Skip to content

MZT-DW/FOTS.PyTorch

 
 

Repository files navigation

News!!! Recognition branch now is added into model. The whole project has beed optimized and refactored.

  • ICDAR Dataset
  • SynthText 800K Dataset
  • detection branch (verified on the training set, It works!)
  • recognition branch (verified)
  • eval
  • multi-gpu training
  • reasonable project structure
  • wandb
  • pytorch_lightning

Introduction

This is a PyTorch implementation of FOTS.

Instruction

Requirements

  1. build tools

    ./build.sh
    
  2. prepare Dataset

  3. create virtual env, you may need conda

    conda create --name fots --file spec-file.txt
    conda activate fots
    pip install -r reqs.txt
    

Training

# quite easy, for single gpu training set gpus to [0]. 0 is the id of your gpu.
python train.py -c pretrain.json
python train.py -c finetune.json

Evaluation

python eval.py 
-c
finetune.json
-m
<your ckpt>
-i
<icdar2015 folder contains train and test>
--detection    
-o
./results
--cuda

with --detection flag to evaluate detection only or without flag to evaluate e2e

Benchmarking and Models (Coming soon!)

Visualization (1000 epochs, 8 bs, icdar2015 without finetuning, still converging!!!)

img_59.jpg img_108.jpg

Acknowledgement

About

FOTS Pytorch Implementation

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 56.1%
  • C++ 34.9%
  • Cuda 3.5%
  • Batchfile 2.1%
  • Shell 1.4%
  • Java 0.7%
  • Other 1.3%