Commit
Browse files
app.py
CHANGED
@@ -68,15 +68,15 @@ print(caption)
|
|
68 |
translated_caption = translate(caption)
|
69 |
print(translated_caption)
|
70 |
|
71 |
-
# Generate Audio
|
72 |
-
inputs = audio_processor(
|
73 |
-
|
74 |
-
|
75 |
-
)
|
76 |
-
|
77 |
-
speech_values = audio_model.generate(**inputs, do_sample=True)
|
78 |
-
|
79 |
-
sampling_rate = audio_model.generation_config.sample_rate
|
80 |
-
Audio(speech_values.cpu().numpy().squeeze(), rate=sampling_rate)
|
81 |
|
82 |
|
|
|
68 |
translated_caption = translate(caption)
|
69 |
print(translated_caption)
|
70 |
|
71 |
+
# # Generate Audio
|
72 |
+
# inputs = audio_processor(
|
73 |
+
# text=caption,
|
74 |
+
# return_tensors="pt",
|
75 |
+
# )
|
76 |
+
#
|
77 |
+
# speech_values = audio_model.generate(**inputs, do_sample=True)
|
78 |
+
#
|
79 |
+
# sampling_rate = audio_model.generation_config.sample_rate
|
80 |
+
# Audio(speech_values.cpu().numpy().squeeze(), rate=sampling_rate)
|
81 |
|
82 |
|