Browse Source
Update
Signed-off-by: Jael Gu <mengjia.gu@zilliz.com>
main
1 changed files with
1 additions and
1 deletions
-
torch_vggish.py
|
@ -42,6 +42,6 @@ class TorchVggish(Operator): |
|
|
|
|
|
|
|
|
def __call__(self, audio_path: str) -> NamedTuple('Outputs', [('embs', numpy.ndarray)]): |
|
|
def __call__(self, audio_path: str) -> NamedTuple('Outputs', [('embs', numpy.ndarray)]): |
|
|
audio_tensors = self.model.preprocess(audio_path) |
|
|
audio_tensors = self.model.preprocess(audio_path) |
|
|
features = self.model._model(audio_tensors) |
|
|
|
|
|
|
|
|
features = self.model(audio_tensors) |
|
|
Outputs = NamedTuple('Outputs', [('embs', numpy.ndarray)]) |
|
|
Outputs = NamedTuple('Outputs', [('embs', numpy.ndarray)]) |
|
|
return Outputs(features.detach().numpy()) |
|
|
return Outputs(features.detach().numpy()) |
|
|