GithubHelp home page GithubHelp logo

hpc203 / ocr-opencv-dnn Goto Github PK

View Code? Open in Web Editor NEW
29.0 3.0 11.0 626 KB

用opencv的dnn模块做文本检测与识别,包含C++和Python两种版本的实现

Python 54.21% C++ 45.79%
ocr text-detection-recognition cpp python deep-learning

ocr-opencv-dnn's Introduction

极简主义OCR

在这个OCR程序中,文本检测用的是EAST,文本识别用的是CRNN,这套程序有Python和C++两种版本的实现。 这两个网络的前向推理依靠opencv的dnn模块实现的,整个程序的运行不依赖任何深度学习框架pytorch,tensorflow等等的。

Python版本的主程序是text_detect_recognition.py,C++版本的主程序是text_detect_recognition.cpp。 在运行程序前,要先下载模型文件放在同一目录下。 EAST模型的下载链接是:https://www.dropbox.com/s/r2ingd0l3zt8hxs/frozen_east_text_detection.tar.gz?dl=1

crnn的模型下载链接是:https://drive.google.com/drive/folders/1cTbQ3nuZG-EKWak6emD_s8_hHXWz7lAr

在编写这套程序时,我有一个疑惑,具体内容可参见我的CSDN博客文章: https://blog.csdn.net/nihate/article/details/108754622

2021年,我发布了使用DBNet做文字检测的程序,包含C++和Python两个版本的。可以把上面的程序里的文字检测模块EAST网络替换成DBNet

ocr-opencv-dnn's People

Contributors

hpc203 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

ocr-opencv-dnn's Issues

Can't parse 'pt1'. Sequence item with index 0 has a wrong type

`Traceback (most recent call last):
File "D:\CV2022\exepy\ocr-opencv-dnn-master\text_detect_recognition.py", line 216, in
cv.line(frame, p1, p2, (0, 255, 0), 1)
cv2.error: OpenCV(4.5.2) 👎 error: (-5:Bad argument) in function 'line'

Overload resolution failed:

  • Can't parse 'pt1'. Sequence item with index 0 has a wrong type
  • Can't parse 'pt1'. Sequence item with index 0 has a wrong type`

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.