源码地址:https://github.com/dBeker/Faster-RCNN-TensorFlow-Python3.5
按照原码下作者的步骤:
1- Install tensorflow, preferably GPU version. Follow instructions. If you do not install GPU version, you need to comment out all the GPU calls inside code and replace them with relavent CPU ones.
我的配置:
cudnn-9.0-windows10-x64-v7
cuda_9.0.176_win10
python3.5
2- Install python packages (cython, python-opencv, easydict)
库可以随时安装,出现error可以随时百度,很好解决。
4- Go to ./data/coco/PythonAPI
Run python setup.py build_ext --inplace
Run python setup.py build_ext install
Go to ./lib/utils and run python setup.py build_ext --inplace
在anaconda prompt中进入目录,注意:如果anaconda中存在多个环境,一定要在进入目录前先激活并进入环境(
conda activate tensorflow-gpu)需要配置的python 3.5的环境(如果存在多个环境时),在tensorflow-gpu的环境下进入目录,运行口令,且三句口令都要在python3.5的环境中运行。
在anaconda prompt中进入./data/coco/PythonAPI
运行 “python setup.py build_ext –inplace“
报错:error: Unable to find vcvarsall.bat
没有安装VS2015,安装https://blog.csdn.net/a6822342/article/details/80841056中的新版本
点击蓝色的Link,下载压缩包
放在上面的目录下即可。
点击上面蓝色的here,下载ckpt。模型下载后解压,放在上面的路径下,没有路径则自己创建。注意模型名必须是vgg16.ckpt。
7- Run train.py
Notify me if there is any issue found. Please note that, I have compiled cython modules with sm61 architecture (GTX 1060, 1070 etc.). Compile support for other architectures will be added.
跑 train.py