All Projects → alisen39 → Trwebocr

alisen39 / Trwebocr

Licence: apache-2.0
开源易用的中文离线OCR,识别率媲美大厂,并且提供了易用的web页面及web的接口,方便人类日常工作使用或者其他程序来调用~

Programming Languages

python
139335 projects - #7 most used programming language
python3
1442 projects

Projects that are alternatives of or similar to Trwebocr

Multi-Type-TD-TSR
Extracting Tables from Document Images using a Multi-stage Pipeline for Table Detection and Table Structure Recognition:
Stars: ✭ 174 (-71.84%)
Mutual labels:  ocr, ocr-recognition
LoL-TFT-Champion-Masking
League Of Legends - Teamfight Tactics Champion Masking
Stars: ✭ 23 (-96.28%)
Mutual labels:  ocr, ocr-recognition
EverTranslator
Translate text anytime and everywhere, even you are gaming!
Stars: ✭ 59 (-90.45%)
Mutual labels:  ocr, ocr-recognition
receipt-manager-app
Receipt parser application written in dart.
Stars: ✭ 140 (-77.35%)
Mutual labels:  ocr, ocr-recognition
OCR-Reader
An Android app to extract text from camera preview directly.
Stars: ✭ 43 (-93.04%)
Mutual labels:  ocr, ocr-recognition
deep-learning-for-document-dewarping
An application of high resolution GANs to dewarp images of perturbed documents
Stars: ✭ 100 (-83.82%)
Mutual labels:  ocr, ocr-recognition
nimtesseract
A Tesseract OCR wrapper for Nim
Stars: ✭ 23 (-96.28%)
Mutual labels:  ocr, ocr-recognition
Deep Text Recognition Benchmark
Text recognition (optical character recognition) with deep learning methods.
Stars: ✭ 2,665 (+331.23%)
Mutual labels:  ocr-recognition, ocr
Android-Text-Scanner
Read text and numbers with android camera OCR
Stars: ✭ 27 (-95.63%)
Mutual labels:  ocr, ocr-recognition
python-ocr-example
The code for the blogpost A Python Approach to Character Recognition
Stars: ✭ 54 (-91.26%)
Mutual labels:  ocr, ocr-recognition
Easyocr
Java OCR 识别组件(基于Tesseract OCR 引擎)。能自动完成图片清理、识别 CAPTCHA 验证码图片内容的一体化工作。Java Image cleanup, OCR recognition component (based Tesseract OCR engine, automatically cleanup image and identification CAPTCHA verification code picture content).
Stars: ✭ 466 (-24.6%)
Mutual labels:  ocr-recognition, ocr
Vedastr
A scene text recognition toolbox based on PyTorch
Stars: ✭ 290 (-53.07%)
Mutual labels:  ocr-recognition, ocr
Opencv
📷 Computer-Vision Demos
Stars: ✭ 244 (-60.52%)
Mutual labels:  ocr-recognition, ocr
ID-Card-Passport-Recognition-SDK-Android
On-Device ID Card & Passport & Driver License Recognition SDK for Android
Stars: ✭ 223 (-63.92%)
Mutual labels:  ocr, ocr-recognition
Awesome Ocr
Stars: ✭ 198 (-67.96%)
Mutual labels:  ocr-recognition, ocr
Transformer-ocr
Handwritten text recognition using transformers.
Stars: ✭ 92 (-85.11%)
Mutual labels:  ocr, ocr-recognition
Textshot
Python tool for grabbing text via screenshot
Stars: ✭ 1,163 (+88.19%)
Mutual labels:  ocr-recognition, ocr
Awesome Deep Text Detection Recognition
A curated list of resources for text detection/recognition (optical character recognition ) with deep learning methods.
Stars: ✭ 2,282 (+269.26%)
Mutual labels:  ocr-recognition, ocr
IdCardRecognition
Android id card recognition based on OCR. 安卓基于OCR的身份证识别。
Stars: ✭ 35 (-94.34%)
Mutual labels:  ocr, ocr-recognition
VehicleInfoOCR
Use your camera to read number plates and obtain vehicle details. Simple, ad-free and faster alternative to existing playstore apps
Stars: ✭ 35 (-94.34%)
Mutual labels:  ocr, ocr-recognition

TrWebOCR-开源的离线OCR

介绍

TrWebOCR,基于开源项目 Tr 构建。
在其基础上提供了http调用的接口,便于你在其他的项目中调用。
并且提供了易于使用的web页面,便于调试或日常使用。

web页面

特性

  • 中文识别
    快速高识别率

  • 文字检测
    支持一定角度的旋转

  • 并发请求
    由于模型本身不支持并发,但通过tornado多进程的方式,能支持一定数量的并发请求。具体并发数取决于机器的配置。

安装需求

运行平台

  • ✔ Python 3.6+
  • ✔ Ubuntu 16.04
  • ✔ ️Ubuntu 18.04
  • ✔ CentOS 7
  • ✔ Docker

Windows和MacOS系统下可通过构建Docker镜像来使用,暂不支持直接部署使用
其他Linux平台暂未测试,可自行安装测试

最低配置要求

  • CPU: 1核
  • 内存: 2G
  • SWAP: 2G

安装说明

服务器部署

  1. 安装python3.7
    推荐使用miniconda

  2. 安装依赖包

pip install -r requirements.txt
  1. 运行
    项目默认运行在8089端口,默认不开启gpu:
python backend/main.py [--port=8089][--open_gpu=0]
# --port 指定运行时端口号 默认是8089  
# --open_gpu 是否开启gpu 默认是0(不开启),可设置为1(开启)

看到以下输出则代表安装成功:

tr 2.3.0 https://github.com/myhub/tr
Server is running: http://192.168.31.95:8089
Now version is: cpu

Docker部署

使用 Dockerfile 构建 或者直接 Pull镜像

# dockerfile 构建
docker build -t trwebocr:latest .

# 运行镜像
docker run -itd --rm -p 8089:8089 --name trwebocr trwebocr:latest 
# 从 dockerhub pull
docker pull mmmz/trwebocr:latest

# 运行镜像
docker run -itd --rm -p 8089:8089 --name trwebocr mmmz/trwebocr:latest 

这里把容器的8089端口映射到了物理机的8089上,但如果你不喜欢映射,去掉run后面的-p 8089:8089 也可以使用docker的IP加8089来访问

接口文档

接口文档的内容放在了本项目的wiki里:
接口文档

接口调用示例

  • Python 使用File上传文件
import requests
url = 'http://192.168.31.108:8089/api/tr-run/'
img1_file = {
    'file': open('img1.png', 'rb')
}
res = requests.post(url=url, data={'compress': 0}, files=img1_file)
  • Python 使用Base64
import requests
import base64
def img_to_base64(img_path):
    with open(img_path, 'rb')as read:
        b64 = base64.b64encode(read.read())
    return b64
    
url = 'http://192.168.31.108:8089/api/tr-run/'
img_b64 = img_to_base64('./img1.png')
res = requests.post(url=url, data={'img': img_b64})

效果展示

文档识别

验证码识别

更新记录

  • 2020年08月17日
    更新Dockerfile,docker镜像支持tr2.3

  • 2020年07月30日
    支持启动命令选择GPU/CPU

  • 2020年07月26日
    更新tr2.0版,支持GPU

更多记录 >>>

License

Apache 2.0

鸣谢

  • 感谢 myhub 和它的开源项目Tr

最后

项目在 GitHub码云 上同步更新,国内朋友可以通过码云clone项目~

如果你也喜欢这个项目,不妨给个star (^.^)✨

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].