Summary#

class skore.Summary(dataframe, project=None)[source]#

Metadata and metrics for all reports persisted in a project at a given moment.

A summary object stores the metadata and metrics of the reports that have been persisted in a project as a pandas.DataFrame, accessible through the frame() method. It implements a custom HTML representation that displays the information as a table. The table provides a per-row selection and builds a query string that can be copied and passed to query() to recover a subset of reports.

Use query() to filter the reports and compare() to load the corresponding report objects from the project.

See also

compare()

Compare selected reports side by side.

Project.summarize()

Create a summary from a project.

compare(*, return_as='list')[source]#

Return the reports referenced by the summary object from the project.

Parameters:
return_as{“list”, “report”}, default=”list”

In what form the reports should be returned.

Returns:
reportslist of reports or ComparisonReport

If return_as="list", a list of EstimatorReport or CrossValidationReport objects. If return_as="report", a ComparisonReport.

See also

compare()

Compare reports side by side.

frame(*, report_type=None)[source]#

Return the metadata and metrics as a pandas.DataFrame.

Parameters:
report_type{“estimator”, “cross-validation”}, default=None

Filter the rows to a specific type of report. When None, all reports are returned.

Returns:
framepandas.DataFrame

The metadata and metrics of the reports.

plot()[source]#

Plot a visual summary of the reports referenced by this object.

Raises:
NotImplementedError

This method is not implemented yet.

query(expr)[source]#

Filter the summary using a pandas.DataFrame.query() expression.

Parameters:
exprstr

The query string to evaluate. The report id is available as an index level, so selections built from the HTML representation (e.g. "id in ['ab12cd34']") can be used to recover specific reports.

Returns:
summarySummary

A new summary restricted to the rows matching expr.