Spaces:
Runtime error
Runtime error
crowbarmassage
commited on
Commit
•
021c820
1
Parent(s):
b50b8b5
Update app.py
Browse files
app.py
CHANGED
@@ -80,11 +80,13 @@ def synthesise(text):
|
|
80 |
# Convert the embedding to a PyTorch tensor and add a batch dimension
|
81 |
#speaker_embeddings = torch.tensor(embedding_array).unsqueeze(0)
|
82 |
print(speaker_embeddings)
|
|
|
83 |
inputs = processor_tts(text=text, return_tensors="pt")
|
84 |
speech = model_tts.generate_speech(
|
85 |
inputs["input_ids"], speaker_embeddings, vocoder=vocoder
|
86 |
)
|
87 |
print(speech)
|
|
|
88 |
return speech
|
89 |
|
90 |
def speech_to_speech_translation(audio_filepath):
|
|
|
80 |
# Convert the embedding to a PyTorch tensor and add a batch dimension
|
81 |
#speaker_embeddings = torch.tensor(embedding_array).unsqueeze(0)
|
82 |
print(speaker_embeddings)
|
83 |
+
print(type(speaker_embeddings))
|
84 |
inputs = processor_tts(text=text, return_tensors="pt")
|
85 |
speech = model_tts.generate_speech(
|
86 |
inputs["input_ids"], speaker_embeddings, vocoder=vocoder
|
87 |
)
|
88 |
print(speech)
|
89 |
+
print(type(speech))
|
90 |
return speech
|
91 |
|
92 |
def speech_to_speech_translation(audio_filepath):
|