baudm / parseq

Scene Text Recognition with Permuted Autoregressive Sequence Models (ECCV 2022)
https://huggingface.co/spaces/baudm/PARSeq-OCR
Apache License 2.0
573 stars 127 forks source link

Highly overfit to training dataset #46

Open kikirizki opened 2 years ago

kikirizki commented 2 years ago

Hi @baudm thank you for your great works, I trained parseq-tiny model with Focused Scene Text Dataset + Incidental Scene Text Dataset, from (https://rrc.cvc.uab.es/), it contains around 4000+ images, after I trained for 300 epochs with default hyperparameter from this repo, it perform very well for training dataset and perform very poor for new unseen data, It seem the language model part overfit because when I tried new dataset, the wrong output usually are text that available in the training dataset, what do you think, do I need more dataset

baudm commented 1 year ago

A dataset that small + training schedule that long would definitely result in overfitting.

  1. Don't use the default hyperparameters.
  2. Try decoding with decode_ar=False and refine_iters=0.
kikirizki commented 1 year ago

@baudm Thank you so much for your response I will try it