Skip to content

[WIP] A Pytorch implementation of DB-Text - Real-time Scene Text Detection with Differentiable Binarization

License

Notifications You must be signed in to change notification settings

huyhoang17/DB_text_minimal

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

51 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

A Pytorch implementation of DB-Text paper

Make awesome things that matter.

Command

Train model

  • Modify some configuration in config.yaml
make train

Test model

make test-all

Evaluate model

  • For evaluation metric, please refer to MegReader repository
# iou-based Pascal
make ioueval

# overlap-based DetEval
make deteval

History (on TotalText dataset)

Train data

Test data

Test dataset (TotalText)

Heatmap Polygon Rotated rectangle

Text-line detection (the model trained on CTW1500 dataset)

Image origin Text-line detected

Full pipeline

Metric evaluation (DetEval - P/R/HMean)

# for TotalText dataset
make deteval
Method image size init lr b-thresh p-thresh unclip ratio Precision Recall F-measure
TotalText-resnet18-fcn (word-level) 640 0.005 0.25 0.50 1.50 0.70 0.64 0.67
CTW1500-resnet18-fcn (line-level) 640 0.005 0.25 0.50 1.50 0.83 0.66 0.74

ToDo

  • Support datasets
  • Pytorch-lightning
  • Model serving with Torchserve
  • Metric callback (P/R/F1)
  • IoU-based metric (P/R/F1 - Pascal)
  • Overlap-based metric (P/R/F1 - DetEval)
  • Model quantization
  • Model pruning
  • Docker / docker-compose
  • ONNX, TensorRT
  • Text recognition model

Reference

I got a lot of code from DBNet.pytorch, thanks to @WenmuZhou

Releases

No releases published

Packages

No packages published