Repository navigation
Commit df1788c
committed
Let FlaxTimestepEmbedding handle the conditioning dtype
nn.Dense promotes its inputs to its own dtype, so casting the already-projected
timestep and guidance to the pooled projection's dtype first only rounds them
early: a no-op when activations are bfloat16, and a needless loss of precision
when they are float32. CombinedTimestepTextProjEmbeddings already passes its
projected timestep through untouched.1 parent 0c4f9e0 commit df1788c
1 file changed
Lines changed: 2 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
552 | 552 | | |
553 | 553 | | |
554 | 554 | | |
555 | | - | |
556 | 555 | | |
557 | 556 | | |
558 | | - | |
| 557 | + | |
559 | 558 | | |
560 | 559 | | |
561 | 560 | | |
562 | 561 | | |
563 | 562 | | |
564 | | - | |
| 563 | + | |
565 | 564 | | |
566 | 565 | | |
567 | 566 | | |
| |||
0 commit comments