mirror of
https://github.com/hpcaitech/Open-Sora.git
synced 2026-02-22 21:43:19 +01:00
[fix] start_from_scratch
This commit is contained in:
parent
ba6c800e9a
commit
fd51586704
|
|
@ -82,16 +82,16 @@ scheduler = dict(
|
|||
|
||||
# Mask settings
|
||||
mask_ratios = {
|
||||
"random": 0.2,
|
||||
"intepolate": 0.01,
|
||||
"quarter_random": 0.01,
|
||||
"quarter_head": 0.01,
|
||||
"quarter_tail": 0.01,
|
||||
"quarter_head_tail": 0.01,
|
||||
"image_random": 0.05,
|
||||
"image_head": 0.1,
|
||||
"image_tail": 0.05,
|
||||
"image_head_tail": 0.05,
|
||||
"random": 0.05,
|
||||
"intepolate": 0.005,
|
||||
"quarter_random": 0.005,
|
||||
"quarter_head": 0.005,
|
||||
"quarter_tail": 0.005,
|
||||
"quarter_head_tail": 0.005,
|
||||
"image_random": 0.025,
|
||||
"image_head": 0.05,
|
||||
"image_tail": 0.025,
|
||||
"image_head_tail": 0.025,
|
||||
}
|
||||
|
||||
# Log settings
|
||||
|
|
@ -105,6 +105,6 @@ ckpt_every = 200
|
|||
# optimization settings
|
||||
load = None
|
||||
grad_clip = 1.0
|
||||
lr = 2e-4
|
||||
lr = 1e-4
|
||||
ema_decay = 0.99
|
||||
adam_eps = 1e-15
|
||||
|
|
|
|||
|
|
@ -209,9 +209,9 @@ def main():
|
|||
ema=ema,
|
||||
optimizer=optimizer,
|
||||
lr_scheduler=lr_scheduler,
|
||||
sampler=None if cfg.get("start_from_scratch ", False) else sampler,
|
||||
sampler=None if cfg.get("start_from_scratch", False) else sampler,
|
||||
)
|
||||
if not cfg.get("start_from_scratch ", False):
|
||||
if not cfg.get("start_from_scratch", False):
|
||||
start_epoch, start_step = ret
|
||||
logger.info("Loaded checkpoint %s at epoch %s step %s", cfg.load, start_epoch, start_step)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue