lenskit.metrics.GlobalMetric#

class lenskit.metrics.GlobalMetric#

Bases: Metric

Base class for metrics that measure entire runs at a time.

For prediction metrics, this is micro-averaging.

__init__()#

Methods

__init__()

measure_run(output, test, /)

Compute a metric value for an entire run.

Attributes

label

The metric's default label in output.

abstract measure_run(output, test, /)#

Compute a metric value for an entire run.

Individual metric classes need to implement this method.

Parameters:
Return type:

float