Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -13,6 +13,13 @@ import shutil
|
|
13 |
import warnings
|
14 |
warnings.filterwarnings("ignore")
|
15 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
16 |
# Import audio processing libraries
|
17 |
try:
|
18 |
from demucs.pretrained import get_model
|
@@ -139,7 +146,6 @@ __init__(self):
|
|
139 |
|
140 |
return vocals_path, instrumental_path
|
141 |
|
142 |
-
|
143 |
except Exception as e:
|
144 |
print(f"Basic separation error: {e}")
|
145 |
return None, None
|
@@ -366,7 +372,7 @@ def process_voice_samples(voice_files) -> str:
|
|
366 |
def create_interface():
|
367 |
with gr.Blocks(
|
368 |
title="🎵 AI Cover Song Platform",
|
369 |
-
# Removed theme=gr.themes.Soft for compatibility with Gradio versions < 4.0.0
|
370 |
css="""
|
371 |
.gradio-container {
|
372 |
font-family: 'Inter', sans-serif;
|
|
|
13 |
import warnings
|
14 |
warnings.filterwarnings("ignore")
|
15 |
|
16 |
+
# NLTK download for 'punkt' tokenizer data
|
17 |
+
import nltk
|
18 |
+
try:
|
19 |
+
nltk.data.find('tokenizers/punkt')
|
20 |
+
except nltk.downloader.DownloadError:
|
21 |
+
nltk.download('punkt')
|
22 |
+
|
23 |
# Import audio processing libraries
|
24 |
try:
|
25 |
from demucs.pretrained import get_model
|
|
|
146 |
|
147 |
return vocals_path, instrumental_path
|
148 |
|
|
|
149 |
except Exception as e:
|
150 |
print(f"Basic separation error: {e}")
|
151 |
return None, None
|
|
|
372 |
def create_interface():
|
373 |
with gr.Blocks(
|
374 |
title="🎵 AI Cover Song Platform",
|
375 |
+
# Removed theme=gr.themes.Soft for compatibility with Gradio versions < 4.0.0 (as per requirements.txt change)
|
376 |
css="""
|
377 |
.gradio-container {
|
378 |
font-family: 'Inter', sans-serif;
|