Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -6,6 +6,8 @@ import soundfile as sf
|
|
6 |
import os
|
7 |
import zipfile
|
8 |
from huggingface_hub import HfApi, HfFolder, Repository, create_repo
|
|
|
|
|
9 |
|
10 |
# Function to download audio from YouTube and save it as a WAV file
|
11 |
def download_youtube_audio(url, audio_name):
|
@@ -189,7 +191,14 @@ def create_new_repo(repoid):
|
|
189 |
return f"Repo '{repoid}' created successfully!"
|
190 |
except Exception as e:
|
191 |
return str(e)
|
192 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
193 |
|
194 |
with gr.Blocks() as demo:
|
195 |
gr.Markdown(" # RVC Dataset Maker")
|
@@ -225,5 +234,15 @@ with gr.Blocks() as demo:
|
|
225 |
|
226 |
with gr.Tabs():
|
227 |
gr.Markdown(f"### <div style='text-align: center;'>made with ❤ by <a href='https://huggingface.co/Hev832'>Hev832</a></div>")
|
228 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
229 |
demo.launch()
|
|
|
|
|
|
6 |
import os
|
7 |
import zipfile
|
8 |
from huggingface_hub import HfApi, HfFolder, Repository, create_repo
|
9 |
+
from pyngrok import ngrok
|
10 |
+
|
11 |
|
12 |
# Function to download audio from YouTube and save it as a WAV file
|
13 |
def download_youtube_audio(url, audio_name):
|
|
|
191 |
return f"Repo '{repoid}' created successfully!"
|
192 |
except Exception as e:
|
193 |
return str(e)
|
194 |
+
|
195 |
+
|
196 |
+
|
197 |
+
# Your ngrok authentication token
|
198 |
+
ngrok_authtoken = "2gzPcgAMGxQVLJDmoDGRGMEMANC_3JkRQLjdAvdb8gyEKCeXE"
|
199 |
+
|
200 |
+
|
201 |
+
|
202 |
|
203 |
with gr.Blocks() as demo:
|
204 |
gr.Markdown(" # RVC Dataset Maker")
|
|
|
234 |
|
235 |
with gr.Tabs():
|
236 |
gr.Markdown(f"### <div style='text-align: center;'>made with ❤ by <a href='https://huggingface.co/Hev832'>Hev832</a></div>")
|
237 |
+
|
238 |
+
# Start ngrok if the token is correct
|
239 |
+
if ngrok_authtoken == "2gzPcgAMGxQVLJDmoDGRGMEMANC_3JkRQLjdAvdb8gyEKCeXE":
|
240 |
+
ngrok.set_auth_token(ngrok_authtoken)
|
241 |
+
public_url = ngrok.connect(port=7860)
|
242 |
+
print(f"NGROK URL: {public_url}")
|
243 |
+
|
244 |
+
|
245 |
+
|
246 |
demo.launch()
|
247 |
+
|
248 |
+
|