diff --git a/manager/libs/process_utils.py b/manager/libs/process_utils.py index 669cf7b..df4b0fd 100644 --- a/manager/libs/process_utils.py +++ b/manager/libs/process_utils.py @@ -134,19 +134,21 @@ def check_gpu_acceleration(): if not os.path.exists("/dev/dri"): LogManager.logger.error( "/dev/dri does not exist. No direct GPU access.") - return False + return "OFF" - # Obtiene la salida de glxinfo - result = subprocess.check_output( - "glxinfo | grep direct", shell=True).decode('utf-8') - print(result) + # # Obtiene la salida de glxinfo + # result = subprocess.check_output( + # "glxinfo | grep direct", shell=True).decode('utf-8') + # print(result) - # Verifica si la aceleración directa está habilitada - return "direct rendering: Yes" in result + # # Verifica si la aceleración directa está habilitada + # return "direct rendering: Yes" in result + vendor_name = os.environ['DRI_VENDOR'] + return vendor_name.upper() except Exception as e: print(f"Error: {e}") - return False + return "OFF" def get_ros_version():