mirror of
https://github.com/ostris/ai-toolkit.git
synced 2026-04-30 11:11:37 +00:00
Change img multiplier math
This commit is contained in:
@@ -457,7 +457,7 @@ class SDTrainer(BaseSDTrainProcess):
|
||||
if self.train_config.target_norm_std:
|
||||
# seperate out the batch and channels
|
||||
pred_std = noise_pred.std([2, 3], keepdim=True)
|
||||
norm_std_loss = torch.abs(1.0 - pred_std).mean()
|
||||
norm_std_loss = torch.abs(self.train_config.target_norm_std_value - pred_std).mean()
|
||||
loss = loss + norm_std_loss
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user