[GH-ISSUE #2569] In AMD graphics card environment, normal model inference cannot be performed(Amd显卡环境下,无法正常模型推理) #1825

Open
opened 2026-10-20 10:12:21 +00:00 by bsakaguchi · 0 comments
Owner

Originally created by @taxiyo568563 on GitHub (May 4, 2025).
Original GitHub issue: https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI/issues/2569

2025-05-04 16:19:38 | INFO | infer.modules.vc.pipeline | Loading rmvpe model,assets/rmvpe/rmvpe.pt
2025-05-04 16:19:39.0235339 [W:onnxruntime:, session_state.cc:1169 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.
2025-05-04 16:19:39.0267376 [W:onnxruntime:, session_state.cc:1171 onnxruntime::VerifyEachNodeIsAssignedToAnEp] Rerunning with verbose output on a non-minimal build will show node assignments.

The first run caused a CPU not being assigned problem, and then the program closed
第一次运行出现CPU未被指定问题,而后程序关闭

I checked the method on the Internet and added CPUExecutionProvider in line 509 of infer/lib/rmvpe.py as follows:
查看了网络上的方法在infer/lib/rmvpe.py中第509行添加CPUExecutionProvider,如下:

            ort_session = ort.InferenceSession(
                "%s/rmvpe.onnx" % os.environ["rmvpe_root"],
                providers=["DmlExecutionProvider","CPUExecutionProvider"],
            )

run again
再次运行

2025-05-04 16:54:38 | INFO | infer.modules.vc.modules | Get sid: manbo.pth
2025-05-04 16:54:38 | INFO | infer.modules.vc.modules | Loading: assets/weights/manbo.pth
2025-05-04 16:54:39 | INFO | infer.modules.vc.modules | Select index: logs\manbo.index
2025-05-04 16:54:46 | INFO | infer.modules.vc.pipeline | Loading rmvpe model,assets/rmvpe/rmvpe.pt
PS D:\project\RVC1006AMD_Intel1> 

Direct exit
直接退出

I have considered whether it is because my graphics card does not support DML, but after a simple test, I was able to successfully obtain a DirectML device using torch_directml in the runtime environment.
我有考虑过是否是我的显卡并不支持dml的问题,但是经过简单的测试我是能够使用runtime环境下的torch_directml成功获取一个DirectML设备的

张量设备: privateuseone:0
tensor([[ 0.6758, -2.9957, -0.3441,  1.1802,  2.8596],
        [-0.3263, -0.5613,  5.0377,  1.9721, -5.7863],
        [-0.4791, -1.5366, -0.3796,  0.8453,  0.2500],
        [ 1.9109, -0.0828,  1.6587,  0.7128, -0.4209],
        [-1.9032, -2.2359,  1.0701, -0.3013,  1.3471]],
       device='privateuseone:0')

I am not very good at learning, please help me
学艺不精,请求各位的援助

Originally created by @taxiyo568563 on GitHub (May 4, 2025). Original GitHub issue: https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI/issues/2569 ``` 2025-05-04 16:19:38 | INFO | infer.modules.vc.pipeline | Loading rmvpe model,assets/rmvpe/rmvpe.pt 2025-05-04 16:19:39.0235339 [W:onnxruntime:, session_state.cc:1169 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. 2025-05-04 16:19:39.0267376 [W:onnxruntime:, session_state.cc:1171 onnxruntime::VerifyEachNodeIsAssignedToAnEp] Rerunning with verbose output on a non-minimal build will show node assignments. ``` The first run caused a CPU not being assigned problem, and then the program closed 第一次运行出现CPU未被指定问题,而后程序关闭 I checked the method on the Internet and added CPUExecutionProvider in line 509 of infer/lib/rmvpe.py as follows: 查看了网络上的方法在infer/lib/rmvpe.py中第509行添加CPUExecutionProvider,如下: ``` ort_session = ort.InferenceSession( "%s/rmvpe.onnx" % os.environ["rmvpe_root"], providers=["DmlExecutionProvider","CPUExecutionProvider"], ) ``` run again 再次运行 ``` 2025-05-04 16:54:38 | INFO | infer.modules.vc.modules | Get sid: manbo.pth 2025-05-04 16:54:38 | INFO | infer.modules.vc.modules | Loading: assets/weights/manbo.pth 2025-05-04 16:54:39 | INFO | infer.modules.vc.modules | Select index: logs\manbo.index 2025-05-04 16:54:46 | INFO | infer.modules.vc.pipeline | Loading rmvpe model,assets/rmvpe/rmvpe.pt PS D:\project\RVC1006AMD_Intel1> ``` Direct exit 直接退出 I have considered whether it is because my graphics card does not support DML, but after a simple test, I was able to successfully obtain a DirectML device using torch_directml in the runtime environment. 我有考虑过是否是我的显卡并不支持dml的问题,但是经过简单的测试我是能够使用runtime环境下的torch_directml成功获取一个DirectML设备的 ``` 张量设备: privateuseone:0 tensor([[ 0.6758, -2.9957, -0.3441, 1.1802, 2.8596], [-0.3263, -0.5613, 5.0377, 1.9721, -5.7863], [-0.4791, -1.5366, -0.3796, 0.8453, 0.2500], [ 1.9109, -0.0828, 1.6587, 0.7128, -0.4209], [-1.9032, -2.2359, 1.0701, -0.3013, 1.3471]], device='privateuseone:0') ``` I am not very good at learning, please help me 学艺不精,请求各位的援助
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
RVC-Project/Retrieval-based-Voice-Conversion-WebUI#1825
No description provided.