Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -56,8 +56,8 @@ def similarity_fn(path1, path2):
|
|
56 |
if not (path1 and path2):
|
57 |
return '<b style="color:red">ERROR: Please record audio for *both* speakers!</b>'
|
58 |
|
59 |
-
wav1, _ =
|
60 |
-
wav2, _ =
|
61 |
print(wav1.shape, wav2.shape)
|
62 |
|
63 |
input1 = feature_extractor(wav1.squeeze(0), return_tensors="pt", sampling_rate=16000).input_values.to(device)
|
|
|
56 |
if not (path1 and path2):
|
57 |
return '<b style="color:red">ERROR: Please record audio for *both* speakers!</b>'
|
58 |
|
59 |
+
wav1, _ = apply_effects_tensor(*torchaudio.load(path1), EFFECTS)
|
60 |
+
wav2, _ = apply_effects_tensor(*torchaudio.load(path2), EFFECTS)
|
61 |
print(wav1.shape, wav2.shape)
|
62 |
|
63 |
input1 = feature_extractor(wav1.squeeze(0), return_tensors="pt", sampling_rate=16000).input_values.to(device)
|