You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ISE is a metric for models where the predict method has a return_std argument. It essentially calculates how many of the true values fall within 2 std of the predictions, so something like this:
def ise(estimator, X, y_true):
"""
Scorer: the Independent Standard Error (ISE).
Parameters:
y_true (array-like): True output values
y_pred (array-like): Predictions from the model (should be a tuple of mean and std)
Returns:
float: ISE value as a percentage
"""
if not has_predict_with_std(estimator):
return np.nan
y_pred_mean, y_pred_std = estimator.predict(X, return_std=True)
within_2std = np.abs(y_pred_mean - y_true) < 2 * y_pred_std
ise_value = np.mean(within_2std) * 100
return ise_value
The problem is that this can't just be wrapped using make_scorer in cross_validate.py, because it requires predict to be called with return_std=True (default is False). And then it needs to work with multioutput too.
The text was updated successfully, but these errors were encountered:
The ISE is a metric for models where the
predict
method has areturn_std
argument. It essentially calculates how many of the true values fall within 2 std of the predictions, so something like this:The problem is that this can't just be wrapped using
make_scorer
incross_validate.py
, because it requirespredict
to be called withreturn_std=True
(default isFalse
). And then it needs to work with multioutput too.The text was updated successfully, but these errors were encountered: