Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,8 @@ from tqdm import tqdm
|
|
12 |
import gradio as gr
|
13 |
|
14 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
|
|
|
|
15 |
|
16 |
class M5(nn.Module):
|
17 |
def __init__(self, n_input=1, n_output=35, stride=16, n_channel=32):
|
|
|
12 |
import gradio as gr
|
13 |
|
14 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
15 |
+
new_sample_rate = 8000
|
16 |
+
transform = torchaudio.transforms.Resample(orig_freq=sample_rate, new_freq=new_sample_rate)
|
17 |
|
18 |
class M5(nn.Module):
|
19 |
def __init__(self, n_input=1, n_output=35, stride=16, n_channel=32):
|