All Projects → myhub → Tr

myhub / Tr

Licence: apache-2.0
Free Offline OCR 离线的中文文本检测+识别SDK

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Tr

insightocr
MXNet OCR implementation. Including text recognition and detection.
Stars: ✭ 100 (-83.28%)
Mutual labels:  ocr, text-recognition, crnn
Crnn.pytorch
crnn实现水平和垂直方向中文文字识别, 提供在3w多个中文字符训练的水平识别和垂直识别的预训练模型; 欢迎关注,试用和反馈问题... ...
Stars: ✭ 145 (-75.75%)
Mutual labels:  crnn, ocr, text-recognition
Crnn With Stn
implement CRNN in Keras with Spatial Transformer Network
Stars: ✭ 83 (-86.12%)
Mutual labels:  crnn, ocr, text-recognition
Deep Text Recognition Benchmark
Text recognition (optical character recognition) with deep learning methods.
Stars: ✭ 2,665 (+345.65%)
Mutual labels:  crnn, ocr, text-recognition
Sightseq
Computer vision tools for fairseq, containing PyTorch implementation of text recognition and object detection
Stars: ✭ 116 (-80.6%)
Mutual labels:  crnn, ocr, text-recognition
Ocr.pytorch
A pure pytorch implemented ocr project including text detection and recognition
Stars: ✭ 196 (-67.22%)
Mutual labels:  crnn, ocr, text-recognition
CRNN.tf2
Convolutional Recurrent Neural Network(CRNN) for End-to-End Text Recognition - TensorFlow 2
Stars: ✭ 131 (-78.09%)
Mutual labels:  ocr, crnn
CRNN
Convolutional recurrent neural network for scene text recognition or OCR in Keras
Stars: ✭ 96 (-83.95%)
Mutual labels:  ocr, text-recognition
MLKit
🌝 MLKit是一个强大易用的工具包。通过ML Kit您可以很轻松的实现文字识别、条码识别、图像标记、人脸检测、对象检测等功能。
Stars: ✭ 294 (-50.84%)
Mutual labels:  ocr, text-recognition
Chineseaddress ocr
Photographing Chinese-Address OCR implemented using CTPN+CTC+Address Correction. 拍照文档中文地址文字识别。
Stars: ✭ 309 (-48.33%)
Mutual labels:  ocr, text-recognition
NLP-image-to-text
code to extract text from images
Stars: ✭ 28 (-95.32%)
Mutual labels:  ocr, text-recognition
ocr
Simple app to extract text from pictures using Tesseract
Stars: ✭ 98 (-83.61%)
Mutual labels:  ocr, text-recognition
Crnn attention ocr chinese
CRNN with attention to do OCR,add Chinese recognition
Stars: ✭ 315 (-47.32%)
Mutual labels:  crnn, ocr
EverTranslator
Translate text anytime and everywhere, even you are gaming!
Stars: ✭ 59 (-90.13%)
Mutual labels:  ocr, text-recognition
kuzushiji-recognition
Kuzushiji Recognition Kaggle 2019. Build a DL model to transcribe ancient Kuzushiji into contemporary Japanese characters. Opening the door to a thousand years of Japanese culture.
Stars: ✭ 16 (-97.32%)
Mutual labels:  ocr, deeplearning
Printed-Chinese-Character-OCR
This is a Chinese Character ocr system based on Deep learning (VGG like CNN neural net work),this rep include trainning set generating,image preprocesing,NN model optimizing based on Keras high level NN framwork
Stars: ✭ 21 (-96.49%)
Mutual labels:  ocr, deeplearning
Vedastr
A scene text recognition toolbox based on PyTorch
Stars: ✭ 290 (-51.51%)
Mutual labels:  ocr, text-recognition
React Native Tesseract Ocr
Tesseract OCR wrapper for React Native
Stars: ✭ 384 (-35.79%)
Mutual labels:  ocr, text-recognition
Awesome Ocr Resources
A collection of resources (including the papers and datasets) of OCR (Optical Character Recognition).
Stars: ✭ 335 (-43.98%)
Mutual labels:  ocr, text-recognition
Attention Ocr Chinese Version
Attention OCR Based On Tensorflow
Stars: ✭ 421 (-29.6%)
Mutual labels:  crnn, text-recognition

tr - Text Recognition

一款针对扫描文档的离线文本识别SDK,核心代码全部采用C++开发,并提供Python接口

更新说明

  • c++接口支持
  • 支持Windows系统
  • 添加python2支持
  • 去除opencv-python、Pillow依赖,降低部署难度
  • 支持多线程
  • 支持GPU

Contact

Email: [email protected]

Requirements

  • Windows 7+/Ubuntu 16.04/Ubuntu 18.04
  • python2/python3,需要安装numpy
  • Windows系统需要安装VC_redist.x64.exe

GPU版本安装说明

如果对速度有要求,推荐安装GPU版本
要使用GPU版本,复制tr_gpu文件夹里面的文件到tr文件夹
注意: 需要先安装CUDA 10.1以及cuDNN 7.6.5

若不想安装CUDA/cuDNN,可以使用docker部署

docker pull mcr.microsoft.com/azureml/onnxruntime:v1.3.0-cuda10.1-cudnn7
sudo nvidia-docker run -v /path/to/tr:/path/to/tr --rm -it mcr.microsoft.com/azureml/onnxruntime:v1.3.0-cuda10.1-cudnn7

Install

  • 安装方法一
git clone https://github.com/myhub/tr.git
cd ./tr
sudo python setup.py install
  • 安装方法二
sudo pip install git+https://github.com/myhub/[email protected]

Test

python2 demo.py               # python2兼容测试     
python3 test.py               # 可视化测试
python3 test-multi-thread.py  # 多线程测试

关联项目

  • 若需要Web端调用,推荐参考TrWebOCR

Python Example

import tr

# detect text lines, return list of (cx, cy, width, height, angle)
print(tr.detect("imgs/web.png", tr.FLAG_RECT))

# detect text lines with angle, return list of (cx, cy, width, height, angle)
print(tr.detect("imgs/id_card.jpeg", tr.FLAG_ROTATED_RECT))

# recognize text line, return (text, confidence)
print(tr.recognize("imgs/line.png"))

# detect and recognize text lines with angle, return list of ((cx, cy, width, height, angle), text, confidence)
print(tr.run("imgs/id_card.jpeg"))

C++ Example

tr_init(0, 0, "crnn.bin", NULL);

#define MAX_WIDTH		512
int unicode[MAX_WIDTH];
float prob[MAX_WIDTH]; 

auto ws = tr_recognize(0, (void *)"line.png", 0, 0, 0, unicode, prob, MAX_WIDTH);

tr_release(0);

效果展示


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].