-
Notifications
You must be signed in to change notification settings - Fork 292
Revert "Fix dtype bug in image converter (#2147)" #2180
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
Conversation
This will break PaliGemma though. At least, I was not able to run it on Colab (maybe, doing something wrong). Here's the notebook: https://colab.research.google.com/gist/abheesht17/c4eb5ecf392143ba8927c116954b8aa8/kerashub-image-converter-dtype-bug.ipynb. So, we should fix that? |
Thanks! I'll take a look. Right now the basic image backbones (resnet, etc.) are broken, but let's find a way that works for everything. |
Oh, and Gemma3 will break too |
This reverts commit e9241dd.
@abheesht17 I think this fixes things. Can you check? |
8b6f2d9
to
13c3295
Compare
Ugh this is whack-a-mole. Take two. |
c2100a3
to
9cb9ab5
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! Working with Gemma3. Merging
This reverts commit e9241dd.
@abheesht17 reverting this because one of the main modes of operation is taking a uint8 image -> rescaled float output. Basically
keras_hub.layers.ImageConverter(scale=1./255)(int_image)
. Whit this change we would cast back to int and flatten the image into all 0s and 1s.