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
a7557455
Unverified
Commit
a7557455
authored
May 21, 2024
by
hoshi-hiyouga
Committed by
GitHub
May 21, 2024
Browse files
PaliGemma - fix processor with no input text (#30916)
Update processing_paligemma.py
parent
d502bd64
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
0 deletions
+1
-0
src/transformers/models/paligemma/processing_paligemma.py
src/transformers/models/paligemma/processing_paligemma.py
+1
-0
No files found.
src/transformers/models/paligemma/processing_paligemma.py
View file @
a7557455
...
...
@@ -177,6 +177,7 @@ class PaliGemmaProcessor(ProcessorMixin):
logger
.
warning_once
(
"You are using PaliGemma without a text prefix. It will perform as a picture-captioning model."
)
text
=
""
if
isinstance
(
text
,
List
)
and
isinstance
(
images
,
List
):
if
len
(
images
)
<
len
(
text
):
...
...
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