Skip to content

root_mean_squared_error

Module: strata.metrics • Kind: function
Source: strata/metrics/regression.mojo

def root_mean_squared_error[
true_dtype: DType = DType.float64,
pred_dtype: DType = DType.float64,
](
y_true: List[Scalar[true_dtype]],
y_pred: List[Scalar[pred_dtype]],
) -> Float64
from strata.metrics import root_mean_squared_error

Compute Root Mean Squared Error (RMSE) regression loss.

RMSE(y,y^)=1N∑i=1N(yi−y^i)2\text{RMSE}(y, \hat{y}) = \sqrt{\frac{1}{N} \sum_{i=1}^{N} (y_i - \hat{y}_i)^2}

Returns: Float64 — Float64: Non-negative square root of mean squared error.