QuantumGraphExecutionReport

class lsst.pipe.base.execution_reports.QuantumGraphExecutionReport(tasks: dict[str, lsst.pipe.base.execution_reports.TaskExecutionReport] = <factory>)

Bases: object

A report on the execution of a quantum graph.

Report the detailed status of each failure; whether tasks were not run, data is missing from upstream failures, or specific errors occurred during task execution (and report the errors). Contains a count of expected, produced DatasetTypes for each task. This report can be output as a dictionary or a yaml file.

Attributes:
tasksdict

A dictionary of TaskExecutionReports by task label.

See also

TaskExecutionReport

A task report.

DatasetTypeExecutionReport

A dataset type report.

Methods Summary

make_reports(butler, graph)

Make a QuantumGraphExecutionReport.

to_summary_dict(butler[, do_store_logs, ...])

Summarize the results of the QuantumGraphExecutionReport in a dictionary.

write_summary_yaml(butler, filename[, ...])

Take the dictionary from QuantumGraphExecutionReport.to_summary_dict and store its contents in a yaml file.

Methods Documentation

classmethod make_reports(butler: Butler, graph: QuantumGraph | str | ParseResult | ResourcePath | Path) QuantumGraphExecutionReport

Make a QuantumGraphExecutionReport.

Step through the quantum graph associated with a run, creating a networkx.DiGraph called status_graph to annotate the status of each quantum node. For each task in the quantum graph, use TaskExecutionReport.inspect_quantum to make a TaskExecutionReport based on the status of each node. Return a TaskExecutionReport for each task in the quantum graph.

Parameters:
butlerlsst.daf.butler.Butler

The Butler used for this report. This should match the Butler used for the run associated with the executed quantum graph.

graphQuantumGraph | ResourcePathExpression

Either the associated quantum graph object or the uri of the location of said quantum graph.

Returns:
report: QuantumGraphExecutionReport

The TaskExecutionReport for each task in the quantum graph.

to_summary_dict(butler: Butler, do_store_logs: bool = True, human_readable: bool = False) dict[str, Any]

Summarize the results of the QuantumGraphExecutionReport in a dictionary.

Parameters:
butlerlsst.daf.butler.Butler

The Butler used for this report.

do_store_logsbool

Store the logs in the summary dictionary.

human_readablebool

Store more human-readable information to be printed out to the command-line.

Returns:
summary_dictdict

A dictionary containing a summary of a TaskExecutionReport for each task in the quantum graph.

write_summary_yaml(butler: Butler, filename: str, do_store_logs: bool = True) None

Take the dictionary from QuantumGraphExecutionReport.to_summary_dict and store its contents in a yaml file.

Parameters:
butlerlsst.daf.butler.Butler

The Butler used for this report.

filenamestr

The name to be used for the summary yaml file.

do_store_logsbool

Store the logs in the summary dictionary.