SunderAli17 commited on
Commit
73cf0ec
·
verified ·
1 Parent(s): 2f74861

Create losses/loss_config.py

Browse files
Files changed (1) hide show
  1. losses/loss_config.py +15 -0
losses/loss_config.py ADDED
@@ -0,0 +1,15 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ from dataclasses import dataclass, field
2
+ from typing import List
3
+
4
+ @dataclass
5
+ class SingleLossConfig:
6
+ name: str
7
+ weight: float = 1.
8
+ init_params: dict = field(default_factory=dict)
9
+ visualize_every_k: int = -1
10
+
11
+
12
+ @dataclass
13
+ class LossesConfig:
14
+ diffusion_losses: List[SingleLossConfig]
15
+ lcm_losses: List[SingleLossConfig]