http协议流式语音合成接口响应增加明确的分界点

pull/3362/head
Fantasy 2 years ago committed by GitHub
parent 94987f26df
commit c00173e812
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -466,7 +466,7 @@ class PaddleTTSConnectionHandler:
wav_base64 = base64.b64encode(wav_bytes).decode('utf8') # to base64
wav_list.append(wav)
yield wav_base64
yield wav_base64 + '\r\n'
wav_all = np.concatenate(wav_list, axis=0)
duration = len(wav_all) / self.tts_engine.sample_rate

Loading…
Cancel
Save