GithubHelp home page GithubHelp logo

buaali / da-faster-rcnn-pytorch Goto Github PK

View Code? Open in Web Editor NEW

This project forked from tiancity-nju/da-faster-rcnn-pytorch

0.0 0.0 0.0 2.11 MB

An unofficial implementation of 'Domain Adaptive Faster R-CNN for Object Detection in the Wild ’

License: Other

Python 78.59% MATLAB 0.35% Shell 0.34% Cuda 8.60% C 11.66% C++ 0.47%

da-faster-rcnn-pytorch's Introduction

da-faster-rcnn-PyTorch

A PyTorch implementation of 'Domain Adaptive Faster R-CNN for Object Detection in the Wild ’

Preparation

Requirements: Python=3.6 and Pytorch=0.4.0

  1. Install Pytorch

  2. Our code is conducted based on faster-rcnn.pytorch,please setup the framework by it.

  3. Download dataset

    • we use cityscape and cityscapes-foggy datasets respectly as source and target,the cityscapes dataset could be download Here

    • the format of datasets is similar with VOC,you just need to split train.txt to train_s.txt and train_t.txt

    • you can also download the dataset GoogleDrive

Train and Test

1.train the model,you need to download the pretrained model [vgg_caffe](https://github.com/jwyang/faster-rcnn.pytorch) which is different with pure pytorch pretrained model

2.change the dataset root path in ./lib/model/utils/config.py and some dataset dir path in ./lib/datasets/cityscape.py,the default data path is ./data

3 Train the model

# train cityscapes -> cityscapes-foggy
CUDA_VISIBLE_DEVICES=GPU_ID python da_trainval_net.py --dataset cityscape --net vgg16 --bs 1 --lr 2e-3 --lr_decay_step 6 --cuda

# Test model in target domain 
CUDA_VISIBLE_DEVICES=GPU_ID python eval/test.py --dataset cityscape --part test_t --model_dir=# The path of your pth model --cuda

Our model could arrive mAP=30.71% in target domain which is high than baseline mAP=24.26%

da-faster-rcnn-pytorch's People

Contributors

tiancity-nju 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.