README.md 12.9 KB
Newer Older
WenmuZhou's avatar
WenmuZhou committed
1
2
English | [简体中文](README_ch.md)

Leif's avatar
Leif committed
3
4
5
6
7
8
9
10
11
12
13
14
15
<p align="center">
 <img src="./doc/PaddleOCR_log.png" align="middle" width = "600"/>
<p align="center">
<p align="left">
    <a href="./LICENSE"><img src="https://img.shields.io/badge/license-Apache%202-dfd.svg"></a>
    <a href="https://github.com/PaddlePaddle/PaddleOCR/releases"><img src="https://img.shields.io/github/v/release/PaddlePaddle/PaddleOCR?color=ffa"></a>
    <a href=""><img src="https://img.shields.io/badge/python-3.7+-aff.svg"></a>
    <a href=""><img src="https://img.shields.io/badge/os-linux%2C%20win%2C%20mac-pink.svg"></a>
    <a href=""><img src="https://img.shields.io/pypi/format/PaddleOCR?color=c77"></a>
    <a href="https://pypi.org/project/PaddleOCR/"><img src="https://img.shields.io/pypi/dm/PaddleOCR?color=9cf"></a>
    <a href="https://github.com/PaddlePaddle/PaddleOCR/stargazers"><img src="https://img.shields.io/github/stars/PaddlePaddle/PaddleOCR?color=ccf"></a>
</p>

WenmuZhou's avatar
WenmuZhou committed
16
## Introduction
Leif's avatar
Leif committed
17

LDOUBLEV's avatar
LDOUBLEV committed
18
PaddleOCR aims to create multilingual, awesome, leading, and practical OCR tools that help users train better models and apply them into practice.
WenmuZhou's avatar
WenmuZhou committed
19

grasswolfs's avatar
grasswolfs committed
20

