Tensorflow中实施的Faster-R-CNN训练模型出错

时间:2017-01-11 11:54:04

标签: python-2.7 machine-learning tensorflow computer-vision neural-network

我正在使用以下github存储库,它在tensorflow中实现了一个名为Faster R-CNN的深度学习模型:

https://github.com/smallcorgi/Faster-RCNN_TF

此模型将用于对象检测。

我正在尝试复制那里提到的步骤来训练模型,这就是我所面对的:

  1. 我成功地执行了从1到5的步骤。
  2. 然后,我运行命令:

    experiments / scripts / faster_rcnn_end2end.sh cpu 0 VGG16 pascal_voc

  3. 我收到错误:

    + set -e
    + export PYTHONUNBUFFERED=True
    + PYTHONUNBUFFERED=True
    + DEV=cpu
    + DEV_ID=0
    + NET=VGG16
    + DATASET=pascal_voc
    + array=($@)
    + len=4
    + EXTRA_ARGS=
    + EXTRA_ARGS_SLUG=
    + case $DATASET in
    + TRAIN_IMDB=voc_2007_trainval
    + TEST_IMDB=voc_2007_test
    + PT_DIR=pascal_voc
    + ITERS=70000
    ++ date +%Y-%m-%d_%H-%M-%S
    + LOG=experiments/logs/faster_rcnn_end2end_VGG16_.txt.2017-01-11_17-16-26
    + exec
    ++ tee -a experiments/logs/faster_rcnn_end2end_VGG16_.txt.2017-01-11_17-16-26
    tee: experiments/logs/faster_rcnn_end2end_VGG16_.txt.2017-01-11_17-16-26: No such file or directory
    + echo Logging output to experiments/logs/faster_rcnn_end2end_VGG16_.txt.2017-01-11_17-16-26
    Logging output to experiments/logs/faster_rcnn_end2end_VGG16_.txt.2017-01-11_17-16-26
    + python ./tools/train_net.py --device cpu --device_id 0 --weights data/pretrain_model/VGG_imagenet.npy --imdb voc_2007_trainval --iters 70000 --cfg experiments/cfgs/faster_rcnn_end2end.yml --network VGGnet_train
    voc_2007_train
    voc_2007_val
    voc_2007_trainval
    voc_2007_test
    kitti_train
    kitti_val
    kitti_trainval
    kitti_test
    nthu_71
    nthu_370
    Traceback (most recent call last):
      File "./tools/train_net.py", line 16, in <module>
        from networks.factory import get_network
      File "/home/impadmin/Desktop/Faster-RCNN_TF-master/tools/../lib/networks/__init__.py", line 8, in <module>
        from .VGGnet_train import VGGnet_train
      File "/home/impadmin/Desktop/Faster-RCNN_TF-master/tools/../lib/networks/VGGnet_train.py", line 2, in <module>
        from networks.network import Network
      File "/home/impadmin/Desktop/Faster-RCNN_TF-master/tools/../lib/networks/network.py", line 3, in <module>
        import roi_pooling_layer.roi_pooling_op as roi_pool_op
      File "/home/impadmin/Desktop/Faster-RCNN_TF-master/tools/../lib/roi_pooling_layer/roi_pooling_op.py", line 6, in <module>
        _roi_pooling_module = tf.load_op_library(filename)
      File "/home/impadmin/anaconda2/lib/python2.7/site-packages/tensorflow/python/framework/load_library.py", line 64, in load_op_library
        None, None, error_msg, error_code)
    tensorflow.python.framework.errors_impl.NotFoundError: /home/impadmin/Desktop/Faster-RCNN_TF-master/lib/roi_pooling_layer/roi_pooling.so: undefined symbol: _Z22ROIPoolBackwardLaucherPKffiiiiiiiS0_PfPKiRKN5Eigen9GpuDeviceE
    

    创建 roi_pooling.so 文件时似乎存在问题。该文件已成功创建,但显示此错误。

    这是否意味着所提到的存储库是用于基于GPU的计算而不是基于CPU的?

    如果可能,我怎样才能在CPU上运行它?

0 个答案:

没有答案