-
Notifications
You must be signed in to change notification settings - Fork 323
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
(google-generativeai: 0.8.1) Send the transparency PNG but look like the "gemini-pro" convert it to jpg. #567
Comments
@manojssmk the light blue that show in this issue is the color from my app background, not the actually picture. The picture should not have any background. (Transparency.) |
@manojssmk you might try with your gist again with my test set pictures. |
@manojssmk you have to use the picture with rgba mode which it is the blank background. (Background should not have any color). When you got the light blue background, that also showing your answer is still wrong. |
@manojssmk @MarkDaoust this is great, now we are in sync. |
I haven't looked into this. But the behavior will be affected by: #570, that PR ensures that we don't process the images before sending them. Try installing from main:
But it's possible that the PR doesn't change anything: the API may handle the alpha channel by showing the model the picture over a black background. If the API isn't passing an actual alpha channel, there's not much I can do in the SDK. |
Testing a bit, I'm just not convinced that the model uses the alpha channel at all.
b/369593779 |
do you have any idea or if google can help? |
I think this is happening in the API backend. I think there's nothing we can do from out here. |
Do you have any idea to report this bug to backend? |
@Pjumpod , I did this morning. The b/369593779 in my previous message was an internal bug reference. |
@MarkDaoust long time no see, Do you have any update from the API backend? |
Description of the bug:
My code is
and here is the output/
`
`
From this link, It should upload from generate_content as PNG and transparency mode.
as show in #523 but when I got the output of "describe the image", I found the word, "on black background" which is mean the PNG with RGBA was convert to RGB.
Actual vs expected behavior:
expect to upload as PNG with RGBA.
but actual still RGB.
Any other information you'd like to share?
google-generativeai 0.8.1
ByeIO may not able to decode the alpha channel of an image.
I attached this in the code review.
and Here is from stackoverflow.
The text was updated successfully, but these errors were encountered: