Typo in if torch.cuda.is_available

This commit is contained in:
David PAGNON 2024-08-08 08:33:01 +02:00 committed by GitHub
parent 8af6ec8075
commit f71aba8a08
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -360,7 +360,7 @@ def rtm_estimator(config_dict):
try: try:
import torch import torch
import onnxruntime as ort import onnxruntime as ort
if torch.cuda.is_available() == False and 'CUDAExecutionProvider' in ort.get_available_providers(): if torch.cuda.is_available() and 'CUDAExecutionProvider' in ort.get_available_providers():
device = 'cuda' device = 'cuda'
backend = 'onnxruntime' backend = 'onnxruntime'
logging.info(f"\nValid CUDA installation found: using ONNXRuntime backend with GPU.") logging.info(f"\nValid CUDA installation found: using ONNXRuntime backend with GPU.")