Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make trained model from checkpoint files #331

Open
z160896 opened this issue Feb 8, 2023 · 2 comments
Open

make trained model from checkpoint files #331

z160896 opened this issue Feb 8, 2023 · 2 comments

Comments

@z160896
Copy link

z160896 commented Feb 8, 2023

@zdenop I have come to the last hurdle! I can finish training the model successfully. I like to make the trained model from files in checkpoints dir from the instruction. can you help how to get it work. appreciated.

steps:

  1. make traineddata MODEL_NAME=hwmodel OUTPUT_DIR=data/hwmodel
  2. make training MODEL_NAME=hwmodel START_MODEL=eng LANG_TYPE=Eng
  3. make traineddata CHECKPOINT_FILES="$(find data/hwmodel/checkpoints -name '*.checkpoint' -mtime -21)" MODEL_NAME=hwmodel OUTPUT_DIR=/mnt/d/git
    make: *** No rule to make target 'data/hwmodel/tessdata_best/hwmodel_19.699000_9449_9800.checkpoint
    data/hwmodel/tessdata_best/hwmodel_20.407000_7080_7300.checkpoint
    data/hwmodel/tessdata_best/hwmodel_21.067000_6516_6700.checkpoint
    data/hwmodel/tessdata_best/hwmodel_21.878000_6042_6200.checkpoint
    data/hwmodel/tessdata_best/hwmodel_22.593000_4598_4700.checkpoint
    data/hwmodel/tessdata_best/hwmodel_23.559000_4120_4200.checkpoint
    data/hwmodel/tessdata_best/hwmodel_24.341000_3831_3900.checkpoint
    data/hwmodel/tessdata_best/hwmodel_25.543000_2463_2500.checkpoint
    data/hwmodel/tessdata_best/hwmodel_26.484000_2271_2300.checkpoint
    data/hwmodel/tessdata_best/hwmodel_27.441000_1980_2000.checkpoint
    data/hwmodel/tessdata_best/hwmodel_28.992000_1683_1700.checkpoint
    data/hwmodel/tessdata_best/hwmodel_30.096000_1491_1500.checkpoint
    data/hwmodel/tessdata_best/hwmodel_31.523000_1193_1200.checkpoint
    data/hwmodel/tessdata_best/hwmodel_32.787000_1093_1100.checkpoint
    data/hwmodel/tessdata_best/hwmodel_35.179000_796_800.checkpoint
    data/hwmodel/tessdata_best/hwmodel_36.494000_597_600.checkpoint
    data/hwmodel/tessdata_best/hwmodel_38.070000_399_400.checkpoint
    data/hwmodel/tessdata_best/hwmodel_39.380000_300_300.checkpoint
    data/hwmodel/tessdata_best/hwmodel_42.453000_200_200.checkpoint
    data/hwmodel/tessdata_best/hwmodel_45.193000_100_100.traineddata', needed by 'traineddata'. Stop.
@stale
Copy link

stale bot commented May 22, 2023

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the stale Issues which require input by the reporter which is not provided label May 22, 2023
@bertsky
Copy link
Collaborator

bertsky commented Mar 3, 2024

@z160896 to convert a checkpoint to a traineddata file, just do:

lstmtraining --stop_training --continue_from path/to/checkpoint --traineddata path/to/proto.traineddata --model_output path/to/trainedata

In your case, that should be:

lstmtraining --stop_training --continue_from data/hwmodel/tessdata_best/hwmodel_19.699000_9449_9800.checkpoint --traineddata data/hwmodel/hwmodel.traineddata --model_output data/hwmodel.traineddata

@stale stale bot removed the stale Issues which require input by the reporter which is not provided label Mar 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants