import torch from torchmetrics.image import StructuralSimilarityIndexMeasure preds = torch.rand([3, 3, 256, 256]) target = preds * 0.75 metric = StructuralSimilarityIndexMeasure(data_range=1.0) values = [ ] for _ in range(10): values.append(metric(preds, target)) fig_, ax_ = metric.plot(values)