Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,6 +1,7 @@
|
|
1 |
import os
|
2 |
import gradio as gr
|
3 |
from scipy.io.wavfile import write
|
|
|
4 |
import librosa
|
5 |
|
6 |
def resample_audio(audio, target_sample_rate):
|
@@ -10,6 +11,7 @@ def resample_audio(audio, target_sample_rate):
|
|
10 |
return target_sample_rate, resampled_audio_data
|
11 |
return audio
|
12 |
|
|
|
13 |
def inference(audio):
|
14 |
os.system("pwd")
|
15 |
os.makedirs("out", exist_ok=True)
|
|
|
1 |
import os
|
2 |
import gradio as gr
|
3 |
from scipy.io.wavfile import write
|
4 |
+
import spaces
|
5 |
import librosa
|
6 |
|
7 |
def resample_audio(audio, target_sample_rate):
|
|
|
11 |
return target_sample_rate, resampled_audio_data
|
12 |
return audio
|
13 |
|
14 |
+
@spaces.GPU
|
15 |
def inference(audio):
|
16 |
os.system("pwd")
|
17 |
os.makedirs("out", exist_ok=True)
|