Closed kirara233 closed 1 year ago
pip install pilk后已解决上述问题,新问题如下: Traceback (most recent call last): File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\pkg\huggingface_session_hash.py", line 47, in get_audio_wav f.write(requests.get(_get_audio_url()).content) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\pkg\huggingface_session_hash.py", line 24, in _get_audio_url ws.run_forever(ping_timeout=30, http_proxy_host=voice_config["proxy_host"], KeyError: 'proxy_host' [2023-03-16 13:22:22.877] main.py (19) - [ERROR] : wav生成失败 [2023-03-16 13:22:22.877] main.py (34) - [WARNING] : 未找到wav,pcm与silk文件
请重新拉取代码
请重新拉取代码 拉取并重启后: [2023-03-16 14:24:46.225] _logging.py (62) - [ERROR] : Handshake status 404 Not Found - goodbye [2023-03-16 14:24:48.120] host.py (314) - [ERROR] : 插件chat_voice触发事件normal_message_responded时发生错误 [2023-03-16 14:24:48.128] host.py (315) - [ERROR] : Traceback (most recent call last): File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\pkg\plugin\host.py", line 308, in emit hook(plugin['instance'], **kwargs) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\main.py", line 61, in person_normal_message_received uuid, msg = _get_voice_wav(kwargs['response_text']) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\main.py", line 21, in _get_voice_wav return hash_uuid, _wav2silk(hash_uuid) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\main.py", line 26, in _wav2silk return mirai.Voice(path=convert_to_silk(wav_path)) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\pkg\wav2silk.py", line 6, in convert_to_silk media = AudioSegment.from_file(media_path) File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\python\lib\site-packages\pydub\audio_segment.py", line 773, in from_file raise CouldntDecodeError( pydub.exceptions.CouldntDecodeError: Decoding failed. ffmpeg returned error code: 1
Output from ffmpeg/avlib:
ffmpeg version 5.1.2-full_build-www.gyan.dev Copyright (c) 2000-2022 the FFmpeg developers built with gcc 12.1.0 (Rev2, Built by MSYS2 project) configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml2 --enable-gmp --enable-bzlib --enable-lzma --enable-libsnappy --enable-zlib --enable-librist --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-libbluray --enable-libcaca --enable-sdl2 --enable-libaribb24 --enable-libdav1d --enable-libdavs2 --enable-libuavs3d --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libaom --enable-libjxl --enable-libopenjpeg --enable-libvpx --enable-mediafoundation --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-liblensfun --enable-libvidstab --enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libshaderc --enable-vulkan --enable-libplacebo --enable-opencl --enable-libcdio --enable-libgme --enable-libmodplug --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libshine --enable-libtheora --enable-libtwolame --enable-libvo-amrwbenc --enable-libilbc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libvorbis --enable-ladspa --enable-libbs2b --enable-libflite --enable-libmysofa --enable-librubberband --enable-libsoxr --enable-chromaprint libavutil 57. 28.100 / 57. 28.100 libavcodec 59. 37.100 / 59. 37.100 libavformat 59. 27.100 / 59. 27.100 libavdevice 59. 7.100 / 59. 7.100 libavfilter 8. 44.100 / 8. 44.100 libswscale 6. 7.100 / 6. 7.100 libswresample 4. 7.100 / 4. 7.100 libpostproc 56. 6.100 / 56. 6.100 C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT\voice_tmp\voice_6839693bc.wav: Invalid data found when processing input
国内使用需要配置代理
插件部署重载后运行,报错如下:
[2023-03-16 12:53:38.306] host.py (88) - [INFO] : 加载插件 [2023-03-16 12:53:38.321] host.py (82) - [ERROR] : 加载模块: plugins/chat_voice/main.py 失败: (<class 'ModuleNotFoundError'>, ModuleNotFoundError("No module named 'pilk'"), <traceback object at 0x00000230CA8BB840>) Traceback (most recent call last): File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\pkg\plugin\host.py", line 79, in walk_plugin_path importlib.import_module(module.name + '.' + item.name) File "importlib__init__.py", line 126, in import_module File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\main.py", line 9, in
from plugins.chat_voice.pkg.wav2silk import convert_to_silk
File "C:\Users\Administrator\Desktop\QQbot+VITS\QQbot\bot\QChatGPT.\plugins\chat_voice\pkg\wav2silk.py", line 1, in
import os, pilk
ModuleNotFoundError: No module named 'pilk'
附设置项: voice_config = { "open": True, #默认开关 "character": '派蒙 Paimon (Genshin Impact)', #希望生成声音的角色 "language": '简体中文', #生成文本的语言['简体中文','日本語','English','Mix'] "audio_speed": '1', #播放速度,可为保留一位小数点的小数[0.1 - 5] "download_url":'https://magic233-vits-umamusume-voice-synthesizer.hf.space/file=', #填入刚复制以https开头的链接 "websocket":'wss://magic233-vits-umamusume-voice-synthesizer.hf.space/queue/join', #填入以wss开头的websocket链接 "limitLength":256, #设置语音文字限长 0为无限制
"proxy_host": "127.0.0.1", #代理ip
}