Giter VIP home page Giter VIP logo

detectron-da-faster-rcnn's Introduction

Domain Adaptive Faster R-CNN in Detectron

Updates

Introduction

This is a Caffe2 implementation of 'Domain Adaptive Faster R-CNN for Object Detection in the Wild', implemented by Haoran Wang([email protected]). The original paper can be found here. This implementation is built on Detectron @ 5ed75f9.

If you find this repository useful, please cite the oringinal paper:

@inproceedings{chen2018domain,
  title={Domain Adaptive Faster R-CNN for Object Detection in the Wild},
      author =     {Chen, Yuhua and Li, Wen and Sakaridis, Christos and Dai, Dengxin and Van Gool, Luc},
      booktitle =  {Computer Vision and Pattern Recognition (CVPR)},
      year =       {2018}
  }

and Detectron:

@misc{Detectron2018,
  author =       {Ross Girshick and Ilija Radosavovic and Georgia Gkioxari and
                  Piotr Doll\'{a}r and Kaiming He},
  title =        {Detectron},
  howpublished = {\url{https://github.com/facebookresearch/detectron}},
  year =         {2018}
}

Installation

Please follow the instruction in Detectron to install and use Detectron-DomainAdaptive-Faster-RCNN.

Usage Example

An example of adapting from Sim10k dataset to Cityscapes dataset is provided:

  1. Download the Cityscapes datasets from here and Sim10k datasets from here.

  2. Convert the labels of Cityscapes datasets and Sim10k datasets to coco format using the scripts 'tools/convert_cityscapes_to_caronly_coco.py' and 'tools/convert_sim10k_to_coco.py'.

  3. Convert ImageNet-pretrained VGG16 Caffe model to Detectron format with 'tools/pickle_caffe_blobs.py' or use my converted VGG16 model in here

  4. Train the Domain Adaptive Faster R-CNN:

    cd $DETECTRON
    python2 tools/train_net.py --cfg configs/da_faster_rcnn_baselines/e2e_da_faster_rcnn_vgg16-sim10k.yaml
    
  5. Test the trained model:

    cd $DETECTRON
    python2 tools/test_net.py --cfg configs/da_faster_rcnn_baselines/e2e_da_faster_rcnn_vgg16-sim10k.yaml TEST.WEIGHTS /<path_to_trained_model>/model_final.pkl NUM_GPUS 1
    

Pretrained Model & Results

The best results for different adaptation are reported. Due to the instable nature of adversarial training, the best models are obtained through a model selection on a randomly picked mini validation set.

image instsnace consistency car AP Pretrained models
Faster R-CNN 32.58
DA Faster R-CNN 38.60 model
DA Faster R-CNN 35.55 model
DA Faster R-CNN 39.23 model
DA Faster R-CNN 40.01 model

Other Implementation

da-faster-rcnn based on Caffe. (original code by paper authors)

Domain-Adaptive-Faster-RCNN-PyTorch based on PyTorch and maskrcnn-benchmark.

sa-da-faster based on PyTorch and maskrcnn-benchmark.

detectron-da-faster-rcnn's People

Contributors

krumo 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.