w-okada / voice-changer

リアルタイムボイスチェンジャー Realtime Voice Changer
Other
16.4k stars 1.8k forks source link

Exception in ASGI application / VC Processing Exception #405

Closed KayaGG closed 1 year ago

KayaGG commented 1 year ago

Issue Type

Bug Report

vc client version number

MMVCServerSIO_win_onnxgpu-cuda_v.1.5.3.8a.zip

OS

Windows 10

GPU

3070 Ti

Clear setting

yes

Sample model

yes

Input chunk num

yes

Wait for a while

The GUI successfully launched.

read tutorial

yes

Voice Changer type

RVC

Model type

pyTorch

Situation

When switching between voices I will get 2 different errors. One stating that an exception in the ASGI application occured, the other saying there was a VC Processing exception and that there is no module named "_ctypes"

D:\RVC>MMVCServerSIO.exe -p 18888 --https false --content_vec_500 pretrain/checkpoint_best_legacy_500.pt --content_vec_500_onnx pretrain/checkpoint_best_legacy_500.onnx --content_vec_500_onnx_on false --hubert_base pretrain/hubert_base.pt --hubert_base_jp pretrain/rinna_hubert_base_jp.pt --hubert_soft pretrain/hubert/hubert-soft-0d54a1f4.pt --nsf_hifigan pretrain/nsf_hifigan/model --model_dir model_dir --samples samples.json Booting PHASE :main Voice Changerを起動しています。 ++[Voice Changer] model_dir is already exists. skip download samples. Internal_Port:18888 protocol: HTTP


ブラウザで次のURLを開いてください.
http://<IP>:<PORT>/
多くの場合は次のいずれかのURLにアクセスすると起動します。
http://localhost:18888/

Booting PHASE :__main__
Booting PHASE :MMVCServerSIO

