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
2ef94ee0
Unverified
Commit
2ef94ee0
authored
Jun 25, 2022
by
kumapo
Committed by
GitHub
Jun 24, 2022
Browse files
Fix: torch.utils.checkpoint import error. (#17849)
parent
ef28a402
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
0 deletions
+2
-0
src/transformers/models/deberta/modeling_deberta.py
src/transformers/models/deberta/modeling_deberta.py
+1
-0
src/transformers/models/deberta_v2/modeling_deberta_v2.py
src/transformers/models/deberta_v2/modeling_deberta_v2.py
+1
-0
No files found.
src/transformers/models/deberta/modeling_deberta.py
View file @
2ef94ee0
...
...
@@ -19,6 +19,7 @@ from collections.abc import Sequence
from
typing
import
Optional
,
Tuple
,
Union
import
torch
import
torch.utils.checkpoint
from
torch
import
nn
from
torch.nn
import
BCEWithLogitsLoss
,
CrossEntropyLoss
,
MSELoss
...
...
src/transformers/models/deberta_v2/modeling_deberta_v2.py
View file @
2ef94ee0
...
...
@@ -20,6 +20,7 @@ from typing import Optional, Tuple, Union
import
numpy
as
np
import
torch
import
torch.utils.checkpoint
from
torch
import
nn
from
torch.nn
import
BCEWithLogitsLoss
,
CrossEntropyLoss
,
LayerNorm
,
MSELoss
...
...
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