Open unikcc opened 5 years ago
I have changed something with this model, did you train with this fork from scratch?
I have changed something with this model, did you train with this fork from scratch? Yes, I train it from scratch.. Since the default value of split_info is None, how can it be subscripted when the model is initialized. Or there's sth not committed
I am using griffin-lim
branch which does not contain split_infos
and have implemented batch synthesis on it and merged into mandarin-new
branch. I am afraid there is something in code not compitable with that branch. Sorry about it.
on branch mandarin-world-vocoder
, if I change max_frame_num
to 800, what effect will cause? I am using Biaobei 10000 corpus. 750 can only keep less than 5000 wav files. @begeekmyfriend
It depends on the frame period that equals to frame shift you are setting. The time length equals frame number multiply frame period.
many thanks !!
Hi, @begeekmyfriend , accouding to your explaination, in corpus : max_time length = max_frame_num frame_period, max_time_length = 750 0.015 = 11.25, but according to my statistics, the longest wav is 8.3s,is there something wrong?
max_frame_num
is just a threshold, not the actual length of your wav clip.
all right! I get it. Another issue, I use the latest pysptk package, occurs an error : mgc2sp() got an unexpected keyword argument 'order
, so which version of pysptk you used in the mandarin-world-vocoder
branch? The latest pysptk mgc2sp function does not contain the order parameter. And I did not found the pysptk in requirement.txt config file. @begeekmyfriend
@superhg2012 You need to copy the built so library into the python environment path manually.
python setup.py build
@superhg2012 You need to copy the built so library into the python environment path manually. python setup.py build
Hi, @begeekmyfriend I am runing your code on mandarin-world-vocoder
branch, In this branch, the pysptk package used as below as : def sp_denormalize(x, hparams): sp = pysptk.sptk.mgc2sp(x.astype(np.float64), order=hparams.num_mgc - 1, alpha=hparams.mcep_alpha, gamma=0.0, fftlen=hparams.fft_size) return np.square(sp / int16_max)
there is parameter order
. I use pip install pysptk
to install the latest pysptk, and run into error : mgc2sp() got an unexpected keyword argument 'order
, which mean you use an old version of pysptk. That's what I mean.
Is your branch of pysptk right?
Is your branch of pysptk right?
sorry, I use the https://github.com/r9y9/pysptk
this master branch
I pulled this branch and run python setup.py build
, but encouned a complition error: pysptk/_sptk.c:523:18: fatal error: SPTK.h: No such file or directory compilation terminated.
no idea to fix this...
git submodule update --init
git submodule update --init
it works, thanks!!
I have changed something with this model, did you train with this fork from scratch? Yes, I train it from scratch.. Since the default value of split_info is None, how can it be subscripted when the model is initialized. Or there's sth not committed
I have a question about 'I train it from scratch' ,what does this mean? thanks for your apply!!!!
I have changed something with this model, did you train with this fork from scratch? Yes, I train it from scratch.. Since the default value of split_info is None, how can it be subscripted when the model is initialized. Or there's sth not committed
For this question, how do you deal with it in the end?
The model of my fork is different from this upstream project and therefore we hold different training parameters. The pretrained model can not be run on my fork.
I also met this problem when I was trying to do tacotron GTA Synthesis to create data needed for Wavenet Training. It seems that it can not load the checkpoint properly during synthesis. I'm trying to fix this problem by retraining Tacotron using training_data and T2 code by Rayhane-mamah.
I think I've found a problem here. I tried to fix the error in tacotron GTA Synthesis. After fixing some small errors I found a bigger one. before mel out it is OK, but:
mel out: (?, ?, 80)
I do not recommend wavenet of this project. Please synthesize in GTA mode with mandarin-griffin-lim
branch and then train with WaveRNN.
Thank you so much for your help! When I try to load the checkpoint in mandarin-griffin-lim branch, it seems that there is something different in the checkpoints of mandarin-griffin-lim branch and mandarin-new branch , and an error occured.
Traceback (most recent call last): File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1334, in _do_call return fn(*args) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1319, in _run_fn options, feed_dict, fetch_list, target_list, run_metadata) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1407, in _call_tf_sessionrun run_metadata) tensorflow.python.framework.errors_impl.NotFoundError: Key model/inference/decoder/Location_Sensitive_Attention/attention_bias not found in checkpoint [[{{node save/RestoreV2}}]] [[{{node save/RestoreV2}}]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1276, in restore {self.saver_def.filename_tensor_name: save_path}) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 929, in run run_metadata_ptr) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1152, in _run feed_dict_tensor, options, run_metadata) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1328, in _do_run run_metadata) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/client/session.py", line 1348, in _do_call raise type(e)(node_def, op, message) tensorflow.python.framework.errors_impl.NotFoundError: Key model/inference/decoder/Location_Sensitive_Attention/attention_bias not found in checkpoint [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]] [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]]
Caused by op 'save/RestoreV2', defined at:
File "synthesize.py", line 65, in
NotFoundError (see above for traceback): Key model/inference/decoder/Location_Sensitive_Attention/attention_bias not found in checkpoint [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]] [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]]
During handling of the above exception, another exception occurred:
Traceback (most recent call last): File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1286, in restore names_to_keys = object_graph_key_mapping(save_path) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/training/saver.py", line 1591, in object_graph_key_mapping checkpointable.OBJECT_GRAPH_PROTO_KEY) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/pywrap_tensorflow_internal.py", line 370, in get_tensor status) File "/home/xxx/anaconda3/envs/tacotron2/lib/python3.6/site-packages/tensorflow/python/framework/errors_impl.py", line 528, in exit c_api.TF_GetCode(self.status.status)) tensorflow.python.framework.errors_impl.NotFoundError: Key _CHECKPOINTABLE_OBJECT_GRAPH not found in checkpoint
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "synthesize.py", line 65, in
Key model/inference/decoder/Location_Sensitive_Attention/attention_bias not found in checkpoint [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]] [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]]
Caused by op 'save/RestoreV2', defined at:
File "synthesize.py", line 65, in
NotFoundError (see above for traceback): Restoring from checkpoint failed. This is most likely due to a Variable name or other graph key that is missing from the checkpoint. Please ensure that you have not altered the graph expected based on the checkpoint. Original error:
Key model/inference/decoder/Location_Sensitive_Attention/attention_bias not found in checkpoint [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]] [[node save/RestoreV2 (defined at /home/xxx/Tacotron-2-mandarin-griffin-lim/tacotron/synthesizer.py:54) ]]
It is clear that model/inference/decoder/Location_Sensitive_Attention/attention_bias is not included in the checkpoint. If this problem is caused by different variable name, the checkpoint may be saved. If not, it would be a good choice to retrain it. T_T
Of course they are different. And I am focusing on mandarin-griffin-lim
and WaveRNN
now.
Thank you very much!
I have changed something with this model, did you train with this fork from scratch? Yes, I train it from scratch.. Since the default value of split_info is None, how can it be subscripted when the model is initialized. Or there's sth not committed
@nkhouse where able to proceed with this issue as split_infos is set to None
Here is my WaveRNN demo. Use mandarin-griffin-lim
branch, set linear_prediction
as False, synthesize GTA results and feed them into WaveRNN which is really faster than WaveNet. So I do not want to maintain mandarin-new
branch anymore.
wavernn_mandarin_male_22050.zip
hello, @begeekmyfriend ,tacotron2 Use mandarin-griffin-lim branch, set linear_prediction as False, synthesize GTA results ,shape of gta is 160 channels, when training WaveRNN , occur RuntimeError: Given groups=1, weight of size [128, 80, 5], expected input[32, 160, 9] to have 80 channels, but got 160 channels instead , but in https://github.com/fatchord/WaveRNN/blob/master/hparams.py, set num_mels = 80 to Settings for all models, if i change WaveRNN at hparams.py num_mels = 160 ,Are there other parameters that need to be modified? Is this reasonable?
Once it runs it is all right for you.
@begeekmyfriend I synthesis audio with pretrained model from BiaoBei, but there is abnormal sentence breaking, for example: "chang2 cheng2 shi4 gu3 dai4 zhong1 guo2 zai4 bu4 tong2 shi2 qi1", it break the "gu3" and "dai4", do you have any suggestion? Thank you. 2th sentence: "gang1 yi4 hao2 mai4 zhi2 zhuo2 pin1 bo2 de5 hai3 yang2 wen2 hua4 jing1 shen2"
Do not use any pretrained model since it might well be outdated.
By the way, please use mandarin-mel-prediction
branch plus WaveRNN
Thank you.
Traceback (most recent call last): File "demo_server.py", line 86, in
synth.load(checkpoint_path, modified_hp)
File "//PycharmProjects/Tacotron-2/tacotron/synthesizer.py", line 28, in load
self.model.initialize(inputs, input_lengths)
File "/PycharmProjects/Tacotron-2/tacotron/models/tacotron.py", line 64, in initialize
p_inputs = tf.py_func(split_func, [inputs, split_infos[:, 0]], lout_int)
TypeError: 'NoneType' object is not subscriptable
@begeekmyfriend
Hi, I get trouble with run your mandarin-new demo_server.py, I pull the lateset code, but It doesn't work. Seems hard to execute