[Voice Changer] model slot is changed -1 -> 0 ................RVC 2023-07-05 04:24:27 | INFO | faiss.loader | Loading faiss with AVX2 support. 2023-07-05 04:24:27 | INFO | faiss.loader | Could not load library with AVX2 support due to: ModuleNotFoundError("No module named 'faiss.swigfaiss_avx2'") 2023-07-05 04:24:27 | INFO | faiss.loader | Loading faiss. Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED (Use voice-changer-native-client --trace-warnings ... to show where the warning was created) 2023-07-05 04:24:29 | INFO | faiss.loader | Successfully loaded faiss. [Voice Changer] [RVC] Creating instance [Voice Changer] [RVC] Initializing... inferencerTypeinferencerTypeinferencerTypeinferencerType pyTorchRVCv2 gin_channels: 256 self.spk_embed_dim: 109 Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED [Voice Changer] generate new embedder. (no embedder) Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED Preparing your application. Please wait... (node:3884) electron: Failed to load URL: http://localhost:18888/ with error: ERR_CONNECTION_REFUSED [Voice Changer] Loading index... Try loading... model_dir\0\added_IVF139_Flat_nprobe_1_BO2Zombies_v2.index GENERATE INFERENCER <voice_changer.RVC.inferencer.RVCInferencerv2.RVCInferencerv2 object at 0x0000018C32149F00> GENERATE EMBEDDER <voice_changer.RVC.embedder.FairseqHubert.FairseqHubert object at 0x0000018C5DB32740> GENERATE PITCH EXTRACTOR <voice_changer.RVC.pitchExtractor.HarvestPitchExtractor.HarvestPitchExtractor object at 0x0000018C5DB327A0> [Voice Changer] [RVC] Initializing... done VoiceChanger Initialized (GPU_NUM:1, mps_enabled:False) [Voice Changer][RVC]: update_settings enableServerAudio 0 [Voice Changer][RVC]: update_settings serverOutputAudioGain 2 [Voice Changer][RVC]: update_settings serverInputDeviceId 9 [Voice Changer][RVC]: update_settings serverOutputDeviceId 20 [Voice Changer][RVC]: update_settings modelSlotIndex 1688555944000 [Voice Changer][RVC]: update_settings enableServerAudio 0 [Voice Changer][RVC]: update_settings serverOutputAudioGain 2 [Voice Changer][RVC]: update_settings serverInputDeviceId 9 [Voice Changer][RVC]: update_settings serverOutputDeviceId 20 [INFO] [DSH] voice-changer-native-client.exe [INFO] [DSH] Creating WndMsg Listener Window [INFO] [DSH] Get number of capabilities [INFO] [DSH] Get stream caps: 0 [INFO] [DSH] Get stream caps: 1 [INFO] [DSH] Get stream caps: 2 [INFO] [DSH] Get stream caps: 3 [INFO] [DSH] Get stream caps: 4 [INFO] [DSH] Get stream caps: 5 [INFO] [DSH] Get stream caps: 6 [INFO] [DSH] Get stream caps: 7 [INFO] [DSH] Get stream caps: 8 [INFO] [DSH] Get stream caps: 9 [INFO] [DSH] Get stream caps: 10 [INFO] [DSH] Get stream caps: 11 [INFO] [DSH] Get stream caps: 12 [INFO] [DSH] Get stream caps: 13 [INFO] [DSH] Get stream caps: 14 [INFO] [DSH] Get stream caps: 15 [INFO] [DSH] Get stream caps: 16 [INFO] [DSH] Get stream caps: 17 [INFO] [DSH] Get stream caps: 18 [INFO] [DSH] Get stream caps: 19 [INFO] [DSH] Get stream caps: 20 [INFO] [DSH] Get stream caps: 21 [INFO] [DSH] Get stream caps: 22 [INFO] [DSH] Get stream caps: 23 [INFO] [DSH] Get stream caps: 24 [INFO] [DSH] Get stream caps: 25 [INFO] [DSH] Get stream caps: 26 [INFO] [DSH] Get stream caps: 27 [INFO] [DSH] Get stream caps: 28 [INFO] [DSH] Get stream caps: 29 [INFO] [DSH] Get stream caps: 30 [INFO] [DSH] Get stream caps: 31 [INFO] [DSH] Get stream caps: 32 [INFO] [DSH] Destroying parent object [INFO] [DSH] Destroying WndMsg Listener Window [INFO] [DSH] Destroyed window [INFO] [DSH] Unregistered window class [2023-07-05 04:24:52] connet sid : ZOrDnaI7L6tCSxdaAAAB [2023-07-05 04:24:52] connet sid : rOHA9UibWv_PaJdCAAAD [Voice Changer] update configuration: modelSlotIndex 1688556296001 [Voice Changer] model slot is changed 0 -> 1 ................RVC [Voice Changer] [RVC] Creating instance [Voice Changer] [RVC] Initializing... inferencerTypeinferencerTypeinferencerTypeinferencerType onnxRVC 2023-07-05 04:25:01.7252797 [W:onnxruntime:, session_state.cc:1030 onnxruntime::VerifyEachNodeIsAssignedToAnEp] Some nodes were not assigned to the preferred execution providers which may or may not have an negative impact on performance. e.g. ORT explicitly assigns shape related ops to CPU to improve perf. 2023-07-05 04:25:01.7331050 [W:onnxruntime:, session_state.cc:1032 onnxruntime::VerifyEachNodeIsAssignedToAnEp] Rerunning with verbose output on a non-minimal build will show node assignments. [Voice Changer] embeder type is not match EnumEmbedderTypes.hubert hubert_base [Voice Changer] generate new embedder. (not match) [Voice Changer] Loading index... GENERATE INFERENCER <voice_changer.RVC.inferencer.OnnxRVCInferencer.OnnxRVCInferencer object at 0x0000018D8DF425C0> GENERATE EMBEDDER <voice_changer.RVC.embedder.FairseqHubert.FairseqHubert object at 0x0000018D8DF42590> GENERATE PITCH EXTRACTOR <voice_changer.RVC.pitchExtractor.HarvestPitchExtractor.HarvestPitchExtractor object at 0x0000018D8DF435E0> [Voice Changer] [RVC] Initializing... done VoiceChanger Initialized (GPU_NUM:1, mps_enabled:False) ---------- REMOVING --------------- [Voice Changer][RVC]: update_settings enableServerAudio 0 [Voice Changer][RVC]: update_settings serverOutputAudioGain 2 [Voice Changer][RVC]: update_settings serverInputDeviceId 9 [Voice Changer][RVC]: update_settings serverOutputDeviceId 20 [Voice Changer][RVC]: update_settings modelSlotIndex 1688556296001 ERROR: Exception in ASGI application Traceback (most recent call last): File "uvicorn\protocols\http\h11_impl.py", line 428, in run_asgi File "uvicorn\middleware\proxy_headers.py", line 78, in call File "engineio\async_drivers\asgi.py", line 67, in call File "fastapi\applications.py", line 284, in call File "starlette\applications.py", line 122, in call File "starlette\middleware\errors.py", line 184, in call File "starlette\middleware\errors.py", line 162, in call File "starlette\middleware\cors.py", line 83, in call File "starlette\middleware\exceptions.py", line 79, in call File "starlette\middleware\exceptions.py", line 68, in call File "fastapi\middleware\asyncexitstack.py", line 20, in call File "fastapi\middleware\asyncexitstack.py", line 17, in call File "starlette\routing.py", line 718, in call File "starlette\routing.py", line 276, in handle File "starlette\routing.py", line 66, in app File "fastapi\routing.py", line 241, in app File "fastapi\routing.py", line 169, in run_endpoint_function File "starlette\concurrency.py", line 41, in run_in_threadpool File "anyio\to_thread.py", line 33, in run_sync File "anyio_core_eventloop.py", line 147, in get_asynclib File "sniffio_impl.py", line 93, in current_async_library sniffio._impl.AsyncLibraryNotFoundError: unknown async library, or not in async context [25472:0705/042619.897:ERROR:gpu_init.cc(523)] Passthrough is not supported, GL is disabled, ANGLE is PyInstaller\loader\pyimod02_importers.py:385: UserWarning: The NumPy module was reloaded (imported a second time). This can in some cases result in small but subtle issues and is discouraged. [Voice Changer] VC PROCESSING EXCEPTION!!! No module named '_ctypes' Traceback (most recent call last): File "voice_changer\VoiceChanger.py", line 207, in on_request_sola File "resampy\core.py", line 168, in resample File "numba\np\ufunc\gufunc.py", line 188, in call File "numba\np\ufunc\gufunc.py", line 133, in _get_ewise_dtypes File "numba\np\ufunc\gufunc.py", line 131, in File "numba\core\typing\typeof.py", line 33, in typeof File "functools.py", line 889, in wrapper File "numba\core\typing\typeof.py", line 251, in _typeof_ndarray File "numba\core\types\abstract.py", line 67, in call File "numba\core\types\npytypes.py", line 461, in init File "numba\core\types\common.py", line 50, in init File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "numba__init.py", line 69, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "numba\core\config.py", line 16, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "llvmlite\binding\init.py", line 4, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "llvmlite\binding\dylib.py", line 1, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "ctypes\init__.py", line 8, in ModuleNotFoundError: No module named '_ctypes'

