README.md 4.6 KB
Newer Older
W
wangguanzhong 已提交
1 2
English | [简体中文](README_cn.md)

3
# PaddleDetection
4

Y
Yang Zhang 已提交
5
The goal of PaddleDetection is to provide easy access to a wide range of object
6
detection models in both industry and research settings. We design
Y
Yang Zhang 已提交
7 8
PaddleDetection to be not only performant, production-ready but also highly
flexible, catering to research needs.
9 10 11


<div align="center">
Y
Yang Zhang 已提交
12
  <img src="demo/output/000000570688.jpg" />
13 14 15 16 17
</div>


## Introduction

Q
qingqing01 已提交
18
Features:
19

Y
Yang Zhang 已提交
20
- Production Ready:
Q
qingqing01 已提交
21 22

  Key operations are implemented in C++ and CUDA, together with PaddlePaddle's
Y
Yang Zhang 已提交
23
highly efficient inference engine, enables easy deployment in server environments.
24

Y
Yang Zhang 已提交
25
- Highly Flexible:
Q
qingqing01 已提交
26 27

  Components are designed to be modular. Model architectures, as well as data
Y
Yang Zhang 已提交
28 29
preprocess pipelines, can be easily customized with simple configuration
changes.
30

Y
Yang Zhang 已提交
31
- Performance Optimized:
Q
qingqing01 已提交
32 33

  With the help of the underlying PaddlePaddle framework, faster training and
Y
Yang Zhang 已提交
34 35
reduced GPU memory footprint is achieved. Notably, Yolo V3 training is
much faster compared to other frameworks. Another example is Mask-RCNN
Q
qingqing01 已提交
36 37
(ResNet50), we managed to fit up to 4 images per GPU (Tesla V100 16GB) during
multi-GPU training.
38

Y
Yang Zhang 已提交
39
Supported Architectures:
40

41 42 43 44 45 46 47 48 49 50
|                    | ResNet | ResNet-vd <sup>[1](#vd)</sup> | ResNeXt-vd | SENet | MobileNet | DarkNet | VGG |
|--------------------|:------:|------------------------------:|:----------:|:-----:|:---------:|:-------:|:---:|
| Faster R-CNN       | ✓      |                             ✓ | x          | ✓     | ✗         | ✗       | ✗   |
| Faster R-CNN + FPN | ✓      |                             ✓ | ✓          | ✓     | ✗         | ✗       | ✗   |
| Mask R-CNN         | ✓      |                             ✓ | x          | ✓     | ✗         | ✗       | ✗   |
| Mask R-CNN + FPN   | ✓      |                             ✓ | ✓          | ✓     | ✗         | ✗       | ✗   |
| Cascade R-CNN      | ✓      |                             ✗ | ✗          | ✗     | ✗         | ✗       | ✗   |
| RetinaNet          | ✓      |                             ✗ | ✗          | ✗     | ✗         | ✗       | ✗   |
| Yolov3             | ✓      |                             ✗ | ✗          | ✗     | ✓         | ✓       | ✗   |
| SSD                | ✗      |                             ✗ | ✗          | ✗     | ✓         | ✗       | ✓   |
51

Q
qingqing01 已提交
52
<a name="vd">[1]</a> [ResNet-vd](https://arxiv.org/pdf/1812.01187) models offer much improved accuracy with negligible performance cost.
53

Y
Yang Zhang 已提交
54
Advanced Features:
55

Y
Yang Zhang 已提交
56 57 58 59
- [x] **Synchronized Batch Norm**: currently used by Yolo V3.
- [x] **Group Norm**: pretrained models to be released.
- [x] **Modulated Deformable Convolution**: pretrained models to be released.
- [x] **Deformable PSRoI Pooling**: pretrained models to be released.
60

61 62
**NOTE:** Synchronized batch normalization can only be used on multiple GPU devices, can not be used on CPU devices or single GPU device.

63 64 65

## Model zoo

W
wangguanzhong 已提交
66
Pretrained models are available in the PaddlePaddle [PaddleDetection model zoo](docs/MODEL_ZOO.md).
Y
Yang Zhang 已提交
67

68 69 70

## Installation

Y
Yang Zhang 已提交
71 72
Please follow the [installation guide](docs/INSTALL.md).

73 74 75

## Get Started

Y
Yang Zhang 已提交
76
For inference, simply run the following command and the visualized result will
Q
qingqing01 已提交
77
be saved in `output`.
78 79 80 81

```bash
export PYTHONPATH=`pwd`:$PYTHONPATH
python tools/infer.py -c configs/mask_rcnn_r50_1x.yml \
J
jerrywgz 已提交
82 83
    -o weights=https://paddlemodels.bj.bcebos.com/object_detection/mask_rcnn_r50_1x.tar \
    --infer_img=demo/000000570688.jpg
84 85
```

Y
Yang Zhang 已提交
86
For detailed training and evaluation workflow, please refer to [GETTING_STARTED.md](docs/GETTING_STARTED.md).
87

Y
Yang Zhang 已提交
88
We also recommend users to take a look at the [IPython Notebook demo](demo/mask_rcnn_demo.ipynb)
89

Y
Yang Zhang 已提交
90
Further information can be found in these documentations:
91

Y
Yang Zhang 已提交
92 93
- [Introduction to the configuration workflow.](docs/CONFIG.md)
- [Guide to custom dataset and preprocess pipeline.](docs/DATA.md)
94 95


Y
Yang Zhang 已提交
96
##  Todo List
97

Y
Yang Zhang 已提交
98 99 100
Please note this is a work in progress, substantial changes may come in the
near future.
Some of the planned features include:
101

Y
Yang Zhang 已提交
102 103 104 105 106
- [ ] Mixed precision training.
- [ ] Distributed training.
- [ ] Inference in 8-bit mode.
- [ ] User defined operations.
- [ ] Larger model zoo.
107 108


Y
Yang Zhang 已提交
109
## Updates
110

W
wangguanzhong 已提交
111 112 113 114 115 116 117 118
#### 7/29/2019

- Update Chinese docs for PaddleDetection
- Fix bug in R-CNN models when train and test at the same time
- Add ResNext101-vd + Mask R-CNN + FPN models
- Add Yolo v3 on VOC models

#### 7/3/2019
Q
qingqing01 已提交
119

Y
Yang Zhang 已提交
120 121 122
- Initial release of PaddleDetection and detection model zoo
- Models included: Faster R-CNN, Mask R-CNN, Faster R-CNN+FPN, Mask
  R-CNN+FPN, Cascade-Faster-RCNN+FPN, RetinaNet, Yolo v3, and SSD.
123 124 125 126


## Contributing

Y
Yang Zhang 已提交
127
Contributions are highly welcomed and we would really appreciate your feedback!!