avalanche.evaluation.metrics.TaskAwareR2

class avalanche.evaluation.metrics.TaskAwareR2[source]

The task-aware R2 metric.

The metric computes a dictionary of <task_label, R2 value> pairs. update/result/reset methods are all task-aware.

__init__()[source]

Creates an instance of the task-aware R2 metric.

Methods

__init__()

Creates an instance of the task-aware R2 metric.

reset([task_label])

Resets the metric.

result([task_label])

Retrieves the running R2.

update(predicted_y, true_y, task_labels)

Update the running R2 given the true and predicted labels.