-
Notifications
You must be signed in to change notification settings - Fork 46
Open
Description
I am using pre-trained model to get the embedding but getting below error:
RuntimeError Traceback (most recent call last)
<ipython-input-5-4bcf886e7e7f> in <module>
2 import torchaudio
3
----> 4 wav2mel = torch.jit.load("wav2mel.pt")
5 dvector = torch.jit.load("dvector.pt").eval()
6
~/anaconda3/lib/python3.8/site-packages/torch/jit/_serialization.py in load(f, map_location, _extra_files)
159 cu = torch._C.CompilationUnit()
160 if isinstance(f, str) or isinstance(f, pathlib.Path):
--> 161 cpp_module = torch._C.import_ir_module(cu, str(f), map_location, _extra_files)
162 else:
163 cpp_module = torch._C.import_ir_module_from_buffer(
RuntimeError:
Class Namespace cannot be used as a value:
Serialized File "code/__torch__/torchaudio/sox_effects/sox_effects.py", line 5
effects: List[List[str]],
channels_first: bool=True) -> Tuple[Tensor, int]:
in_signal = __torch__.torch.classes.torchaudio.TensorSignal.__new__(__torch__.torch.classes.torchaudio.TensorSignal)
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ <--- HERE
_0 = (in_signal).__init__(tensor, sample_rate, channels_first, )
out_signal = ops.torchaudio.sox_effects_apply_effects_tensor(in_signal, effects)
'apply_effects_tensor' is being compiled since it was called from 'SoxEffects.forward'
Serialized File "code/__torch__/data/wav2mel.py", line 29
wav_tensor: Tensor,
sample_rate: int) -> Tensor:
_0 = __torch__.torchaudio.sox_effects.sox_effects.apply_effects_tensor
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ <--- HERE
_1 = _0(wav_tensor, sample_rate, self.effects, True, )
wav_tensor1, _2, = _1
Metadata
Metadata
Assignees
Labels
No labels