From 3e1fb645f204031b2cfb9fe937195f29b11e4674 Mon Sep 17 00:00:00 2001 From: unusuallman <84268283+unusuallman@users.noreply.github.com> Date: Mon, 19 Aug 2024 12:02:24 +0800 Subject: [PATCH] Update utility.py --- backend/tools/infer/utility.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/backend/tools/infer/utility.py b/backend/tools/infer/utility.py index 2c1ff892..e8367705 100644 --- a/backend/tools/infer/utility.py +++ b/backend/tools/infer/utility.py @@ -340,7 +340,8 @@ def get_infer_gpuid(): if sysstr == "Windows": return 0 - if not paddle.fluid.core.is_compiled_with_rocm(): + # if not paddle.fluid.core.is_compiled_with_rocm(): + if not paddle.is_compiled_with_rocm(): cmd = "env | grep CUDA_VISIBLE_DEVICES" else: cmd = "env | grep HIP_VISIBLE_DEVICES"