ctf4science.eval_module.extract_metrics_in_order#

ctf4science.eval_module.extract_metrics_in_order(dataset_name: str, batch_results: dict[str, Any]) list[float]#

Extract metric values from batch results in the order defined by the dataset config.

Pairs are processed in ascending pair_id; within each pair, metrics follow the order in the dataset configuration.

Parameters:
dataset_namestr

Name of the dataset (e.g. 'PDE_KS').

batch_resultsdict

Dictionary loaded from batch results (e.g. batch_results.yaml), with a pairs list keyed by pair_id and metrics.

Returns:
list of float

Metric values in the order specified by the dataset config.

Raises:
ValueError

If a pair or metric is missing in batch_results.