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
92544cb8
Unverified
Commit
92544cb8
authored
May 15, 2024
by
xkszltl
Committed by
GitHub
May 15, 2024
Browse files
Missing `Optional` in typing. (#30821)
The function checks for None in its first line.
parent
64c06df3
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
src/transformers/generation/utils.py
src/transformers/generation/utils.py
+1
-1
No files found.
src/transformers/generation/utils.py
View file @
92544cb8
...
...
@@ -1255,7 +1255,7 @@ class GenerationMixin:
return
generation_config
def
_prepare_generation_config
(
self
,
generation_config
:
GenerationConfig
,
**
kwargs
:
Dict
self
,
generation_config
:
Optional
[
GenerationConfig
]
,
**
kwargs
:
Dict
)
->
Tuple
[
GenerationConfig
,
Dict
]:
"""
Prepares the base generation config, then applies any generation configuration options from kwargs.
...
...
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