Skip to content

Result Time-Series & Version Comparison

Bundle evaluation results across epochs into a single series and inspect the trends of metrics, issue breakdowns, and heatmaps. Cross-version comparison (overlay and delta) is also supported.

  • Evaluator.get_result_series(...) returns a ResultSeries.
  • series_a - series_b gives a cross-version delta (ResultSeriesDelta); plot_metrics(overlay=[...]) overlays series.

Prerequisites

An online API connection is required (local mode is not supported).

Fetch a series

evaluator = Evaluator(model_name="my_model", version_name="v1")

series = evaluator.get_result_series(
    select_by="latest",     # pick the latest completed result per epoch
    # method_name="...",    # for select_by="method_name" ("default" is NOT expanded; pass a concrete name)
    # result_name="...",    # for select_by="result_name" (case-sensitive substring)
    # version_name="v2",    # to target another version of the same model
)
select_by Selection basis
"latest" (default) The latest completed result per epoch
"method_name" Exact match on method_name (the "default" alias is not expanded)
"result_name" Substring match on result_name (case-sensitive)

metrics() returns a tidy DataFrame.

series.metrics()
#   -> columns: [n_epoch, metric, dataset_type, value, result_id, result_name]

series.plot_metrics(metric="accuracy", dataset_type="val")                   # timeline
series.plot_metrics(metric="accuracy", dataset_type="val", mode="delta")     # adjacent-epoch delta
plot_metrics arg Default Description
metric None (all) Metric to plot
dataset_type None (all) dataset_type to plot
mode "timeline" "timeline" (raw) / "delta" (vs previous epoch, or vs baseline=)
overlay None Other ResultSeries drawn on the same axes (version comparison)

Missing values

Metrics for unmeasured epochs are kept as NaN, so lines break at those points in the plot.

series.issues()             # per-epoch issues concatenated with an n_epoch column
series.plot_issues(by="category", metric="counts_ratio", kind="area")
series.issues_delta(by="error_code")   # epoch-over-epoch change as numbers
#   -> columns: [n_epoch, error_code, value, delta]
  • by for plot_issues / issues_delta is "category" / "error_code".
  • metric is "counts_ratio" (default) / "counts" / "accuracy" / "average_iou", etc.
  • kind is "line" / "area" (stacked).

Missing rule for count metrics

For count-like metrics (counts / counts_ratio), a category absent at an epoch is treated as 0, so a newly appearing issue reads as a positive delta and a disappearing one as a negative delta. For quality metrics (e.g. accuracy) missing values are left as-is (no zero-fill).

heatmaps(...) fetches one heatmap per epoch and returns a HeatmapSeries (filmstrip). The arguments match Result.get_heatmap.

hs = series.heatmaps(x_axis="pred_score", y_axis="error_proba",
                     dataset_type="pool", epochs=[1, 5, 10])
hs.show()                                  # display each epoch side by side
hs.show_deltas(field="delta_error_ratio")  # consecutive-epoch deltas (when axis ranges align)

Note

Deltas (show_deltas / deltas) are valid only when adjacent epochs share axis ranges; otherwise a ValueError is raised. The absolute-value filmstrip show() always works.

Extract a single epoch's Result

From a series you can pull out a regular single Result and use it with get_heatmap / recommend_al_strategy, etc.

r = series.get_result(n_epoch=10)          # resolvable by result_name= too
r.get_summary()

Compare versions

Fetch the series of another version of the same model and overlay or diff them.

s_v1 = evaluator.get_result_series()
s_v2 = evaluator.get_result_series(version_name="v2")   # another version of the same model

# overlay
s_v1.plot_metrics(metric="accuracy", overlay=[s_v2])

# delta (ResultSeriesDelta)
delta = s_v1 - s_v2
delta.metrics()                                   # [n_epoch, metric, dataset_type, delta, a_value, b_value]
delta.plot(metric="accuracy", dataset_type="val") # version delta (with a 0 reference line)

# issue delta (which categories / error codes grew or shrank)
delta.issues(by="error_code")
#   -> [n_epoch, error_code, delta, a_value, b_value, status]
#      status: "both" (in both versions) / "a_only" (new in v1) / "b_only" (gone in v1)
delta.plot_issues(by="category")

evaluator.list_versions()   # list versions of this model (DataFrame)

Cross-version issue-delta rule

Comparison is on common epochs (intersection), and categories / error codes are aligned via outer join (union of both sides). Count metrics are zero-filled so appearance/disappearance is readable from both the delta and the status column.

From the CLI

The same capabilities are available from the terminal.

mldebugger results show    <model> <version>     # metric trends + issue breakdown
mldebugger results compare <model> <vA> <vB>     # metric delta between versions

See Terminal App (mldebugger) for details.