apple / tensorflow_macos

TensorFlow for macOS 11.0+ accelerated using Apple's ML Compute framework.
Other
3.66k stars 308 forks source link

Cannot install on 11.2.1 #182

Open fonnesbeck opened 3 years ago

fonnesbeck commented 3 years ago

When running the install script as described on the README on a MacBook Air M1 and macOS 11.2.1, I get the following error:

ERROR: TensorFlow with ML Compute acceleration is only available on macOS 11.0 and later.

Clearly this is a false error message. Anyone else see this?

fonnesbeck commented 3 years ago

Looking at what the script is looking for, I'm getting the following for OS version:

echo $(sw_vers -productVersion) 10.16

Apparently this is by design, to allow for compatibility with some older apps. So, this is not a valid way to check for Big Sur.

fonnesbeck commented 3 years ago

Am I really the only one seeing this? Still does not work in alpha3.

sqzhang-jeremy commented 3 years ago

Am I really the only one seeing this? Still does not work in alpha3. Nope. I've met the same error bug with you, but on a MacBook pro M1 and macOS 11.1. I closed the conda env and redid the command:bash download_and_install.sh, it worked. Here is the download_and_install.sh link: https://pan.baidu.com/s/1dvoz0JYcylrT0UeHuojGzw, password: ggwi

fonnesbeck commented 3 years ago

Thanks for the suggestion; it does not work even after deactivating the conda env. The issue with the OS version remains--it still thinks I am running OS 10.16.

sqzhang-jeremy commented 3 years ago

Thanks for the suggestion; it does not work even after deactivating the conda env. The issue with the OS version remains--it still thinks I am running OS 10.16.

1)Reboot ur mac. 2)Check the right python version you've installed. I've referenced an article: https://blog.csdn.net/knowledge_endlesss/article/details/113853831, which gives a very clear thinking to install tf/torch on Macbook M1. Now only version 3.9+ supports ARM on the Python website, and tensorflow_macos only supports python3.8+. Therefore, a >=3.9 python should be installed first. Then, a new python=3.8 env shoulde be created by conda manger like miniforge. 3)redo the bash download_and_install.sh.

Hope it will work. There are many bugs in tensorflow_macos, maybe I was lucky.

fonnesbeck commented 3 years ago

The only way I could get around it was to strip out all of the version checks in the scripts, download the installer, strip out the version check in the installer script, and then run it.

The version check clearly does not work, and should be removed or modified to work correctly with Big Sur.