Spaces:
Sleeping
Sleeping
Update src/text_to_speech.py
Browse files- src/text_to_speech.py +1 -1
src/text_to_speech.py
CHANGED
@@ -46,7 +46,7 @@ def text_to_speech(gender, speed):
|
|
46 |
for text_file in text_files:
|
47 |
with open(f"./text/{text_file}", "r", encoding="utf-8") as file:
|
48 |
content = file.read()
|
49 |
-
audio_file = text_file.replace("txt","
|
50 |
generate_audio(content, f"./audio/{audio_file}", gender=gender, speed=speed)
|
51 |
if __name__ == "__main__":
|
52 |
text_to_speech(gender = "female", speed = "fast")
|
|
|
46 |
for text_file in text_files:
|
47 |
with open(f"./text/{text_file}", "r", encoding="utf-8") as file:
|
48 |
content = file.read()
|
49 |
+
audio_file = text_file.replace("txt","mp3")
|
50 |
generate_audio(content, f"./audio/{audio_file}", gender=gender, speed=speed)
|
51 |
if __name__ == "__main__":
|
52 |
text_to_speech(gender = "female", speed = "fast")
|