Spaces:
Build error
Build error
Update inference.py
Browse files- inference.py +1 -1
inference.py
CHANGED
|
@@ -64,7 +64,7 @@ def infer(f,r,speaker,key,reqf0=False):
|
|
| 64 |
if sr<16000:
|
| 65 |
return "采样率过低,请上传至少拥有16000Hz采样率的音频",None
|
| 66 |
duration = audio.shape[0] / sr
|
| 67 |
-
print(audio
|
| 68 |
if duration > 120:
|
| 69 |
return "请上传小于2min的音频", None
|
| 70 |
#audio = (audio / np.iinfo(audio.dtype).max).astype(np.float32)
|
|
|
|
| 64 |
if sr<16000:
|
| 65 |
return "采样率过低,请上传至少拥有16000Hz采样率的音频",None
|
| 66 |
duration = audio.shape[0] / sr
|
| 67 |
+
print(audio,sr,duration)
|
| 68 |
if duration > 120:
|
| 69 |
return "请上传小于2min的音频", None
|
| 70 |
#audio = (audio / np.iinfo(audio.dtype).max).astype(np.float32)
|