mirror of
https://github.com/ml-explore/mlx-examples.git
synced 2025-06-24 09:21:18 +08:00
Update llms/mlx_lm/models/gemma3_text.py
Co-authored-by: Awni Hannun <awni.hannun@gmail.com>
This commit is contained in:
parent
92b06ddcad
commit
bbadd1d5af
@ -116,7 +116,6 @@ class MLP(nn.Module):
|
|||||||
self.up_proj = nn.Linear(dim, hidden_dim, bias=False)
|
self.up_proj = nn.Linear(dim, hidden_dim, bias=False)
|
||||||
|
|
||||||
def __call__(self, x) -> mx.array:
|
def __call__(self, x) -> mx.array:
|
||||||
# This should not be GELU approx, jax.nn.gelu
|
|
||||||
return self.down_proj(nn.gelu_approx(self.gate_proj(x)) * self.up_proj(x))
|
return self.down_proj(nn.gelu_approx(self.gate_proj(x)) * self.up_proj(x))
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user