Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
transformers
Commits
e73595bd
"awq/git@developer.sourcefind.cn:OpenDAS/autoawq.git" did not exist on "a4626828a4a00426eacf3e39b02bf650a57daec6"
Unverified
Commit
e73595bd
authored
Apr 29, 2020
by
Lysandre Debut
Committed by
GitHub
Apr 29, 2020
Browse files
Remove jitted method so that our models are pickable. (#4050)
parent
2c778428
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
9 deletions
+0
-9
src/transformers/activations.py
src/transformers/activations.py
+0
-9
No files found.
src/transformers/activations.py
View file @
e73595bd
...
@@ -33,15 +33,6 @@ if torch.__version__ < "1.4.0":
...
@@ -33,15 +33,6 @@ if torch.__version__ < "1.4.0":
gelu
=
_gelu_python
gelu
=
_gelu_python
else
:
else
:
gelu
=
F
.
gelu
gelu
=
F
.
gelu
try
:
import
torch_xla
# noqa F401
logger
.
warning
(
"The torch_xla package was detected in the python environment. PyTorch/XLA and JIT is untested,"
" no activation function will be traced with JIT."
)
except
ImportError
:
gelu_new
=
torch
.
jit
.
script
(
gelu_new
)
ACT2FN
=
{
ACT2FN
=
{
"relu"
:
F
.
relu
,
"relu"
:
F
.
relu
,
...
...
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