mandarin-tts icon indicating copy to clipboard operation
mandarin-tts copied to clipboard

示例命令行有误

Open fa1c4 opened this issue 2 years ago • 1 comments

$ python ../../mtts/synthesize.py -d cuda --c config.yaml --checkpoint ./checkpoints/checkpoint_1240000.pth.tar -i input.txt usage: synthesize.py [-h] [-i INPUT] [--duration DURATION] [--output_dir OUTPUT_DIR] --checkpoint CHECKPOINT [-c CONFIG] [-d {cuda,cpu}] synthesize.py: error: ambiguous option: --c could match --checkpoint, --config

fa1c4 avatar Sep 14 '22 00:09 fa1c4

我做了下debug,很多底层错误被掩盖了,修改了好多地方:

  1. mtts文件夹下的models->vocoder->VocGan->model中的代码import 出错,我的修改办法是把models->vocoder->VocGan->utils拷贝至models->vocoder->VocGan->model中,重命名为xx,然后再generator.py中修改from .utils.utils为from .xx.utls;
  2. synthesize.py中的 lines = open(args.input).read().split('\n') 改为 lines = open(args.input,encoding='utf-8').read().split('\n')
  3. dataset.py中的所有open文件选项添加utf-8编码选择,同2;
  4. fs2_model.py中所有open文件选项添加utf-8编码选择,同2。

DukeDong avatar Jul 12 '23 03:07 DukeDong