Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
|
@@ -379,7 +379,7 @@ def download_audio(url, cookie_file=None):
|
|
| 379 |
os.remove(temp_output_path)
|
| 380 |
logger.info(f"Temporary file deleted: {temp_output_path}")
|
| 381 |
|
| 382 |
-
@spaces.GPU
|
| 383 |
def roformer_separator(audio, model_key, seg_size, override_seg_size, overlap, pitch_shift, model_dir, output_dir, out_format, norm_thresh, amp_thresh, batch_size, exclude_stems="", progress=gr.Progress(track_tqdm=True)):
|
| 384 |
if not audio:
|
| 385 |
raise ValueError("No audio or video file provided.")
|
|
@@ -481,7 +481,7 @@ def roformer_separator(audio, model_key, seg_size, override_seg_size, overlap, p
|
|
| 481 |
torch.cuda.empty_cache()
|
| 482 |
logger.info("GPU memory cleared")
|
| 483 |
|
| 484 |
-
@spaces.GPU
|
| 485 |
def auto_ensemble_process(audio, model_keys, state, seg_size=64, overlap=0.1, out_format="wav", use_tta="False", model_dir="/tmp/audio-separator-models/", output_dir="output", norm_thresh=0.9, amp_thresh=0.9, batch_size=1, ensemble_method="avg_wave", exclude_stems="", weights_str="", progress=gr.Progress(track_tqdm=True)):
|
| 486 |
temp_audio_path = None
|
| 487 |
extracted_audio_path = None
|
|
|
|
| 379 |
os.remove(temp_output_path)
|
| 380 |
logger.info(f"Temporary file deleted: {temp_output_path}")
|
| 381 |
|
| 382 |
+
@spaces.GPU(duration=60)
|
| 383 |
def roformer_separator(audio, model_key, seg_size, override_seg_size, overlap, pitch_shift, model_dir, output_dir, out_format, norm_thresh, amp_thresh, batch_size, exclude_stems="", progress=gr.Progress(track_tqdm=True)):
|
| 384 |
if not audio:
|
| 385 |
raise ValueError("No audio or video file provided.")
|
|
|
|
| 481 |
torch.cuda.empty_cache()
|
| 482 |
logger.info("GPU memory cleared")
|
| 483 |
|
| 484 |
+
@spaces.GPU(duration=60)
|
| 485 |
def auto_ensemble_process(audio, model_keys, state, seg_size=64, overlap=0.1, out_format="wav", use_tta="False", model_dir="/tmp/audio-separator-models/", output_dir="output", norm_thresh=0.9, amp_thresh=0.9, batch_size=1, ensemble_method="avg_wave", exclude_stems="", weights_str="", progress=gr.Progress(track_tqdm=True)):
|
| 486 |
temp_audio_path = None
|
| 487 |
extracted_audio_path = None
|