zoukankan      html  css  js  c++  java
  • Jetson TX1 install pyfasterrcnn

    Install py-faster-rcnn following the official version 
     
    • Build the Cython modules
    cd $FRCN_ROOT/lib
    make
     
    Errors:
    Traceback (most recent call last):
      File "setup.py", line 58, in <module>
      CUDA = locate_cuda()
      File "setup.py", line 55, in locate_cuda
      raise EnvironmentError('The CUDA %s path could not be located in %s' % (k, v))
    EnvironmentError: The CUDA lib path could not be located in /usr/local/cuda-8.0/lib
     
    Reason: the cuda path is not correct in ./lib/setup.py
    Solver
    gedit 打开 setup.py
    cudaconfig = {'home':home, 'nvcc':nvcc,
                      'include': pjoin(home, 'include'),
                      'lib': pjoin(home, 'lib')}
    把上面的最后一个lib改为lib64即可   
    cudaconfig = {'home':home, 'nvcc':nvcc,
                      'include': pjoin(home, 'include'),
                      'lib': pjoin(home, 'lib64')}
     
    • Build Caffe and pycaffe
    cd $FRCN_ROOT/caffe-fast-rcnn
    # Now follow the Caffe installation instructions here:
    #   http://caffe.berkeleyvision.org/installation.html
    
    # If you're experienced with Caffe and have all of the requirements installed
    # and your Makefile.config in place, then simply do:
    make -j8 && make pycaffe
     
    Errors:
    learning@learning-virtual-machine:~/caffe$ make all
    PROTOC src/caffe/proto/caffe.proto
    CXX .build_release/src/caffe/proto/caffe.pb.cc
    CXX src/caffe/data_transformer.cpp
    CXX src/caffe/common.cpp
    CXX src/caffe/internal_thread.cpp
    CXX src/caffe/blob.cpp
    CXX src/caffe/data_reader.cpp
    CXX src/caffe/parallel.cpp
    CXX src/caffe/util/hdf5.cpp
    In file included from src/caffe/util/hdf5.cpp:1:0:
    ./include/caffe/util/hdf5.hpp:6:18: fatal error: hdf5.h: No such file or directory
    compilation terminated.
    Makefile:572: recipe for target '.build_release/src/caffe/util/hdf5.o' failed
    make: *** [.build_release/src/caffe/util/hdf5.o] Error 1
    learning@learning-virtual-machine:~/caffe$ 
     
    Solver:
    Makefile.config
    INCLUDE_DIRS
    /usr/include/hdf5/serial/
    Makefile
    LIBRARIES
    hdf5_hl and hdf5 改为 hdf5_serial_hl ,hdf5_serial

    这里写图片描述
     
    这里写图片描述
     
    • Demo
     
    cd $FRCN_ROOT
    ./tools/demo.py
    Errors:
    Loaded network /home/ubuntu/Projects/py-faster-rcnn/data/faster_rcnn_models/VGG16_faster_rcnn_final.caffemodel
    Killed
     
    Reason:
    The vgg16 model is too large
    Solver:
    Change to zf model
     
    • Results:
     
    Loaded network /home/ubuntu/Projects/py-faster-rcnn/data/faster_rcnn_models/ZF_faster_rcnn_final.caffemodel
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Demo for data/demo/000456.jpg
    Detection took 0.530s for 300 object proposals
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Demo for data/demo/000542.jpg
    Detection took 0.722s for 135 object proposals
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Demo for data/demo/001150.jpg
    Detection took 0.643s for 231 object proposals
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Demo for data/demo/001763.jpg
    Detection took 0.764s for 200 object proposals
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    Demo for data/demo/004545.jpg
    Detection took 0.661s for 300 object proposals
     
     
     
  • 相关阅读:
    工具进阶:如何利用 MAT 找到问题发生的根本原因
    性能优化步骤
    搞定内存泄漏
    jvm配置示例
    vue的transition相同元素通过v-if,以及绑定key的区别
    安装nvm之node版本管理器
    在ts中定义变量类型的dva使用方法
    dva的全部用法
    react父子组件传值之二,ref传值(父组件调用子组件的值和方法) useRef+useImperativeHandle(hook)
    react父子组件传值方式一之props方法
  • 原文地址:https://www.cnblogs.com/haiyang21/p/6539700.html
Copyright © 2011-2022 走看看