GithubHelp home page GithubHelp logo

missdores / faster-rcnn-resnet Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eniac-xie/faster-rcnn-resnet

0.0 2.0 0.0 656 KB

ResNet Implementation for Faster-rcnn

License: MIT License

Shell 3.55% Makefile 0.02% MATLAB 0.76% Python 89.43% C++ 0.06% Cuda 2.13% C 4.05%

faster-rcnn-resnet's Introduction

Faster-RCNN-ResNet

This code extends py-faster-rcnn by adding ResNet implementation and Online Hard Example Mining.

This is a ResNet Implementation for Faster-RCNN. The faster rcnn code is based on py-faster-rcnn. The ohem code is based on ohem. To reduce the memory usage, we use batchnorm layer in Microsoft's caffe

Modification

  1. The caffe-fast-rcnn we use is a little different from the one py-faster-rcnn use, it uses the batchnorm layer from Microsoft's caffe to reduce the memory usage.
  2. Using the in-place eltwise sum within the PR
  3. To reduce the memory usage, we also release a pretrained ResNet-101 model in which batchnorm layer's parameters is merged into scale layer's, see tools/merge_bn_scale.py form more detail.
  4. Use Online-Hard-Example-Mining while training.

Installation

The usage is similar to py-faster-rcnn.

  1. Clone this repository
git clone https://github.com/Eniac-Xie/faster-rcnn-resnet.git

We'll call the directory that you cloned faster-rcnn-resnet ROOT

  1. Clone the modified caffe-fast-rcnn
cd $ROOT/
git clone https://github.com/Eniac-Xie/caffe-fast-rcnn.git
  1. Build Cython module
 cd $ROOT/lib/
 make
  1. Build Caffe
 cd $ROOT/caffe-fast-rcnn
 make all -j8
 make pycaffe

Result

training data test data ohem [email protected]
Faster-RCNN, ResNet-50 VOC 07+12 trainval VOC 07 test False 78.78%
Faster-RCNN, ResNet-101 VOC 07+12 trainval VOC 07 test True 79.44%

Testing

Download faster-rcnn-resnet weights from:

faster-rcnn-resnet without ohem (BaiduYun)

faster-rcnn-resnet without ohem (OneDrive)

faster-rcnn-resnet with ohem (BaiduYun)

faster-rcnn-resnet with ohem (OneDrive)

then you can do as follow:

 cd $ROOT/
 sh experiments/scripts/train_resnet101_bn_scale_merged_0712_end2end.sh
 make

or

 cd $ROOT/
 sh experiments/scripts/train_resnet101_bn_scale_merged_0712_end2end_ohem.sh
 make

Training

Download resnet-101 pretrained model, note that we use a modified version in which batchnorm layer's parameters is merged into scale layer's, you can download the model from Baidu Yun or OneDrive

then you can do as follow:

 cd $ROOT/
 sh experiments/scripts/train_resnet101_bn_scale_merged_0712_end2end.sh

or

 cd $ROOT/
 sh experiments/scripts/train_resnet101_bn_scale_merged_0712_end2end_ohem.sh

faster-rcnn-resnet's People

Contributors

eniac-xie avatar havardthom avatar lixiang-ucas avatar onkarganjewar avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.