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
061580c8
Unverified
Commit
061580c8
authored
Jun 09, 2023
by
Freddie Vargus
Committed by
GitHub
Jun 09, 2023
Browse files
Fix typo in streamers.py (#24144)
parent
12bb853c
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/generation/streamers.py
src/transformers/generation/streamers.py
+1
-1
No files found.
src/transformers/generation/streamers.py
View file @
061580c8
...
...
@@ -81,7 +81,7 @@ class TextStreamer(BaseStreamer):
def
put
(
self
,
value
):
"""
Recives tokens, decodes them, and prints them to stdout as soon as they form entire words.
Rec
e
ives tokens, decodes them, and prints them to stdout as soon as they form entire words.
"""
if
len
(
value
.
shape
)
>
1
and
value
.
shape
[
0
]
>
1
:
raise
ValueError
(
"TextStreamer only supports batch size 1"
)
...
...
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