Spaces:
Runtime error
Runtime error
ASG Models
commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -25,8 +25,8 @@ def genrate_speech(text,name_model):
|
|
| 25 |
model=get_model(name_model)
|
| 26 |
with torch.no_grad():
|
| 27 |
wav=model(
|
| 28 |
-
input_ids=
|
| 29 |
-
attention_mask=
|
| 30 |
speaker_id=0
|
| 31 |
).waveform.cpu().numpy().reshape(-1)
|
| 32 |
return model.config.sampling_rate,wav
|
|
|
|
| 25 |
model=get_model(name_model)
|
| 26 |
with torch.no_grad():
|
| 27 |
wav=model(
|
| 28 |
+
input_ids= inputs.input_ids.to(device),
|
| 29 |
+
attention_mask=inputs.attention_mask.to(device),
|
| 30 |
speaker_id=0
|
| 31 |
).waveform.cpu().numpy().reshape(-1)
|
| 32 |
return model.config.sampling_rate,wav
|