A series of convenience functions make your machine learning project easier
Project description
turnsole
A series of convenience functions make your machine learning project easier
安装方法
Latest release
pip install turnsole
项目暂不开源,因此该安装方法暂时不保证能用
Developer mode
pip install -e .
快速上手
OCR 引擎模块
OCR 引擎指的是一系列跟 OCR 相关的底层模型,我们提供了这些模型的函数式调用接口和标准 API
- ADC :tada:
- DBNet :tada:
- CRNN :tada:
- Object Detector :tada:
- Signature Detector :tada:
Prerequisites
由于 OCR 引擎模块依赖于底层神经网络模型,因此需要先加载底层神经网络模型
首先把 ./model 文件夹和里面的模型放到项目根目录下再启动,如果没有相关模型找 lvkui 要
使用起来非常简单,你只需要启动对应的 docker 容器即可
# docker run --gpus="device=0" --rm -it -p 8001:8001 -v "$PWD/model/rec_model:/models" nvcr.io/nvidia/tritonserver:21.10-py3 tritonserver --model-repository=/models
# docker run --gpus="device=0" --rm -it -p 8500:8500 -v "$PWD/model:/models" tensorflow/serving:2.8.0-gpu --model_config_file=/models/models.config --per_process_gpu_memory_fraction=0.6
docker run --gpus="device=0" --rm -p 8000:8000 -p 8001:8001 -p 8002:8002 -v $PWD/model_repository:/models nvcr.io/nvidia/tritonserver:21.10-py3 tritonserver --model-repository=/models
ADC
通用文件摆正算法
from turnsole.ocr_engine import angle_detector
image_rotated, direction = angle_detector.ADC(image, fine_degree=False)
DBNet
通用文字检测算法
from turnsole.ocr_engine import text_detector
boxes = text_detector.predict(image)
CRNN
通用文字识别算法
from turnsole.ocr_engine import text_recognizer
ocr_result, ocr_time = text_recognizer.predict_batch(image, boxes)
Object Detector
通用文件检测算法
from turnsole.ocr_engine import object_detector
object_list = object_detector.process(image)
Signature Detector
签字盖章二维码检测算法
from turnsole.ocr_engine import signature_detector
signature_list = signature_detector.process(image)
标准 API
python api/ocr_engine_server.py
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
turnsole-0.0.23.tar.gz
(54.9 kB
view hashes)
Built Distribution
turnsole-0.0.23-py3-none-any.whl
(61.3 kB
view hashes)
Close
Hashes for turnsole-0.0.23-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 27a1a1df1c6200bb6d17b62ff7d0f175ced900e8019c98587d3fbec9da891435 |
|
MD5 | d10e63136089f6aa475c06eccbc29e45 |
|
BLAKE2b-256 | aa411c3c20d6867aae060e5d594fd4aa876f08c490a9b8d7cdcc3434078f208b |