GitHub

RapidAI /RapidOCR

๐Ÿ“„ Awesome OCR multiple programing languages toolkits based on ONNX Runtime, OpenVINO, MNN, PaddlePaddle, TensorRT and PyTorch.

โ˜… 8,431โ‘‚ 767๐Ÿ‘ 63โ‘ƒ 117โ— 288โ–ค 56
PythonCreated 2021-01-04rapidai.github.io/RapidOCRDocs
+0
Daily
+0
Weekly
+272
Monthly
8,431
stars
767
forks
63
watchers
117
prs
288
issues
56
releases

README

 

    Open source OCR for the security of the digital world

 





=3.8-aff.svg"








Join our Discord

็ฎ€ไฝ“ไธญๆ–‡ | English


 ๐Ÿ“ Introduction

RapidOCR is a completely open-source, free OCR tool that supports multi-platform, multi-language operation and rapid offline deployment. Its core advantages lie in extreme speed and extensive compatibility.

Supported Languages: Default support for Chinese and English recognition. For other supported languages, please refer to the documentation: Model List.

Project Origin: Considering that PaddleOCR still has room for optimization in engineering aspects, we innovatively converted the models in PaddleOCR into the highly compatible ONNX format to simplify and accelerate the inference deployment of OCR models on various terminal devices. Furthermore, we achieved seamless cross-platform porting based on multiple programming languages such as Python, C++, Java, and C, enabling developers to get started easily and integrate efficiently.

Name Implication: The name "RapidOCR" embodies our core expectations for the product: Rapid (simple operation, fast response), Good & Economical (low resource consumption, high cost-effectiveness), and Intelligent (achieving accurate and efficient recognition relying on deep learning technology). We focus on leveraging the advantages of artificial intelligence to create compact yet powerful models, relentlessly pursuing speed while ensuring excellent recognition results.

User Guide:

- Direct Deployment: If the models provided in this repository meet your needs, simply refer to the Official Documentation to quickly complete the deployment and usage of RapidOCR.
- Custom Fine-tuning: If the existing models cannot meet specific scenario requirements, you can fine-tune them using your own data based on PaddleOCR, and then apply the optimized models to the RapidOCR deployment process to achieve personalized customization.

If you find this project helpful for your work or study, we kindly ask you to give us a โญ Star to provide valuable support and encouragement!

 ๐ŸŽฅ Visualization


    


 ๐Ÿ› ๏ธ Installation

bash
pip install rapidocr onnxruntime


 ๐Ÿ“‹ Usage

python
from rapidocr import RapidOCR

engine = RapidOCR()

img_url = "https://www.modelscope.cn/models/RapidAI/RapidOCR/resolve/master/resources/test_files/ch_en_num.jpg"
result = engine(img_url)
print(result)

result.vis("vis_result.jpg")


 ๐Ÿณ Docker

Docker development environments are available for all supported inference engines:

bash
 Build and test with ONNX Runtime (CPU)
make build-onnxruntime-cpu
make test-onnxruntime-cpu

 Or use any engine: onnxruntime-gpu, tensorrt, paddle, openvino, pytorch, mnn
make build-tensorrt
make shell-tensorrt


See docker/README.md for full setup instructions, GPU configuration, and troubleshooting.

 ๐Ÿ“š Documentation

Full documentation can be found on docs, in Chinese.

 ๐Ÿ‘ฅ Who use? (more)

- Docling
- CnOCR
- api-for-open-llm
- arknights-mower
- pensieve
- genshin_artifact_auxilia

Snapshot: 2026-11-04T14:00:00Z ยท Data license Apache-2.0 ยท JSON