1 环境
1.opencv(https://sourceforge.net/projects/opencvlibrary/)
2.cmake(https://cmake.org/download/)
3.vs2019((https://github.com/PaddlePaddle/PaddleOCR/tree/release/2.1)
4.paddleOCR项目-建议2.0(https://github.com/PaddlePaddle/PaddleOCR/tree/release/2.1);
5:模型:
CLS:https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_det_infer.tar);
DET:https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_cls_infer.tar
REC:https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_server_v2.0_rec_infer.tar
6:预测库(https://paddleinference.paddlepaddle.org.cn/v2.0/user_guides/download_lib.html#windows)
主文件
环境设置
opencv复制
C++主文件
CMakeLists.txt
不同的电脑对用不同的open文件和预测包
CMake进行编译
vs要设置Release设置
修改config.cpp文件
修改utility.cpp文件
生成exe文件
tools文件
models
build文件
Release文件:
把paddle_inference_install_dir\paddle\lib\paddle_inference.dll文件复制到Releasewe文件里
ocr_system.exe C:\OCR\PaddleOCR-release-2.1\deploy\cpp_infer\tools\config.txt C:\OCR\PaddleOCR-release-2.1\doc\imgs\11.jpg