You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Models downloaded through KerasHub fail to deserialize.
To Reproduce
It is not possible to reproduce this bug in Colab. I suspect there is some library version incompatibility; however, the Colab environment is so complicated that I was unable to replicate it locally.
To reproduce the bug, create a new directory and put the following pyproject.toml into it:
The versions of these packages (besides matplotlib and Jupyter) are pinned to their values in Colab. Next, run uv sync, then source .venv/bin/activate. Finally, copy and paste the following code blocks into a Jupyter notebook (taken from the tutorial here):
importosos.environ["KERAS_BACKEND"] ="jax"# or "tensorflow" or "torch"os.environ["XLA_PYTHON_CLIENT_MEM_FRACTION"] ="1.0"
Thanks for reporting the issue. I reproduce the issue in keras_hub(0.18.1) and keras(3.8.0) version and issue doesn't reproduce anymore. Attached gist here for the reference.
Hi, yes, I mentioned this when I wrote the issue. However, when installing these packages locally (both on MacOS and on Linux), the example breaks for me. Could you please try reproducing the bug outside of the Colab environment?
Describe the bug
Models downloaded through KerasHub fail to deserialize.
To Reproduce
It is not possible to reproduce this bug in Colab. I suspect there is some library version incompatibility; however, the Colab environment is so complicated that I was unable to replicate it locally.
To reproduce the bug, create a new directory and put the following
pyproject.toml
into it:The versions of these packages (besides matplotlib and Jupyter) are pinned to their values in Colab. Next, run
uv sync
, thensource .venv/bin/activate
. Finally, copy and paste the following code blocks into a Jupyter notebook (taken from the tutorial here):The final cell results in the following error:
Expected behavior
I expect the last cell to produce the output
from the tutorial page.
Additional context
The tutorial works on Colab, but not locally; I tried this both on Linux with CUDA GPUs and on my M1 MacBook Pro. Neither worked.
Would you like to help us fix it?
I don't believe I have the expertise or time to fix it, unfortunately.
The text was updated successfully, but these errors were encountered: