(self, embedding_dim: int, use_additional_conditions: bool = False, time_step_rescale=1000)
| 272 | use_additional_conditions (`bool`): To use additional conditions for normalization or not. |
| 273 | """ |
| 274 | def __init__(self, embedding_dim: int, use_additional_conditions: bool = False, time_step_rescale=1000): |
| 275 | super().__init__() |
| 276 | |
| 277 | self.emb = PixArtAlphaCombinedTimestepSizeEmbeddings( |
| 278 | embedding_dim, size_emb_dim=embedding_dim // 2, use_additional_conditions=use_additional_conditions |
| 279 | ) |
| 280 | |
| 281 | self.silu = nn.SiLU() |
| 282 | self.linear = nn.Linear(embedding_dim, 6 * embedding_dim, bias=True) |
| 283 | |
| 284 | self.time_step_rescale = time_step_rescale ## timestep usually in [0, 1], we rescale it to [0,1000] for stability |
| 285 | |
| 286 | def forward( |
| 287 | self, |
nothing calls this directly
no test coverage detected