-
Notifications
You must be signed in to change notification settings - Fork 74.5k
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
h5py==3.0.0 causes issues with keras model loads in tensorflow 2.1.0 #44467
Comments
I think it will be hard to expect a backport on 2.1.0. |
the new h5py version just came out today: https://pypi.org/project/h5py/#history Pinning it to a version <3.0.0 (or at least throwing a warning) is a very lightweight change with no risk. |
Yes but as you know generally we had very few patch releases (e.g. 2.1.x) so It Is quite hard to have wheels with these fixes on old versions. |
@bhack I'm not going to add any more messages after this, but I think you can see based on these other issues the Keras API is essentially broken because h5py new release. I'm not sure why the version was not pinned as it is in master, but I strongly advise that you pin to h5py==2.10.0 this for all TF >= 2.1. |
/cc @mihaimaruseac @angerson there are many Dockerfile and other file not constrained. |
FWIW, I got a similar error message with h5py 3.0, and removing |
We cannot pin the versions without doing a patch release. We only do patch releases for security issues. This issue has a quick workaround: We are in the process of releasing TF 2.4 which should not be affected by this issue. |
Thought it might be pertinent to link to the h5py repo: edit: |
Addresses training and inference issues tensorflow/tensorflow#44467
That seems the case. I tried h5py 3.1.0, and the error |
😆 Thanks!! |
|
Tensorflow update required following update to cuda 11.0. Based on https://www.tensorflow.org/install/source#gpu, the 2.4 branch of tensorflow should be used with cuda 11.0. - Removed pinned version of keras/h5py, no longer needed. tensorflow/tensorflow#44467 (comment) - Updated tflite version to 2.4.2. Also, tflite install script now reads the installed version of tensorflow, to keep the version matched in the future.
* [Docker] Updated tensorflow/tflite version to 2.4.2 Tensorflow update required following update to cuda 11.0. Based on https://www.tensorflow.org/install/source#gpu, the 2.4 branch of tensorflow should be used with cuda 11.0. - Removed pinned version of keras/h5py, no longer needed. tensorflow/tensorflow#44467 (comment) - Updated tflite version to 2.4.2. Also, tflite install script now reads the installed version of tensorflow, to keep the version matched in the future. * [Docker] Corrected version pinning of xgboost Previously, due to missing quotes, installed most recent version of xgboost, piping the results to a file named '=1.1.0'. Now, installs xgboost at least at version 1.1.0. Co-authored-by: Eric Lunderberg <elunderberg@octoml.ai>
Hey guys, when Iam trying to downgrade the version of h5py I get the follwing error: ERROR: Failed building wheel for h5py Rolling back uninstall of h5py Would be awesome if someone can help me! :) |
Downgrade h5py for Keras model loading in TF 2.1.x tensorflow/tensorflow#44467
* [Docker] Updated tensorflow/tflite version to 2.4.2 Tensorflow update required following update to cuda 11.0. Based on https://www.tensorflow.org/install/source#gpu, the 2.4 branch of tensorflow should be used with cuda 11.0. - Removed pinned version of keras/h5py, no longer needed. tensorflow/tensorflow#44467 (comment) - Updated tflite version to 2.4.2. Also, tflite install script now reads the installed version of tensorflow, to keep the version matched in the future. * [Docker] Corrected version pinning of xgboost Previously, due to missing quotes, installed most recent version of xgboost, piping the results to a file named '=1.1.0'. Now, installs xgboost at least at version 1.1.0. Co-authored-by: Eric Lunderberg <elunderberg@octoml.ai>
I am facing the same issue. Is there any solution came out to fix this bug:
|
Apparently tensorflow/tensorflow#44467 will take a bit longer to really get sorted out and distributed. Sigh.
Wait, why is this closed? I'm certainly still having the problem. Reverting to an earlier version of h5py is not a solution, it's a work-around. |
TF 2.1.x is no longer supported. TF 2.4.x was supposed to have this fixed (but also is no longer updated). Any version of TF above 2.4.0 should not have this issue. If there is a similar issue, please open a new issue. Edit: locking to prevent notifications being sent to everyone that followed this issue over its lifetime and are no longer affected |
h5py released version 3.0.0 today and it causes this code to fail:
https://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/keras/saving/hdf5_format.py#L182
with error:
It looks like in version 2.1.0 the
h5py
version is not pinned (it is pinned in master), which is causing the issue.The text was updated successfully, but these errors were encountered: