(参考:
GitHub官方安装教程)
准备model-master的文件,从GitHub下载:https://github.com/tensorflow/models.git
进行解压,更名为models
1、查看tf路径版本
dell@dell-PowerEdge-T630:~$ python3
Python 3.5.2 (default, Nov 23 2017, 16:37:01)
[GCC 5.4.0 20160609] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import tensorflow as tf
>>> tf.__version__
'1.4.0'
>>> tf.__path__
['/usr/local/lib/python3.5/dist-packages/tensorflow']
>>>
2、安装所需的库
sudo apt-get install protobuf-compiler python3-pil python3-lxml
sudo pip3 install matplotlib
3、复制model到TF路径下
4、编译proto
5、回到home路径
vim .bashrc
source .bashrc 使配置生效
6、测试安装是否成功
7、debug
提示少了python3-tk的包
安装:sudo apt-get install python3-tk
8、继续debug
安装后还是不行,继续网上查资料,发现没有install
进入research目录
执行sudo python3 setup.py install
进入slim
执行sudo python3 setup.py install
9、运行成功