package modelkit

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Modelkit.Regression_scorer

Higher-is-better regression scorer specifications.

Loss scorers negate their corresponding metric, following scikit-learn's selection convention.

type metric =
  1. | Mean_absolute_error
  2. | Mean_squared_error
  3. | Root_mean_squared_error
  4. | R2
type params = {
  1. metric : metric;
  2. undefined : Undefined_metric_policy.t;
}
type t
val create : ?undefined:Undefined_metric_policy.t -> metric -> t
val neg_mean_absolute_error : t
val neg_mean_squared_error : t
val neg_root_mean_squared_error : t
val r2 : ?undefined:Undefined_metric_policy.t -> unit -> t

Admits a built-in specification through the first-class scorer API.

include SCORER with type t := t and type params := params and type truth = Target.regression Target.t and type prediction = Target.regression Target.t
include SPECIFICATION with type t := t with type params := params
val clone : t -> t
val params : t -> params
type prediction = Target.regression Target.t
val name : t -> string
val score : t -> ?sample_weight:Sample_weight.t -> truth:truth -> prediction:prediction -> unit -> (float, Error.t) result