MAC下安裝tensorflow 1.15.0

背景:Tensorflow 2.0 與1.*存在着不兼容的情況,而目前很多的項目源碼是1.*版本下的,爲了方便學習,還是裝回1.*版本

環境:

OS:mac os

PYTHON: 3.7

pip install tensorflow==1.15.0

直接用pip安裝提示找不到這個版本,於是打算先把1.15版本下載下來。

1. 進入官網 https://pypi.org/project/tensorflow/1.15.0/#files  找到對應的macos 3.7版本並點擊下載。

2. 進入到whl文件所在的目錄,執行安裝命令,注意我這裏前面加了python3 -m,是因爲解釋器python3對應的是3.7版本

answers-MacBook-Pro:Downloads answer$ python3 -m pip install tensorflow-1.15.0-cp37-cp37m-macosx_10_11_x86_64.whl

3. 查看是否安裝成功。

answers-MacBook-Pro:Downloads answer$ pip show tensorflow
Name: tensorflow
Version: 1.15.0
Summary: TensorFlow is an open source machine learning framework for everyone.
Home-page: https://www.tensorflow.org/
Author: Google Inc.
Author-email: [email protected]
License: Apache 2.0
Location: /Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages
Requires: opt-einsum, absl-py, keras-applications, protobuf, tensorboard, termcolor, keras-preprocessing, wheel, numpy, tensorflow-estimator, astor, gast, google-pasta, wrapt, six, grpcio
Required-by: 
answers-MacBook-Pro:Downloads answer$ 

 

可能存在的問題:python解釋器、pip

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章