iaml.metrics.mean_absolute_error_metric

[METRIC] Mean Absolute Error

Classes

MeanAbsoluteErrorMetric

[METRIC] Mean Absolute Error

Module Contents

class iaml.metrics.mean_absolute_error_metric.MeanAbsoluteErrorMetric

Bases: iaml.metric.Metric

[METRIC] Mean Absolute Error

name: str = 'Mean Absolute Error'

Return the metric formatted name

Returns:

Formatted name.

greater_is_better = False

Whether larger values are better. Set to False for error metrics.

refs: list[dict[str, Any]]

List of references for this metric.

__str__() → str

Metric name

Returns:

Metric name.

suitable(X: pandas.DataFrame, y: pandas.DataFrame, type_of_target: str) → bool

Is this metric usable given X and y ?

Parameters:
  • X (pd.DataFrame) – The dataset we try to compute metrics on.

  • y (pd.DataFrame) – The dataset target we try to compute metrics on

  • type_of_target (str) – The type of target we are trying to predict

Returns:

Suitable ?

compute(y: pandas.DataFrame, y_pred: pandas.DataFrame, **kwargs) → float

Compute metric given y, y_pred. Must be overridden by children classes

Parameters:
  • y (pd.DataFrame) – Ground truth to compute the metric.

  • y_pred (pd.DataFrame) – Prediction to compute the metric.

  • **kwargs (dict, optional) – Additional parameters

Returns:

Computed value