Iterates through all metrics and computes their values, handling errors
gracefully based on each metric's required property.
Usage
compute_all_metrics(
fit_result,
data_bundle,
context,
metrics,
task_ctx,
result_path = NULL
)Value
A named list with:
metrics: Named list of computed and flattened metric valueswarnings: Character vector of any warning messages
Details
For each metric:
If the metric has
required = TRUEand fails, the error is re-thrownIf the metric has
required = FALSEand fails, NA values are returned with error information stored in<metric_name>__error_classand<metric_name>__error_messageAll metric outputs are flattened using
flatten_metric_output()