WenmuZhou's avatar
WenmuZhou committed
21
**Recent updates**
MissPenguin's avatar
MissPenguin committed
22
23
24
- 2021.12.21 release PaddleOCR v2.4, release 1 text detection algorithm (PSENet), 3 text recognition algorithms (NRTR、SEED、SAR), 1 key information extraction algorithm (SDMGR, [tutorial](./ppstructure/docs/kie_en.md)) and 3 DocVQA algorithms (LayoutLM, LayoutLMv2, LayoutXLM, [tutorial](./ppstructure/vqa)).
- 2021.9.7 release PaddleOCR v2.3, [PP-OCRv2](./doc/doc_en/ppocr_introduction_en.md#pp-ocrv2) is proposed. The inference speed of PP-OCRv2 is 220% higher than that of PP-OCR server in CPU device. The F-score of PP-OCRv2 is 7% higher than that of PP-OCR mobile.
- 2021.8.3 released PaddleOCR v2.2, add a new structured documents analysis toolkit, i.e., [PP-Structure](./ppstructure/README.md), support layout analysis and table recognition (One-key to export chart images to Excel files).
Leif's avatar
Leif committed
25

WenmuZhou's avatar
WenmuZhou committed
26
27
- [more](./doc/doc_en/update_en.md)

28

MissPenguin's avatar
update  
MissPenguin committed
29
## Features
WenmuZhou's avatar
WenmuZhou committed
30

MissPenguin's avatar
update  
MissPenguin committed
31
PaddleOCR support a variety of cutting-edge algorithms related to OCR, and developed industrial featured models/solution [PP-OCR](./doc/doc_en/ppocr_introduction_en.md) and [PP-Structure](./ppstructure/README.md) on this basis, and get through the whole process of data production, model training, compression, inference and deployment.
dyning's avatar
dyning committed
32

MissPenguin's avatar
update  
MissPenguin committed
33
![](./doc/features_en.png)
LDOUBLEV's avatar
LDOUBLEV committed
34

MissPenguin's avatar
update  
MissPenguin committed
35
> It is recommended to start with the “quick experience” in the document tutorial
LDOUBLEV's avatar
LDOUBLEV committed
36
37


WenmuZhou's avatar
WenmuZhou committed
38
## Quick Experience
dyning's avatar
dyning committed
39

MissPenguin's avatar
update  
MissPenguin committed
40
41
42
43
44
45
46
47
48
49
50
51
- Web online experience for the ultra-lightweight OCR: [Online Experience](https://www.paddlepaddle.org.cn/hub/scene/ocr)
- Mobile DEMO experience (based on EasyEdge and Paddle-Lite, supports iOS and Android systems): [Sign in to the website to obtain the QR code for  installing the App](https://ai.baidu.com/easyedge/app/openSource?from=paddlelite)
- One line of code quick use: [Quick Start](./doc/doc_en/quickstart_en.md)


<a name="book"></a>
## E-book: *Dive Into OCR*
- [Dive Into OCR 📚](./doc/doc_en/ocr_book_en.md)


<a name="Community"></a>
## Community
dyning's avatar
dyning committed
52

MissPenguin's avatar
update  
MissPenguin committed
53
54
55
- **Join us**👬: Scan the QR code below with your Wechat, you can join the official technical discussion group. Looking forward to your participation.
- **Contribution**🏅️: [Contribution page](./doc/doc_en/thirdparty.md) contains various tools and applications developed by community developers using PaddleOCR, as well as the functions, optimized documents and codes contributed to PaddleOCR. It is an official honor wall for community developers and a broadcasting station to help publicize high-quality projects.
- **Regular Season**🎁: The community regular season is a point competition for OCR developers, covering four types: documents, codes, models and applications. Awards are selected and awarded on a quarterly basis. Please refer to the [link](https://github.com/PaddlePaddle/PaddleOCR/issues/4982) for more details.
tink2123's avatar
tink2123 committed
56

LDOUBLEV's avatar
LDOUBLEV committed
57

grasswolfs's avatar
grasswolfs committed
58
<div align="center">
MissPenguin's avatar
update  
MissPenguin committed
59
<img src="https://raw.githubusercontent.com/PaddlePaddle/PaddleOCR/dygraph/doc/joinus.PNG"  width = "200" height = "200" />
grasswolfs's avatar
grasswolfs committed
60
</div>
dyning's avatar
dyning committed
61

WenmuZhou's avatar
WenmuZhou committed
62
63

<a name="Supported-Chinese-model-list"></a>
64
## PP-OCR Series Model List(Update on September 8th)
WenmuZhou's avatar
WenmuZhou committed
65
66
67

| Model introduction                                           | Model name                   | Recommended scene | Detection model                                              | Direction classifier                                         | Recognition model                                            |
| ------------------------------------------------------------ | ---------------------------- | ----------------- | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
littletomatodonkey's avatar
littletomatodonkey committed
68
69
| Chinese and English ultra-lightweight PP-OCRv3 model(16.2M)     | ch_PP-OCRv3_xx          | Mobile & Server | [inference model](https://paddleocr.bj.bcebos.com/PP-OCRv3/chinese/ch_PP-OCRv3_det_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv3/chinese/ch_PP-OCRv3_det_distill_train.tar) | [inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_train.tar) | [inference model](https://paddleocr.bj.bcebos.com/PP-OCRv3/chinese/ch_PP-OCRv3_rec_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv3/chinese/ch_PP-OCRv3_rec_train.tar) |
| English ultra-lightweight PP-OCRv3 model(13.4M)     | en_PP-OCRv3_xx          | Mobile & Server | [inference model](https://paddleocr.bj.bcebos.com/PP-OCRv3/english/en_PP-OCRv3_det_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv3/english/en_PP-OCRv3_det_distill_train.tar) | [inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_train.tar) | [inference model](https://paddleocr.bj.bcebos.com/PP-OCRv3/english/en_PP-OCRv3_rec_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv3/english/en_PP-OCRv3_rec_train.tar) |
LDOUBLEV's avatar
reset  
LDOUBLEV committed
70
| Chinese and English ultra-lightweight PP-OCRv2 model(11.6M) |  ch_PP-OCRv2_xx |Mobile & Server|[inference model](https://paddleocr.bj.bcebos.com/PP-OCRv2/chinese/ch_PP-OCRv2_det_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv2/chinese/ch_PP-OCRv2_det_distill_train.tar)| [inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_train.tar) |[inference model](https://paddleocr.bj.bcebos.com/PP-OCRv2/chinese/ch_PP-OCRv2_rec_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/PP-OCRv2/chinese/ch_PP-OCRv2_rec_train.tar)|
Leif's avatar
Leif committed
71
| Chinese and English ultra-lightweight PP-OCR model (9.4M)       | ch_ppocr_mobile_v2.0_xx      | Mobile & server   |[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_det_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_det_train.tar)|[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_train.tar) |[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_rec_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_rec_train.tar)      |
72
| Chinese and English general PP-OCR model (143.4M)               | ch_ppocr_server_v2.0_xx      | Server            |[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_server_v2.0_det_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_server_v2.0_det_train.tar)    |[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_train.tar)    |[inference model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_server_v2.0_rec_infer.tar) / [trained model](https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_server_v2.0_rec_train.tar)  |
LDOUBLEV's avatar
LDOUBLEV committed
73

WenmuZhou's avatar
WenmuZhou committed
74

MissPenguin's avatar
update  
MissPenguin committed
75
76
77
- For more model downloads (including multiple languages), please refer to [PP-OCR series model downloads](./doc/doc_en/models_list_en.md).
- For a new language request, please refer to [Guideline for new language_requests](#language_requests).
- For structural document analysis models, please refer to [PP-Structure models](./ppstructure/docs/models_list_en.md).
WenmuZhou's avatar
WenmuZhou committed
78
79

## Tutorials
Leif's avatar
Leif committed
80
- [Environment Preparation](./doc/doc_en/environment_en.md)
MissPenguin's avatar
update  
MissPenguin committed
81
82
83
84
- [PP-OCR 🔥](./doc/doc_en/ppocr_introduction_en.md)
    - [Quick Start](./doc/doc_en/quickstart_en.md)
    - [Model Zoo](./doc/doc_en/models_en.md)
    - [Model training](./doc/doc_en/training_en.md)
Leif's avatar
Leif committed
85
86
        - [Text Detection](./doc/doc_en/detection_en.md)
        - [Text Recognition](./doc/doc_en/recognition_en.md)
87
        - [Text Direction Classification](./doc/doc_en/angle_class_en.md)
MissPenguin's avatar
update  
MissPenguin committed
88
    - Model Compression
Leif's avatar
Leif committed
89
90
        - [Model Quantization](./deploy/slim/quantization/README_en.md)
        - [Model Pruning](./deploy/slim/prune/README_en.md)
MissPenguin's avatar
update  
MissPenguin committed
91
        - [Knowledge Distillation](./doc/doc_en/knowledge_distillation_en.md)
MissPenguin's avatar
update  
MissPenguin committed
92
    - [Inference and Deployment](./deploy/README.md)
MissPenguin's avatar
update  
MissPenguin committed
93
94
        - [Python Inference](./doc/doc_en/inference_ppocr_en.md)
        - [C++ Inference](./deploy/cpp_infer/readme.md)
Leif's avatar
Leif committed
95
        - [Serving](./deploy/pdserving/README.md)
MissPenguin's avatar
update  
MissPenguin committed
96
97
        - [Mobile](./deploy/lite/readme.md)
        - [Paddle2ONNX](./deploy/paddle2onnx/readme.md)
Leif's avatar
Leif committed
98
        - [Benchmark](./doc/doc_en/benchmark_en.md)  
MissPenguin's avatar
update  
MissPenguin committed
99
100
101
- [PP-Structure 🔥](./ppstructure/README.md)
    - [Quick Start](./ppstructure/docs/quickstart_en.md)
    - [Model Zoo](./ppstructure/docs/models_list_en.md)
102
    - [Model training](./doc/doc_en/training_en.md)  
MissPenguin's avatar
update  
MissPenguin committed
103
104
105
106
107
108
109
110
111
112
113
114
115
        - [Layout Parser](./ppstructure/layout/README.md)
        - [Table Recognition](./ppstructure/table/README.md)
        - [DocVQA](./ppstructure/vqa/README.md)
        - [Key Information Extraction](./ppstructure/docs/kie_en.md)
    - [Inference and Deployment](./deploy/README.md)
        - [Python Inference](./ppstructure/docs/inference_en.md)
        - [C++ Inference]()
        - [Serving](./deploy/pdserving/README.md)
- [Academic algorithms](./doc/doc_en/algorithms_en.md)
    - [Text detection](./doc/doc_en/algorithm_overview_en.md)
    - [Text recognition](./doc/doc_en/algorithm_overview_en.md)
    - [End-to-end](./doc/doc_en/algorithm_overview_en.md)
    - [Add New Algorithms to PaddleOCR](./doc/doc_en/add_new_algorithm_en.md)
LDOUBLEV's avatar
LDOUBLEV committed
116
- Data Annotation and Synthesis
grasswolfs's avatar
grasswolfs committed
117
    - [Semi-automatic Annotation Tool: PPOCRLabel](./PPOCRLabel/README.md)
dyning's avatar
dyning committed
118
    - [Data Synthesis Tool: Style-Text](./StyleText/README.md)
grasswolfs's avatar
grasswolfs committed
119
120
    - [Other Data Annotation Tools](./doc/doc_en/data_annotation_en.md)
    - [Other Data Synthesis Tools](./doc/doc_en/data_synthesis_en.md)
WenmuZhou's avatar
WenmuZhou committed
121
- Datasets
122
123
124
    - [General OCR Datasets(Chinese/English)](doc/doc_en/dataset/datasets_en.md)
    - [HandWritten_OCR_Datasets(Chinese)](doc/doc_en/dataset/handwritten_datasets_en.md)
    - [Various OCR Datasets(multilingual)](doc/doc_en/dataset/vertical_and_multilingual_datasets_en.md)
MissPenguin's avatar
update  
MissPenguin committed
125
- [Code Structure](./doc/doc_en/tree_en.md)
WenmuZhou's avatar
WenmuZhou committed
126
- [Visualization](#Visualization)
MissPenguin's avatar
update  
MissPenguin committed
127
- [Community](#Community)
LDOUBLEV's avatar
LDOUBLEV committed
128
- [New language requests](#language_requests)
WenmuZhou's avatar
WenmuZhou committed
129
130
131
- [FAQ](./doc/doc_en/FAQ_en.md)
- [References](./doc/doc_en/reference_en.md)
- [License](#LICENSE)
dyning's avatar
dyning committed
132

tink2123's avatar
tink2123 committed
133

MissPenguin's avatar
update  
MissPenguin committed
134
<a name="Visualization"></a>
WenmuZhou's avatar
WenmuZhou committed
135
136
## Visualization [more](./doc/doc_en/visualization_en.md)
- Chinese OCR model
dyning's avatar
dyning committed
137
<div align="center">
LDOUBLEV's avatar
LDOUBLEV committed
138
    <img src="./doc/imgs_results/ch_ppocr_mobile_v2.0/test_add_91.jpg" width="800">
LDOUBLEV's avatar
LDOUBLEV committed
139
140
    <img src="./doc/imgs_results/ch_ppocr_mobile_v2.0/00015504.jpg" width="800">
    <img src="./doc/imgs_results/ch_ppocr_mobile_v2.0/00056221.jpg" width="800">
LDOUBLEV's avatar
LDOUBLEV committed
141
    <img src="./doc/imgs_results/ch_ppocr_mobile_v2.0/rotate_00052204.jpg" width="800">
dyning's avatar
dyning committed
142
</div>
tink2123's avatar
tink2123 committed
143

WenmuZhou's avatar
WenmuZhou committed
144
- English OCR model
dyning's avatar
dyning committed
145
<div align="center">
LDOUBLEV's avatar
LDOUBLEV committed
146
    <img src="./doc/imgs_results/ch_ppocr_mobile_v2.0/img_12.jpg" width="800">
dyning's avatar
dyning committed
147
</div>
148

WenmuZhou's avatar
WenmuZhou committed
149
- Multilingual OCR model
dyning's avatar
dyning committed
150
<div align="center">
LDOUBLEV's avatar
LDOUBLEV committed
151
    <img src="./doc/imgs_results/french_0.jpg" width="800">
LDOUBLEV's avatar
LDOUBLEV committed
152
    <img src="./doc/imgs_results/korean.jpg" width="800">
dyning's avatar
dyning committed
153
</div>
tink2123's avatar
tink2123 committed
154

dyning's avatar
dyning committed
155

LDOUBLEV's avatar
LDOUBLEV committed
156
<a name="language_requests"></a>
157
## Guideline for New Language Requests
LDOUBLEV's avatar
LDOUBLEV committed
158

andyjpaddle's avatar
andyjpaddle committed
159
If you want to request a new language support, a PR with 1 following files are needed:
LDOUBLEV's avatar
LDOUBLEV committed
160

grasswolfs's avatar
grasswolfs committed
161
1. In folder [ppocr/utils/dict](./ppocr/utils/dict),
LDOUBLEV's avatar
LDOUBLEV committed
162
163
164
165
166
167
it is necessary to submit the dict text to this path and name it with `{language}_dict.txt` that contains a list of all characters. Please see the format example from other files in that folder.

If your language has unique elements, please tell me in advance within any way, such as useful links, wikipedia and so on.

More details, please refer to [Multilingual OCR Development Plan](https://github.com/PaddlePaddle/PaddleOCR/issues/1048).

MissPenguin's avatar
MissPenguin committed
168

WenmuZhou's avatar
WenmuZhou committed
169
170
<a name="LICENSE"></a>
## License
171
This project is released under <a href="https://github.com/PaddlePaddle/PaddleOCR/blob/master/LICENSE">Apache 2.0 license</a>