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
c127d055
"git@developer.sourcefind.cn:modelzoo/solov2-pytorch.git" did not exist on "d6a724fbc606bb750a1682065b1260a6131c17e9"
Unverified
Commit
c127d055
authored
Jul 30, 2020
by
Oren Amsalem
Committed by
GitHub
Jul 30, 2020
Browse files
add another e.g. to avoid confusion (#6055)
parent
d24ea708
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
2 deletions
+2
-2
src/transformers/modeling_tf_pytorch_utils.py
src/transformers/modeling_tf_pytorch_utils.py
+2
-2
No files found.
src/transformers/modeling_tf_pytorch_utils.py
View file @
c127d055
...
...
@@ -203,7 +203,7 @@ def load_pytorch_weights_in_tf2_model(tf_model, pt_state_dict, tf_inputs=None, a
f
"- This IS expected if you are initializing
{
tf_model
.
__class__
.
__name__
}
from a TF 2.0 model trained on another task "
f
"or with another architecture (e.g. initializing a BertForSequenceClassification model from a TFBertForPretraining model).
\n
"
f
"- This IS NOT expected if you are initializing
{
tf_model
.
__class__
.
__name__
}
from a TF 2.0 model that you expect "
f
"to be exactly identical (initializing a BertForSequenceClassification model from a TFBertForSequenceClassification model)."
f
"to be exactly identical (
e.g.
initializing a BertForSequenceClassification model from a TFBertForSequenceClassification model)."
)
else
:
logger
.
warning
(
f
"All PyTorch model weights were used when initializing
{
tf_model
.
__class__
.
__name__
}
.
\n
"
)
...
...
@@ -350,7 +350,7 @@ def load_tf2_weights_in_pytorch_model(pt_model, tf_weights, allow_missing_keys=F
f
"- This IS expected if you are initializing
{
pt_model
.
__class__
.
__name__
}
from a TF 2.0 model trained on another task "
f
"or with another architecture (e.g. initializing a BertForSequenceClassification model from a TFBertForPretraining model).
\n
"
f
"- This IS NOT expected if you are initializing
{
pt_model
.
__class__
.
__name__
}
from a TF 2.0 model that you expect "
f
"to be exactly identical (initializing a BertForSequenceClassification model from a TFBertForSequenceClassification model)."
f
"to be exactly identical (
e.g.
initializing a BertForSequenceClassification model from a TFBertForSequenceClassification model)."
)
else
:
logger
.
warning
(
f
"All TF 2.0 model weights were used when initializing
{
pt_model
.
__class__
.
__name__
}
.
\n
"
)
...
...
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