I'm getting the following message when I install the *.whl for TensorFlow. I'm installing from source just like this: https://www.tensorflow.org/install/install_sources
keras 2.2.2 has requirement keras-applications==1.0.4, but you'll have keras-applications 1.0.5 which is incompatible.
keras 2.2.2 has requirement keras-preprocessing==1.0.2, but you'll have keras-preprocessing 1.0.3 which is incompatible.
Installing collected packages: keras-applications, keras-preprocessing, tensorflow
Found existing installation: Keras-Applications 1.0.4
Uninstalling Keras-Applications-1.0.4:
Successfully uninstalled Keras-Applications-1.0.4
Found existing installation: Keras-Preprocessing 1.0.2
Uninstalling Keras-Preprocessing-1.0.2:
Successfully uninstalled Keras-Preprocessing-1.0.2
Successfully installed keras-applications-1.0.5 keras-preprocessing-1.0.3 tensorflow-1.10.0
Do you know why the installation removes the correct versions of Keras-Applications and Keras-Preprocessing, and reinstalls with the newer incompatible versions?
Thanks
Installation & compatibility To start using Keras, simply install TensorFlow 2. Keras/TensorFlow are compatible with: Python 3.7–3.10.
TensorFlow is an open-sourced end-to-end platform, a library for multiple machine learning tasks, while Keras is a high-level neural network library that runs on top of TensorFlow. Both provide high-level APIs used for easily building and training models, but Keras is more user-friendly because it's built-in Python.
keras 2.10. 0 Deep learning for humans.
Tensorflow and Keras require a python version of at least 3.7. Use the following command to install Python 3.8. After installing Python 3.8, assign this version as the standard version.
It seems that you'll need Keras-2.1.6 instead of Keras-2.2.2. So, use
sudo -H pip uninstall Keras
to uninstall the current 2.2.2 version, then
sudo pip install Keras==2.1.6
Hopefully this can fix the issue you have.
Regarding the reason why this happens, I think it is because TensorFlow requires Keras-Applications>=1.0.5
, and Keras-Preprocessing>=1.0.3
. The package management algorithm always go with the latest available package, which bring to us Kera-2.2.2. Whereas latest Keras have an odd dependency requirement, which specifically requires Keras-Applications==1.0.4
, and Keras-Preprocessing==1.0.2
. My fix is to roll back Keras to a slight older version that have >= requirements, to make pip happy.
One step further, I think it is either a bug in Keras 2.2.2's dependency, or it is intensional because Keras 2.2.2 is somehow incompatible with latest Keras-Applications or Keras-Preprocessing.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With