Skip to content

Commit 71d086c

Browse files
committed
fix glu func order
1 parent 6127350 commit 71d086c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

nn/math_.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ def gelu(x: LayerRef) -> Layer:
2727
return activation(x, activation="gelu")
2828

2929

30+
def glu(x: LayerRef) -> Layer:
31+
"""GLU https://arxiv.org/abs/1612.08083"""
32+
return activation(x, activation='glu')
33+
34+
3035
def exp(x: LayerRef) -> Layer:
3136
"""exp"""
3237
return activation(x, activation="exp")
@@ -50,8 +55,3 @@ def sigmoid(x: LayerRef) -> Layer:
5055
def swish(x: LayerRef) -> Layer:
5156
"""swish"""
5257
return activation(x, activation="swish")
53-
54-
55-
def glu(x: LayerRef) -> Layer:
56-
"""GLU"""
57-
return activation(x, activation='glu')

0 commit comments

Comments
 (0)