Faster R-CNN Train your data in a CPU configuration

Source: Internet
Author: User

because there is no GPU, so in the CPU training their own data, the middle encountered a variety of pits, fortunately did not give up, This process is documented in this article.

1, under the CPU configuration faster r-cnn, reference blog: http://blog.csdn.net/wjx2012yt/article/details/52197698#quote

2, in the CPU training data set, need to py-faster-rcnn within the Roi_pooling_layer and Smooth_l1_loss_layer changed to the CPU version,

and recompile. The blogger has modified it to be replaced directly: http://blog.csdn.net/qq_14975217/article/details/51495844

3, the production of their own VOC data set, this part of the reference blog: http://blog.csdn.net/gvfdbdf/article/details/52214008

4, in order to prevent mixing with the previous model, before training to remove the output folder (or change the other name), but also to the Py-faster-rcnn/data/cache files and

File deletion (if any) in the Py-faster-rcnn/data/vocdevkit2007/annotations_cache.

5, before the training of the changes. My dataset is for people in the monitoring video, so there are only backgrounds and people in both categories. Just follow this blog to make changes:

http://blog.csdn.net/sinat_30071459/article/details/51332084

Also modify the solve file settings in py-faster-rcnn/models/pascal_voc/zf/faster_rcnn_alt_opt, including STEPSIZE,BASE_LR,

Otherwise, it is very easy to loss=-nan when training.

6. Training in PY-FASTER-RCNN

0 ZF PASCAL_VOC  

7. Testing

Copy the Py-faster-rcnn\output\faster_rcnn_alt_opt\***_trainval ZF Caffemodel from the training to

Py-faster-rcnn\data\faster_rcnn_models, modify the py-faster-rcnn\tools\demo.py (mainly category modification

And the modification of the test picture). Run

Python demo.py--cpu

8. Results

Maybe I have too little data and bad quality (1000 photos), the number of training is not enough, the detection effect is not very good, the default threshold value can not be detected.

When the demo.py in the Conf_thresh down to 0.1 only to detect a piece, and the speed is very slow, about 13 seconds a sheet, the effect is general.

Faster R-CNN Train your data in a CPU configuration

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.