From 514f567b445f1f9d1b3db4af4cc9675e4d4a7887 Mon Sep 17 00:00:00 2001 From: lizhongxiang Date: Wed, 26 Feb 2025 17:43:34 +0800 Subject: [PATCH] =?UTF-8?q?add:=20=E9=83=A8=E7=BD=B2=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- config.yaml | 8 ++++---- fish_speech/utils/file.py | 2 -- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/config.yaml b/config.yaml index 961a27c1e..cf8066f44 100644 --- a/config.yaml +++ b/config.yaml @@ -92,10 +92,10 @@ TTS: FishSpeechTTS: url: http://192.168.101.242:10000/tts-fishspeech/v1/tts ref_audios: - - /opt/xiaozhi-es32-server/audio_ref/shinchan.wav - - /opt/xiaozhi-es32-server/audio_ref/shinchan2.wav - - /opt/xiaozhi-es32-server/audio_ref/shinchan3.wav - - /opt/xiaozhi-es32-server/audio_ref/shinchan4.wav + - audio_ref/shinchan.wav + - audio_ref/shinchan2.wav + - audio_ref/shinchan3.wav + - audio_ref/shinchan4.wav ref_texts: - "难过的事讨厌的事丢脸的事全都集中起来,在这里,让水冲走所有的烦恼不就好了吗。" - "我还是觉得船到桥头自然直这句话最棒了。" diff --git a/fish_speech/utils/file.py b/fish_speech/utils/file.py index a54c22655..af33a2595 100644 --- a/fish_speech/utils/file.py +++ b/fish_speech/utils/file.py @@ -39,8 +39,6 @@ def get_latest_checkpoint(path: Path | str) -> Path | None: def audio_to_bytes(file_path): - if not file_path or not Path(file_path).exists(): - return None with open(file_path, "rb") as wav_file: wav = wav_file.read() return wav