How to set the model_path correctly

#1
by Wuweiraven - opened

When I tried to run your project using fairsq, I found that I wasn't sure how I should structure the project properly, and I didn't know whether model_path should specify a specific file or folder path (I tried both, but the program reported errors). I hope you can give me a tutorial on deploying your project

My fairseq version:
last commit: 965240c784910895b05e66d7ef7e15321050b414

fairseq use checkpoint: chinese-wav2vec2-large-fairseq-ckpt.pt

you should set the checkpint path (not a folder) in this config file
https://github.com/facebookresearch/fairseq/blob/main/examples/wav2vec/config/pretraining/wav2vec2_large_librivox.yaml#L8
you need to add restore_file

or

$ fairseq-hydra-train
distributed_training.distributed_port=$PORT
task.data=/path/to/data
model.w2v_path=chinese-wav2vec2-large-fairseq-ckpt.pt
--config-dir /path/to/fairseq-py/examples/wav2vec/config/finetuning
--config-name base_100h

Or continue pretrain:
https://github.com/facebookresearch/fairseq/blob/main/examples/wav2vec/config/finetuning/base_100h.yaml#L8

add restore_file: chinese-wav2vec2-large-fairseq-ckpt.pt

Sign up or log in to comment