torchmetrics.Metric The base Metric class is an abstract base class that are used as the building block for all other Module metrics. torchmetrics.Metric