def __init__(self, gpu_id, every=0.5):
        """
        Creates an instance of the epoch Max GPU metric.

        :param gpu_id: GPU device ID.
        :param every: seconds after which update the maximum GPU
            usage
        """
        super(EpochMaxGPU, self).__init__(
            gpu_id, every, reset_at="epoch", emit_at="epoch", mode="train"
        )

        Creates an instance of the epoch Max GPU metric.

        :param gpu_id: GPU device ID.
        :param every: seconds after which update the maximum GPU
            usage
        
avalanche/evaluation/metrics/gpu_usage.py