electra-app-p9v2 / src /utils /tracking_utils.py
nounouille
Initial commit - Deploy Electra app
9a9b2ea
raw
history blame contribute delete
379 Bytes
# src/utils/tracking_utils.py
import torch
def log_gpu_info():
"""
Affiche les infos GPU disponibles.
"""
if torch.cuda.is_available():
print(f"GPU disponible : {torch.cuda.get_device_name(0)}")
print(f"Mémoire totale : {round(torch.cuda.get_device_properties(0).total_memory / 1024**3, 2)} Go")
else:
print("Aucun GPU détecté.")