Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
2582bbde
Unverified
Commit
2582bbde
authored
Aug 21, 2023
by
Arthur
Committed by
GitHub
Aug 21, 2023
Browse files
fix ACT_FN (#25627)
parent
2c1bcbf5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/models/openai/modeling_openai.py
src/transformers/models/openai/modeling_openai.py
+1
-1
No files found.
src/transformers/models/openai/modeling_openai.py
View file @
2582bbde
...
@@ -130,7 +130,7 @@ def load_tf_weights_in_openai_gpt(model, config, openai_checkpoint_folder_path):
...
@@ -130,7 +130,7 @@ def load_tf_weights_in_openai_gpt(model, config, openai_checkpoint_folder_path):
return
model
return
model
ACT_FNS
=
{
"relu"
:
nn
.
ReLU
,
"silu"
:
silu
,
"gelu"
:
gelu_new
,
"swish"
:
silu
}
ACT_FNS
=
{
"relu"
:
nn
.
ReLU
()
,
"silu"
:
silu
,
"gelu"
:
gelu_new
,
"swish"
:
silu
}
class
Attention
(
nn
.
Module
):
class
Attention
(
nn
.
Module
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment