GithubHelp home page GithubHelp logo

crnn_ctc_tf2's Introduction

本项目基于tensorflow2.3.1构建了crnn+ctc文字识别模型
crnn模型采用了resnet18+lstm,backbone可选(resnet18或vggnet)
实现功能:
1 不定长文字训练和识别
2 tensorflow内嵌tensorrt加速
3 bacth数据文字识别(待更新)
-----------------------------------------------------------------
参数配置:
config.py
--base_dir 设置为项目所在路径
--train_anno 训练文件路径
--test_anno 测试文件路径
--img_root 图片文件路径
--save_model_path 训练模型保存路径
--pre_weight 预训练文件路径
--dict_file_path 字典文件路径
其它参数可保持不变
------------------------------------------------------------------
数据格式:
  图片相对于img_root的路径\t标签内容
exmaple:
  /line1/img_203.jpg\t天气真好
------------------------------------------------------------------
训练:
python main.py --type train
测试:
python main.py --type test --model_file {模型参数文件路径}
demo:
python main.py --model_file {模型文件路径} --img_path {图片路径}
--------------------------------------------------------------------
您也可以直接下载已经训练好的中文通用文字识别模型,下载地址 : 链接: https://pan.baidu.com/s/1mcxZmvzABE-L-4CRRUc85g  密码: v1cl
下载好之后修改demo.py中的模型路径,即可使用该模型,该模型使用的字典为dict文件夹下的ppocr_keys_v1,该字典来源于百度paddleocr中文字典

crnn_ctc_tf2's People

Contributors

ethanlighter avatar

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.