w-okada / voice-changer

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

[ISSUE]: Voice changing usees CPU even though the GPU is selected as processing device #959

Closed retr0j12 closed 10 months ago

retr0j12 commented 10 months ago

Voice Changer Version

MMVCServerSIO_win_onnxdirectML-cuda_v.1.5.3.15

Operational System

Windows 11

GPU

RX 6800 XT

Read carefully and check the options

Model Type

RVC

Issue Description

image As you can see, even though gpu0 is selected it for some reason still uses my cpu, what proves that even more is that when i stop voice changing or close the app, cpu activity drops back to around 3-5%

Application Screenshot

image

Logs on console

[VCClient] Access http://127.0.0.1:18888/ [VCClient] wait web server...0 http://127.0.0.1:18888/ gin_channels: 256 self.spk_embed_dim: 109 [Voice Changer] generate new embedder. (no embedder) [Voice Changer] Loading index... Try loading... model_dir\6\added_IVF20_Flat_nprobe_1_Gojo_v2.index [VCClient] wait web server... done 200 [2023-10-18 19:18:35] connet sid : Xjlr0P4H26XTc46XAAAB [2023-10-18 19:18:35] connet sid : E1-0IQ70MoYaoShZAAAD [Voice Changer] update configuration: gpu 1 gin_channels: 256 self.spk_embed_dim: 109 [Voice Changer] generate new embedder. (anyway) EP Error D:\a_work\2\s\onnxruntime\core\providers\dml\dml_provider_factory.cc(132)\onnxruntime_pybind11_state.pyd!00007FF9F5392FFB: (caller: 00007FF9F5392D81) Exception(1) tid(4b60) C0262002 Specified display adapter handle is invalid. when using ['DmlExecutionProvider'] Falling back to ['CPUExecutionProvider'] and retrying. [Voice Changer] Loading index... Try loading... model_dir\6\added_IVF20_Flat_nprobe_1_Gojo_v2.index Pipeline has been deleted [Voice Changer] update configuration: gpu 0 gin_channels: 256 self.spk_embed_dim: 109 [Voice Changer] generate new embedder. (anyway) [Voice Changer] Loading index... Try loading... model_dir\6\added_IVF20_Flat_nprobe_1_Gojo_v2.index Pipeline has been deleted paramDict {'voiceChangerType': 'RVC', 'slot': 6, 'isSampleMode': False, 'sampleId': None, 'files': [{'name': 'Gojo_e600_s1800.pth', 'kind': 'rvcModel', 'dir': ''}, {'name': 'added_IVF20_Flat_nprobe_1_Gojo_v2.index', 'kind': 'rvcIndex', 'dir': ''}], 'params': {}} RVC:: slotInfo.modelFile Gojo_e600_s1800.pth [Voice Changer] Official Model(pyTorch) : v2 SlotInfo::: RVCModelSlot(slotIndex=-1, voiceChangerType='RVC', name='Gojo_e600_s1800', description='', credit='', termsOfUseUrl='', iconFile='', speakers={0: 'target'}, modelFile='Gojo_e600_s1800.pth', indexFile='added_IVF20_Flat_nprobe_1_Gojo_v2.index', defaultTune=0, defaultIndexRatio=0, defaultProtect=0.5, isONNX=False, modelType='pyTorchRVCv2', samplingRate=48000, f0=True, embChannels=768, embOutputLayer=12, useFinalProj=False, deprecated=False, embedder='hubert_base', sampleId='', version='v2') [Voice Changer] update configuration: modelSlotIndex 1697645974006 Pipeline has been deleted gin_channels: 256 self.spk_embed_dim: 109 [Voice Changer] generate new embedder. (anyway) [Voice Changer] Loading index... Try loading... model_dir\6\added_IVF20_Flat_nprobe_1_Gojo_v2.index

retr0j12 commented 10 months ago

After looking in it some more, i realised issue persists.

0RadicalLarry0 commented 10 months ago

you need to export all your models to onnx on amd

exciar commented 10 months ago

are you sure this isn't a pth model?

w-okada commented 10 months ago

I have no idea beacuse I have not used AMD GPU. But, gpt4 says your driver is outdated or corrupted about the message Exception(1) tid(4b60) C0262002 Specified display adapter handle is invalid.

This error message usually comes up when there's an issue with the graphics card driver or the graphics card itself. It could mean that the graphics card driver is outdated or corrupted, or the graphics card is not properly connected or is failing.

Here are few methods to fix this issue:

1. Update Graphics Card Driver: You can either visit the manufacturer's website to download the latest version of the driver or use the Windows Device Manager to update the driver.

2. Reinstall Graphics Card Driver: Uninstall the current graphics card driver from your system and install a new one.

3. Check Hardware: If the error still persists, check the graphics card hardware. It might be loosely fitted. It’s better to consult with a professional hardware expert in this case.

4. Try using another graphics card if you have one to determine if the graphics card is causing the issue. 

Remember to always backup your data before troubleshooting hardware issues, as it could lead to data loss.
w-okada commented 10 months ago

no res close