torch_fair

lightautoml.tasks.losses.torch.torch_fair(y_true, y_pred, sample_weight=None, c=0.9)[source]

Computes Mean Fair Error.

Parameters:
  • y_true (Tensor) – true target values.

  • y_pred (Tensor) – predicted target values.

  • sample_weight (Optional[Tensor]) – specify weighted mean.

  • c (float) – metric coefficient.

Returns:

metric value.