anaconda安裝的TensorFlow版本沒有model這個模塊


一、采用git bash來安裝,確認已經安裝了git

二、手動找到TensorFlow的模塊文件夾地址,若不知道,輸入以下兩行代碼:

import tensorflow as tf

tf.__path__

輸出的地址為TensorFlow模塊所在地址

三、在此地址右鍵:git bash here

四、在git bash中輸入以下命令:

git clone --recurse-submodules https://github.com/tensorflow/models

五、安裝編譯完畢會發現tf文件夾下已經有models文件夾了

導入程序試試看

from tensorflow.models.tutorials.rnn.ptb import reader#存在models了也可以導入了

 

參考https://blog.csdn.net/u013058751/article/details/80157020

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM