ozipoetra
commited on
Commit
·
04c6849
1
Parent(s):
58c57f4
aaa
Browse files- app.py +2 -2
- weights/folder_info.json +2 -2
app.py
CHANGED
@@ -91,8 +91,8 @@ def create_vc_fn(model_name, tgt_sr, net_g, vc, if_f0, version, file_index):
|
|
91 |
return "You need to upload an audio", None
|
92 |
sampling_rate, audio = vc_upload
|
93 |
duration = audio.shape[0] / sampling_rate
|
94 |
-
if duration >
|
95 |
-
return "Please upload an audio file that is less than
|
96 |
audio = (audio / np.iinfo(audio.dtype).max).astype(np.float32)
|
97 |
if len(audio.shape) > 1:
|
98 |
audio = librosa.to_mono(audio.transpose(1, 0))
|
|
|
91 |
return "You need to upload an audio", None
|
92 |
sampling_rate, audio = vc_upload
|
93 |
duration = audio.shape[0] / sampling_rate
|
94 |
+
if duration > 60 and spaces:
|
95 |
+
return "Please upload an audio file that is less than 60 seconds. If you need to generate a longer audio file, please use Colab.", None
|
96 |
audio = (audio / np.iinfo(audio.dtype).max).astype(np.float32)
|
97 |
if len(audio.shape) > 1:
|
98 |
audio = librosa.to_mono(audio.transpose(1, 0))
|
weights/folder_info.json
CHANGED
@@ -3,12 +3,12 @@
|
|
3 |
"enable": true,
|
4 |
"title": "Main Character",
|
5 |
"folder_path": "Main",
|
6 |
-
"description": "
|
7 |
},
|
8 |
"Sumeru":{
|
9 |
"enable": true,
|
10 |
"title": "Sumeru",
|
11 |
"folder_path": "Sumeru",
|
12 |
-
"description": "
|
13 |
}
|
14 |
}
|
|
|
3 |
"enable": true,
|
4 |
"title": "Main Character",
|
5 |
"folder_path": "Main",
|
6 |
+
"description": "Be a Gentle men bruhhh"
|
7 |
},
|
8 |
"Sumeru":{
|
9 |
"enable": true,
|
10 |
"title": "Sumeru",
|
11 |
"folder_path": "Sumeru",
|
12 |
+
"description": "ah"
|
13 |
}
|
14 |
}
|