/ctc-ocr-pytorch

uni/bi directional LSTM+CTC on squential mnist for OCR

Primary LanguagePython

ctc-ocr-pytorch

This repo is based on pytorch-ocr and traines a Quantized as well as Full Precision BiLSTM with CTCLoss on squential mnist for OCR using pytorch. Visit the original repo for installation and other details. This is to be used with my LSTM-PYNQ fork.

Data

Quantized Training

Partially Quantized

python main.py -p quantized_settings/W4A8/partial.json

Fully Quantized Fine Tuning

python main.py -p quantized_settings/W4A8/finetune.json --init_bn_fc_fusion --resume <path to .tar>

Evaluate

python main.py --resume <path to .tar> --eval

Export Model with PEs and SIMD factor

python main.py --resume <path to .tar>  --export --pe 1 --simd_factor 8

Export test image

python main.py --resume <path to .tar>  --export_image

Speacial Thanks to