ilovin / lstm_ctc_ocr

Use CTC + tensorflow to OCR
https://ilovin.github.io/2017-04-06/tensorflow-lstm-ctc-ocr/
354 stars 140 forks source link
crnn tensorflow warpctc-tensorflow-binding

How to use

  1. ./train.sh

Dependency

Some details

The training data:
data

Notice that, parameters can be found in ./lstm.yml(higher priority) and lib/lstm/utils/config.y
some parameters need to be fined tune:

in ./lib/lstm/utils/gen.py, the height of the images are the same, and I pad the width to the same for each batch, so if you want to use your own data, the height of the image shall be the same.

Result

The accurary can be more that 95% acc

Read this blog for more details and this blog for how to use tf.nn.ctc_loss or warpCTC