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

Assertion error: torchaaudio resample_waveform related #11

Open
raikarsagar opened this issue Nov 16, 2020 · 3 comments
Open

Assertion error: torchaaudio resample_waveform related #11

raikarsagar opened this issue Nov 16, 2020 · 3 comments

Comments

@raikarsagar
Copy link

I am facing assertion error and the log is as follows:

Traceback (most recent call last):
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/utils/train.py", line 98, in train
disc_real, disc_real_multiscale = model_d(audioG, melG)
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/venv/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/model/hierarchical_discriminator.py", line 30, in forward
x_ = down_(x)
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/venv/lib/python3.6/site-packages/torch/nn/modules/module.py", line 532, in call
result = self.forward(*input, **kwargs)
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/venv/lib/python3.6/site-packages/torchaudio/transforms.py", line 382, in forward
return kaldi.resample_waveform(waveform, self.orig_freq, self.new_freq)
File "/home/stuart/sagar/speech_analysis_synth/VocGAN/venv/lib/python3.6/site-packages/torchaudio/compliance/kaldi.py", line 802, in resample_waveform
assert waveform.dim() == 2
AssertionError

Any wayouts from this issue will be helpful.
Thanks
Sagar

@rishikksh20
Copy link
Owner

your audio should be single channel, check weather you pass single or dual channel.

@raikarsagar
Copy link
Author

The files are fine because I was able to train with master branch. The issue persists with baseline branch.

@rishikksh20
Copy link
Owner

don't use that branch, that branch no more maintained.

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