Skip to content
Snippets Groups Projects

Train

Use the teklia-dan train document command to train a new DAN model. It is able to train a DAN model at line or document-level and evaluate it.

Examples

Document

To train DAN on documents:

  1. Set your training configuration in dan/ocr/document/train.py. Refer to the dedicated section for a description of parameters.
  2. Run teklia-dan train document.
  3. Look into evaluation results in the output folder:
    • checkpoints contains model weights for the last trained epoch and for the epoch giving the best valid CER.
    • results contains the tensorboard log file, the parameters file, and the evaluation results for the best epoch.

Line

To train DAN on lines, run teklia-dan train document with a line dataset.

Additional page