Fix bug where EMA was not being initialized even when setup in the config. EMA will now properly be setup and used.

This commit is contained in:
Jaret Burkett
2026-06-07 11:11:49 -06:00
parent 8968e41234
commit 82190b41e6

View File

@@ -2026,6 +2026,9 @@ class BaseSDTrainProcess(BaseTrainProcess):
# Update the learning rates if they changed
# optimizer.param_groups = previous_params
# set up the ema now that the optimizer (and its params) are ready
self.setup_ema()
lr_scheduler_params = self.train_config.lr_scheduler_params
# make sure it had bare minimum