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
08bfc171
Unverified
Commit
08bfc171
authored
Sep 16, 2020
by
Xi Ye
Committed by
GitHub
Sep 16, 2020
Browse files
fix the warning message of overflowed sequence (#7151)
parent
af8425b7
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/tokenization_utils_base.py
src/transformers/tokenization_utils_base.py
+1
-1
No files found.
src/transformers/tokenization_utils_base.py
View file @
08bfc171
...
@@ -2477,7 +2477,7 @@ class PreTrainedTokenizerBase(SpecialTokensMixin):
...
@@ -2477,7 +2477,7 @@ class PreTrainedTokenizerBase(SpecialTokensMixin):
logger
.
warning
(
logger
.
warning
(
"Token indices sequence length is longer than the specified maximum sequence length "
"Token indices sequence length is longer than the specified maximum sequence length "
"for this model ({} > {}). Running this sequence through the model will result in "
"for this model ({} > {}). Running this sequence through the model will result in "
"indexing errors"
.
format
(
len
(
ids
),
self
.
model_max_length
)
"indexing errors"
.
format
(
len
(
encoded_inputs
[
"input_
ids
"
]
),
self
.
model_max_length
)
)
)
# Padding
# Padding
...
...
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