forked from DigitalPhonetics/IMS-Toucan
-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_prosody_override.py
20 lines (16 loc) · 1.2 KB
/
run_prosody_override.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import torch
from InferenceInterfaces.UtteranceCloner import UtteranceCloner
if __name__ == '__main__':
uc = UtteranceCloner(model_id="Meta", device="cuda" if torch.cuda.is_available() else "cpu")
uc.clone_utterance(path_to_reference_audio="audios/test.wav",
reference_transcription="Hello world, this is a test.",
filename_of_result="audios/test_cloned.wav",
clone_speaker_identity=False,
lang="en")
uc.biblical_accurate_angel_mode(path_to_reference_audio="audios/test.wav",
reference_transcription="Hello world, this is a test.",
filename_of_result="audios/test_cloned_angelic.wav",
list_of_speaker_references_for_ensemble=["audios/speaker_references_for_testing/female_high_voice.wav",
"audios/speaker_references_for_testing/female_mid_voice.wav",
"audios/speaker_references_for_testing/male_low_voice.wav"],
lang="en")