Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -116,14 +116,14 @@ def LLM_response(question_audio, question="Hello, what is your name?", voice = '
|
|
116 |
return None, None, None
|
117 |
|
118 |
@calculate_time
|
119 |
-
def Talker_response(question_audio = None, method = 'SadTalker', text = '', voice = '
|
120 |
if character == '女性角色':
|
121 |
# 女性角色
|
122 |
source_image, pic_path = r'inputs/girl.png', r'inputs/girl.png'
|
123 |
crop_pic_path = "./inputs/first_frame_dir_girl/girl.png"
|
124 |
first_coeff_path = "./inputs/first_frame_dir_girl/girl.mat"
|
125 |
crop_info = ((403, 403), (19, 30, 502, 513), [40.05956541381802, 40.17324339233366, 443.7892505041507, 443.9029284826663])
|
126 |
-
default_voice = '
|
127 |
elif character == '男性角色':
|
128 |
# 男性角色
|
129 |
source_image = r'./inputs/boy.png'
|
|
|
116 |
return None, None, None
|
117 |
|
118 |
@calculate_time
|
119 |
+
def Talker_response(question_audio = None, method = 'SadTalker', text = '', voice = 'en-GB-SoniaNeural', rate = 0, volume = 100, pitch = 0, batch_size = 2, character = '女性角色'):
|
120 |
if character == '女性角色':
|
121 |
# 女性角色
|
122 |
source_image, pic_path = r'inputs/girl.png', r'inputs/girl.png'
|
123 |
crop_pic_path = "./inputs/first_frame_dir_girl/girl.png"
|
124 |
first_coeff_path = "./inputs/first_frame_dir_girl/girl.mat"
|
125 |
crop_info = ((403, 403), (19, 30, 502, 513), [40.05956541381802, 40.17324339233366, 443.7892505041507, 443.9029284826663])
|
126 |
+
default_voice = 'en-GB-SoniaNeural'
|
127 |
elif character == '男性角色':
|
128 |
# 男性角色
|
129 |
source_image = r'./inputs/boy.png'
|