DeepLearningExamples
DeepLearningExamples copied to clipboard
[HiFiGAN] Missing class variable in model ResBlock2
Related to PyTorch/SpeechSynthesis/HiFiGAN
Describe the bug
The class variable lrelu_slope
is used in the class method forward
but it is not defined. which raises an exception if HiFiGAN is trained with a parameter --resblock 2
. The variable is referenced here: https://github.com/NVIDIA/DeepLearningExamples/blob/d56fe703b034bf70d5e3aab4e1fec7bbe3d7735b/PyTorch/SpeechSynthesis/HiFiGAN/hifigan/models.py#L130
To Reproduce
Train HiFiGAN using the regular script (scripts/train.sh
), adding the input parameter --resblock 2
Expected behavior Training should run with no errors
Solution
Define the class variable in the __init__
method, similarly as in class ResBlock1
, that is add:
self.lrelu_slope = LRELU_SLOPE
Environment
- Container version: nvcr.io/nvidia/pytorch:22.12-py3
- GPUs in the system: 8X A40
- CUDA driver version: 520.61.05