lsst-ctrl-mpexec 29.2025.4000__py3-none-any.whl → 29.2025.4200__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -251,7 +251,7 @@ def qgraph(
251
251
  else:
252
252
  import_mode = TaskImportMode.DO_NOT_IMPORT
253
253
  with PredictedQuantumGraph.open(qgraph, import_mode=import_mode) as reader:
254
- if for_execution or qgraph_dot or qgraph_mermaid or show.needs_full_qg:
254
+ if for_execution or qgraph_dot or qgraph_mermaid or show.needs_full_qg or qgraph_node_id:
255
255
  # This reads everything for the given quanta.
256
256
  reader.read_execution_quanta(quantum_ids)
257
257
  elif for_init_output_run:
@@ -316,24 +316,24 @@ def qgraph(
316
316
  output, metadata=metadata, attach_datastore_records=qgraph_datastore_records
317
317
  )
318
318
 
319
- if not summarize_quantum_graph(qgc.header):
320
- return None
321
-
322
319
  if save_qgraph:
323
320
  _LOG.verbose("Writing quantum graph to %r.", save_qgraph)
324
321
  qgc.write(save_qgraph)
325
322
 
326
323
  qg = qgc.assemble()
327
324
 
325
+ if not summarize_quantum_graph(qg):
326
+ return None
327
+
328
328
  if qgraph_dot:
329
329
  _LOG.verbose("Writing quantum graph DOT visualization to %r.", qgraph_dot)
330
- graph2dot(qg, qgraph_dot) # TODO[DM-51850]: make this work
330
+ graph2dot(qg, qgraph_dot)
331
331
 
332
332
  if qgraph_mermaid:
333
333
  _LOG.verbose("Writing quantum graph Mermaid visualization to %r.", qgraph_mermaid)
334
- graph2mermaid(qg, qgraph_mermaid) # TODO[DM-51850]: make this work
334
+ graph2mermaid(qg, qgraph_mermaid)
335
335
 
336
336
  # optionally dump some info.
337
- show.show_graph_info(qg, butler_config) # TODO[DM-51850]: make this work
337
+ show.show_graph_info(qg, butler_config)
338
338
 
339
339
  return qg
@@ -163,7 +163,7 @@ def run_qbb(
163
163
  qg = PredictedQuantumGraph.read_execution_quanta(qgraph, quantum_ids=quantum_ids)
164
164
  job_metadata = {"qg_read_time": qg_read_time.duration, "qg_size": len(qg)}
165
165
 
166
- summarize_quantum_graph(qg.header)
166
+ summarize_quantum_graph(qg)
167
167
 
168
168
  dataset_types = {dtn.name: dtn.dataset_type for dtn in qg.pipeline_graph.dataset_types.values()}
169
169
 
@@ -38,7 +38,7 @@ from astropy.table import Table
38
38
  from lsst.daf.butler.cli.opt import config_file_option, config_option
39
39
  from lsst.daf.butler.cli.utils import MWCommand, MWCtxObj, split_commas
40
40
  from lsst.pipe.base.cli.opt import instrument_option
41
- from lsst.pipe.base.quantum_graph import HeaderModel
41
+ from lsst.pipe.base.quantum_graph import BaseQuantumGraph
42
42
  from lsst.utils.logging import getLogger
43
43
 
44
44
  from .opt import delete_option, task_option
@@ -219,32 +219,36 @@ class PipetaskCommand(MWCommand):
219
219
  extra_epilog = "See 'pipetask --help' for more options."
220
220
 
221
221
 
222
- def summarize_quantum_graph(qg_header: HeaderModel) -> int:
222
+ def summarize_quantum_graph(qg: BaseQuantumGraph) -> int:
223
223
  """Report a summary of the quanta in the graph.
224
224
 
225
+ This only reports quanta that were actually loaded.
226
+
225
227
  Parameters
226
228
  ----------
227
- qg_header : `lsst.pipe.base.quantum_graph.HeaderModel`
228
- Header of the quantum graph.
229
+ qg : `lsst.pipe.base.quantum_graph.BaseQuantumGraph`
230
+ Quantum graph object
229
231
 
230
232
  Returns
231
233
  -------
232
234
  n_quanta : `int`
233
235
  The number of quanta in the graph.
234
236
  """
235
- n_quanta = qg_header.n_quanta
237
+ n_task_quanta = {
238
+ task_label: len(quanta_for_task)
239
+ for task_label, quanta_for_task in qg.quanta_by_task.items()
240
+ if quanta_for_task
241
+ }
242
+ n_quanta = sum(n_task_quanta.values())
236
243
  if n_quanta == 0:
237
244
  _LOG.info("QuantumGraph contains no quanta.")
238
245
  else:
239
246
  if _LOG.isEnabledFor(logging.INFO):
240
- qg_quanta, qg_tasks = [], []
241
- for task_label, n_quanta_for_task in qg_header.n_task_quanta.items():
242
- qg_tasks.append(task_label)
243
- qg_quanta.append(n_quanta_for_task)
247
+ qg_tasks, qg_quanta = zip(*n_task_quanta.items())
244
248
  qg_task_table = Table(dict(Quanta=qg_quanta, Tasks=qg_tasks))
245
249
  qg_task_table_formatted = "\n".join(qg_task_table.pformat())
246
250
  quanta_str = "quantum" if n_quanta == 1 else "quanta"
247
- n_tasks = len(qg_header.n_task_quanta)
251
+ n_tasks = len(n_task_quanta)
248
252
  n_tasks_plural = "" if n_tasks == 1 else "s"
249
253
  _LOG.info(
250
254
  "QuantumGraph contains %d %s for %d task%s\n%s",
@@ -1,2 +1,2 @@
1
1
  __all__ = ["__version__"]
2
- __version__ = "29.2025.4000"
2
+ __version__ = "29.2025.4200"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: lsst-ctrl-mpexec
3
- Version: 29.2025.4000
3
+ Version: 29.2025.4200
4
4
  Summary: Pipeline execution infrastructure for the Rubin Observatory LSST Science Pipelines.
5
5
  Author-email: Rubin Observatory Data Management <dm-admin@lists.lsst.org>
6
6
  License: BSD 3-Clause License
@@ -16,11 +16,11 @@ lsst/ctrl/mpexec/simple_pipeline_executor.py,sha256=aVWgOds0ILCTzXdrWy0KFyjcIuqw
16
16
  lsst/ctrl/mpexec/singleQuantumExecutor.py,sha256=Y70xs5f06sEeDXF3cKNjxL4gdG69Osu8Xbol-vm-VIo,8616
17
17
  lsst/ctrl/mpexec/taskFactory.py,sha256=0TdCM-le7CXhobVbWPTqcq9sOrGceUY6mmkzzWhi0dM,1707
18
18
  lsst/ctrl/mpexec/util.py,sha256=y2Rw5PL40_EuLtVxiqSVX0JfPV4IrFl1LfOMUWx2u30,4236
19
- lsst/ctrl/mpexec/version.py,sha256=OZgl6BR-Rxy62NJlHO2yg_Rq4EhfmRSKDkEEnAyc-3Q,55
19
+ lsst/ctrl/mpexec/version.py,sha256=loN_SewEappJtRr1bfMkUAloXYiZtM4w0O03FF5yeZQ,55
20
20
  lsst/ctrl/mpexec/cli/__init__.py,sha256=6dpDHNBzyicVpFi1fsaiYVbYEMeoL57IHKkPaej24gs,1301
21
21
  lsst/ctrl/mpexec/cli/butler_factory.py,sha256=-Nlm5nVcWK_JbW8oc5qudu9yuZg5Pknf1LmtkxTkHJs,26713
22
22
  lsst/ctrl/mpexec/cli/pipetask.py,sha256=4HnhX9dCizCihVbpHVJX5WXO9TEli9oL6wA-tPh1_vA,2209
23
- lsst/ctrl/mpexec/cli/utils.py,sha256=Oiw4yOpsR7_kJObhZAZu8hm81NFmaLaRAv86v4smadk,9833
23
+ lsst/ctrl/mpexec/cli/utils.py,sha256=WvpVompkHFbk-EAOVNTWXDd_OfWgp0bvzKKCcX1o5r8,9890
24
24
  lsst/ctrl/mpexec/cli/cmd/__init__.py,sha256=nRmwwW5d55gAEkyE7NpSK8mxa56HcfEta2r-Y9I07F8,1661
25
25
  lsst/ctrl/mpexec/cli/cmd/commands.py,sha256=dO0WMFEwAAGoiNBgkQXu1oW-N89Eah89X2XR84PKQBg,17063
26
26
  lsst/ctrl/mpexec/cli/opt/__init__.py,sha256=IzUInuJj9igiaNcEqMx0adelgJtQC5_XMYnaiizBn0A,1378
@@ -33,18 +33,18 @@ lsst/ctrl/mpexec/cli/script/cleanup.py,sha256=D7W-azf4mNJcIWhbU5uCRCi94mkb8-Q2ks
33
33
  lsst/ctrl/mpexec/cli/script/confirmable.py,sha256=Bo1GSTZQn44d_TRj6N3YfpYcZiuHEYoz26WZQwMyb4A,3918
34
34
  lsst/ctrl/mpexec/cli/script/pre_exec_init_qbb.py,sha256=3cNw5BKMT4_YWo1GeuH4VmvKeYOoyDcjH7QgBEoiPmA,4140
35
35
  lsst/ctrl/mpexec/cli/script/purge.py,sha256=gYwSsZfTBP6oDcDp_YdqQEKGvAStvsj5hwNw42S8ptE,10637
36
- lsst/ctrl/mpexec/cli/script/qgraph.py,sha256=aaWRxqQHWWg8hRYlMZmKxQMq5arZNIYa4rHvQmENRUs,14905
36
+ lsst/ctrl/mpexec/cli/script/qgraph.py,sha256=4mWtSF375XW2-Gm5DPdvSwbjeNRYhG19FHN66q2sjGc,14813
37
37
  lsst/ctrl/mpexec/cli/script/report.py,sha256=ItJitmYmWIDjj7PxRtP4qXLx-z5FAU6nSfI2gx0GS5k,12800
38
38
  lsst/ctrl/mpexec/cli/script/run.py,sha256=d_oSGl6t9qEPeFPsZxlPQkUsGLNNl5wB1PXGn71Fw-s,14135
39
- lsst/ctrl/mpexec/cli/script/run_qbb.py,sha256=lz4PMezfyDjFzyjrOnk0i-BULj_Tn8axHHDPQ20KgVo,10862
39
+ lsst/ctrl/mpexec/cli/script/run_qbb.py,sha256=W1MvzoUBKvHNx17s1dvyGXaC7C5uGvbvDrF9meXbvok,10855
40
40
  lsst/ctrl/mpexec/cli/script/update_graph_run.py,sha256=2b0Q0j5yPC4bWxq0tsd4et2VmOnu-dQLQa94340z78Y,2623
41
- lsst_ctrl_mpexec-29.2025.4000.dist-info/licenses/COPYRIGHT,sha256=pGCjnRAnyt02a6_9PLzXQikpvYmvMmK9fCdOKlRSV6k,369
42
- lsst_ctrl_mpexec-29.2025.4000.dist-info/licenses/LICENSE,sha256=pRExkS03v0MQW-neNfIcaSL6aiAnoLxYgtZoFzQ6zkM,232
43
- lsst_ctrl_mpexec-29.2025.4000.dist-info/licenses/bsd_license.txt,sha256=7MIcv8QRX9guUtqPSBDMPz2SnZ5swI-xZMqm_VDSfxY,1606
44
- lsst_ctrl_mpexec-29.2025.4000.dist-info/licenses/gpl-v3.0.txt,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
45
- lsst_ctrl_mpexec-29.2025.4000.dist-info/METADATA,sha256=ccuSpT6JGbaAbBp6qCSkQMJYnLPaY_aMKR4drY_2eaU,2302
46
- lsst_ctrl_mpexec-29.2025.4000.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
47
- lsst_ctrl_mpexec-29.2025.4000.dist-info/entry_points.txt,sha256=aYE38yqZU8qvpLUUkXzgmUxDJYYknEqPxgxYkowrL4s,64
48
- lsst_ctrl_mpexec-29.2025.4000.dist-info/top_level.txt,sha256=eUWiOuVVm9wwTrnAgiJT6tp6HQHXxIhj2QSZ7NYZH80,5
49
- lsst_ctrl_mpexec-29.2025.4000.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
50
- lsst_ctrl_mpexec-29.2025.4000.dist-info/RECORD,,
41
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/licenses/COPYRIGHT,sha256=pGCjnRAnyt02a6_9PLzXQikpvYmvMmK9fCdOKlRSV6k,369
42
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/licenses/LICENSE,sha256=pRExkS03v0MQW-neNfIcaSL6aiAnoLxYgtZoFzQ6zkM,232
43
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/licenses/bsd_license.txt,sha256=7MIcv8QRX9guUtqPSBDMPz2SnZ5swI-xZMqm_VDSfxY,1606
44
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/licenses/gpl-v3.0.txt,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
45
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/METADATA,sha256=H6qLgq5Im388p4enDvweMHYuo_JAFM_qnNCfUVleN6U,2302
46
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
47
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/entry_points.txt,sha256=aYE38yqZU8qvpLUUkXzgmUxDJYYknEqPxgxYkowrL4s,64
48
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/top_level.txt,sha256=eUWiOuVVm9wwTrnAgiJT6tp6HQHXxIhj2QSZ7NYZH80,5
49
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
50
+ lsst_ctrl_mpexec-29.2025.4200.dist-info/RECORD,,