Skip to content

Commit

Permalink
add LayerNorm to ColorEncoder
Browse files Browse the repository at this point in the history
  • Loading branch information
piercus committed Jan 22, 2024
1 parent b1eaa66 commit 37a21bf
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/refiners/fluxion/adapters/color_palette.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,10 +55,17 @@ def __init__(
self,
embedding_dim: int,
device: Device | str | None = None,
eps: float = 1e-5,
dtype: DType | None = None,
) -> None:
super().__init__(
fl.Linear(in_features=4, out_features=embedding_dim, device=device, dtype=dtype),
fl.Linear(in_features=4, out_features=embedding_dim, bias=True, device=device, dtype=dtype),
fl.LayerNorm(
normalized_shape=embedding_dim,
eps=eps,
device=device,
dtype=dtype,
)
)

class ColorPaletteEncoder(fl.Chain):
Expand Down

0 comments on commit 37a21bf

Please sign in to comment.