diff --git a/ignite/contrib/engines/common.py b/ignite/contrib/engines/common.py index 09f769a18d0..bcfa54be55e 100644 --- a/ignite/contrib/engines/common.py +++ b/ignite/contrib/engines/common.py @@ -78,7 +78,7 @@ def setup_common_training_handlers( lr_scheduler: learning rate scheduler as native torch LRScheduler or ignite's parameter scheduler. with_gpu_stats: if True, :class:`~ignite.metrics.GpuInfo` is attached to the - trainer. This requires `pynvml` package to be installed. + trainer. This requires `pynvml<12` package to be installed. output_names: list of names associated with `update_function` output dictionary. with_pbars: if True, two progress bars on epochs and optionally on iterations are attached. Default, True. diff --git a/ignite/metrics/gpu_info.py b/ignite/metrics/gpu_info.py index 96ed4f07c57..d13bbd8a1da 100644 --- a/ignite/metrics/gpu_info.py +++ b/ignite/metrics/gpu_info.py @@ -10,7 +10,7 @@ class GpuInfo(Metric): """Provides GPU information: a) used memory percentage, b) gpu utilization percentage values as Metric - on each iterations. + on each iterations. This metric requires `pynvml `_ package of version `<12`. .. Note :: @@ -39,7 +39,7 @@ def __init__(self) -> None: except ImportError: raise ModuleNotFoundError( "This contrib module requires pynvml to be installed. " - "Please install it with command: \n pip install pynvml" + "Please install it with command: \n pip install 'pynvml<12'" ) # Let's check available devices if not torch.cuda.is_available():