From 2838dad477da0146b190a2bc3d05e6b3b812f343 Mon Sep 17 00:00:00 2001 From: Maisam Arif Date: Tue, 23 Apr 2024 04:49:47 -0500 Subject: [PATCH] Removed print in python interface Signed-off-by: Maisam Arif Change-Id: I80e8cf18dc7631c66d4863251438327b8853cead [ROCm/amdsmi commit: 0d6626db0d7a20857a5eece3d26ac1a8e413b11f] --- projects/amdsmi/py-interface/README.md | 6 +++--- projects/amdsmi/py-interface/amdsmi_interface.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/projects/amdsmi/py-interface/README.md b/projects/amdsmi/py-interface/README.md index 41468bd9a3..e165eb2860 100644 --- a/projects/amdsmi/py-interface/README.md +++ b/projects/amdsmi/py-interface/README.md @@ -88,7 +88,7 @@ Initialize GPUs only example: ```python try: # by default we initalize with AmdSmiInitFlags.INIT_AMD_GPUS - init_flag = amdsmi_init() + ret = amdsmi_init() # continue with amdsmi except AmdSmiException as e: print("Init GPUs failed") @@ -99,7 +99,7 @@ Initialize CPUs only example: ```python try: - init_flag = amdsmi_init(AmdSmiInitFlags.INIT_AMD_CPUS) + ret = amdsmi_init(AmdSmiInitFlags.INIT_AMD_CPUS) # continue with amdsmi except AmdSmiException as e: print("Init CPUs failed") @@ -110,7 +110,7 @@ Initialize both GPUs and CPUs example: ```python try: - init_flag = amdsmi_init(AmdSmiInitFlags.INIT_AMD_APUS) + ret = amdsmi_init(AmdSmiInitFlags.INIT_AMD_APUS) # continue with amdsmi except AmdSmiException as e: print("Init both GPUs & CPUs failed") diff --git a/projects/amdsmi/py-interface/amdsmi_interface.py b/projects/amdsmi/py-interface/amdsmi_interface.py index 31bf22adae..61222340bb 100644 --- a/projects/amdsmi/py-interface/amdsmi_interface.py +++ b/projects/amdsmi/py-interface/amdsmi_interface.py @@ -1964,7 +1964,7 @@ def amdsmi_get_gpu_process_list( "vram_mem": process_list[index].memory_usage.vram_mem, }, }) - print(result) + return result