[Voice Changer] VC PROCESSING EXCEPTION!!! No module named '_ctypes' Traceback (most recent call last): File "voice_changer\VoiceChanger.py", line 207, in on_request_sola File "resampy\core.py", line 168, in resample File "numba\np\ufunc\gufunc.py", line 188, in call File "numba\np\ufunc\gufunc.py", line 133, in _get_ewise_dtypes File "numba\np\ufunc\gufunc.py", line 131, in File "numba\core\typing\typeof.py", line 33, in typeof File "functools.py", line 889, in wrapper File "numba\core\typing\typeof.py", line 251, in _typeof_ndarray File "numba\core\types\abstract.py", line 67, in call File "numba\core\types\npytypes.py", line 461, in init File "numba\core\types\common.py", line 50, in init File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "numba\core\types__init.py", line 4, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "numba\core\utils.py", line 25, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "numba\core\config.py", line 16, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "llvmlite\binding\init.py", line 4, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "llvmlite\binding\dylib.py", line 1, in File "PyInstaller\loader\pyimod02_importers.py", line 385, in exec_module File "ctypes\init__.py", line 8, in ModuleNotFoundError: No module named '_ctypes'`

KayaGG commented 1 year ago

Further note: This issue does not appear to happen on the previous version 1.5.3.8.zip

w-okada commented 1 year ago

mmmm, there is no change between 1.5.3.8 and 1.5.3.8a in server script. ...

KayaGG commented 1 year ago

Weird that it happens then, something must have changed though. Absolutely no idea what it could be though, good luck haha