LSTMTRAINING(1)

πŸ’… lstmtraining(1) πŸ’…

okay bestie, welcome to lstmtraining(1) β€” literally the training program for LSTM-based networks, and yes she's iconic, yes she's a little extra, and yes we're gonna get through all of it together 🫢


✨ NAME ✨

lstmtraining β€” Training program for LSTM-based networks. that's it, that's the vibe πŸ’–


πŸ¦‹ SYNOPSIS πŸ¦‹

lstmtraining --continue_from  train_output_dir/continue_from_lang.lstm
--old_traineddata bestdata_dir/continue_from_lang.traineddata
--traineddata   train_output_dir/lang/lang.traineddata --max_iterations
NNN --debug_interval 0|-1 --train_listfile
train_output_dir/lang.training_files.txt --model_output
train_output_dir/newlstmmodel

🌸 DESCRIPTION 🌸

so lstmtraining(1) trains LSTM-based networks, and the main input situation is: a list of lstmf files πŸ“ plus a starter traineddata file. that's the whole main-character setup.

real talk though β€” training from scratch is not recommended to be done by users, no cap. like, don't. πŸ™ˆ

what you can do instead is finetuning (the example command up in the synopsis is literally the finetuning example, iykyk) or replacing a layer via the options. and heads up: different options apply to different types of training, so not every flag is gonna slay in every scenario.

read the training documentation for the details, bestie: https://tesseract-ocr.github.io/tessdoc/TrainingTesseract-4.00.html


πŸŽ€ OPTIONS πŸŽ€

  • --debug_interval β€” how often to display the alignment. (type: int default: 0)
  • --net_mode β€” controls network behavior. (type: int default: 192)
  • --perfect_sample_delay β€” how many imperfect samples between perfect ones. (type: int default: 0)
  • --max_image_MB β€” max memory to use for images. (type: int default: 6000)
  • --append_index β€” index in continue_from Network at which to attach the new network defined by net_spec. (type: int default: -1)
  • --max_iterations β€” if set, exit after this many iterations. a negative value is interpreted as epochs, 0 means infinite iterations. (type: int default: 0)
  • --target_error_rate β€” final error rate in percent. (type: double default: 0.01)
  • --weight_range β€” range of initial random weights. (type: double default: 0.1)
  • --learning_rate β€” weight factor for new deltas. (type: double default: 0.001)
  • --momentum β€” decay factor for repeating deltas. (type: double default: 0.5)
  • --adam_beta β€” decay factor for repeating deltas. (type: double default: 0.999)
  • --stop_training β€” just convert the training model to a runtime model. (type: bool default: false)
  • --convert_to_int β€” convert the recognition model to an integer model. (type: bool default: false)
  • --sequential_training β€” use the training files sequentially instead of round-robin. (type: bool default: false)
  • --debug_network β€” get info on distribution of weight values. (type: bool default: false)
  • --randomly_rotate β€” train OSD and randomly turn training samples upside-down. (type: bool default: false)
  • --net_spec β€” network specification. (type: string default: empty)
  • --continue_from β€” existing model to extend. (type: string default: empty)
  • --model_output β€” basename for output models. (type: string default: lstmtrain)
  • --train_listfile β€” file listing training files in lstmf training format. (type: string default: empty)
  • --eval_listfile β€” file listing eval files in lstmf training format. (type: string default: empty)
  • --traineddata β€” starter traineddata with combined Dawgs/Unicharset/Recoder for language model. (type: string default: empty)
  • --old_traineddata β€” when changing the character set, this specifies the traineddata with the old character set that is to be replaced. (type: string default: empty)

πŸ‘‘ HISTORY πŸ‘‘

lstmtraining(1) was first made available for tesseract4.00.00alpha. she's been serving since day one, periodt πŸ’…


🌈 RESOURCES 🌈


πŸ”₯ SEE ALSO πŸ”₯

  • tesseract(1) β€” the whole reason we're here, go read her too 🫢

πŸ“ COPYING πŸ“

Copyright (C) 2012 Google, Inc. Licensed under the Apache License, Version 2.0 β€” keep the license intact bestie, it's the law ✨


πŸ’œ AUTHOR πŸ’œ

The Tesseract OCR engine was written by Ray Smith and his research groups at Hewlett Packard (1985-1995) and Google (2006-2018). literal legends, no cap πŸ‘‘


okay that's the whole page, you ate that πŸ’… this was the lstmtraining(1) page, dated 2026-09-28 β€” go train something iconic, mwah πŸŽ€πŸ’–

πŸ“¦ where this page comes from