keras-team / autokeras

AutoML library for deep learning
http://autokeras.com/
Apache License 2.0
9.13k stars 1.4k forks source link

Bug: Installation failed #1850

Closed MarhsallLotte closed 1 year ago

MarhsallLotte commented 1 year ago

Bug Description

I created a new environment under Anaconda with Python 3.10.9 and jupyter notebook installed. Then I followed the instruction to install "autokeras" after "keras-tuner" with pip. However, I got an error message with "subprocess-exited-with-error", where the error exists in "ImportError: cannot import name 'MutableMapping' from 'collections'".

Bug Reproduction

Code for reproducing the bug:

  1. Create a new environment in anaconda with Python 3.10.9, and activate the environment.
  2. pip3 install keras-tuner --upgrade
  3. pip3 install autokeras

Expected Behavior

  1. Long attempt in "Collecting tensorflow>=2.8.0", where it collects all the versions from 2.10.1 to 2.8.0
  2. Long attempt in "Collecting requests", where it collects all the versions from "requests-2.28.1-py3-none-any.whl" to "requests-1.2.3.tar.gz"
  3. Preparing metadata (setup.py) ... error
  4. error: subprocess-exited-with-error
  5. Error message: "ImportError: cannot import name 'MutableMapping' from 'collections'"

Setup Details

Include the details about the versions of:

Additional context

The full error code: https://drive.google.com/file/d/1wu8uoDfstb35FLEkV9-fjkLFoWX9_rQM/view?usp=sharing

MarhsallLotte commented 1 year ago

Kind of fix it by stating the TensorFlow version. In my case, I stated to install tensorflow==2.11, then it allow me to install the AutoKeras library.

lwq-star commented 1 year ago

My TensorFlow version==2.11. But I also encountered the same mistake, how to solve it?