HTCDag#

class lsst.ctrl.bps.htcondor.HTCDag(data=None, name='')#

Bases: DiGraph

HTCondor DAG.

Parameters#

datanetworkx.DiGraph.data

Initial graph.

namestr

Name for DAG.

Methods Summary

add_attribs([attribs])

Add attributes to the DAG.

add_final_job(job)

Add an HTCJob for the FINAL job in HTCDag.

add_job(job[, parent_names, child_names])

Add an HTCJob to the HTCDag.

add_job_relationships(parents, children)

Add DAG edge between parents and children jobs.

add_service_job(job)

Add an HTCJob for the SERVICE job in HTCDag.

del_job(job_name)

Delete the job from the DAG.

dump(fh)

Dump DAG info to output stream.

write(submit_path[, job_subdir, dag_subdir, ...])

Write DAG to a file.

write_dot(filename)

Write a dot version of the DAG.

Methods Documentation

add_attribs(attribs=None)#

Add attributes to the DAG.

Parameters#

attribsdict

DAG attributes.

add_final_job(job)#

Add an HTCJob for the FINAL job in HTCDag.

Parameters#

jobHTCJob

HTCJob to add to the HTCDag as a FINAL job.

add_job(job, parent_names=None, child_names=None)#

Add an HTCJob to the HTCDag.

Parameters#

jobHTCJob

HTCJob to add to the HTCDag.

parent_namesIterable [str], optional

Names of parent jobs.

child_namesIterable [str], optional

Names of child jobs.

add_job_relationships(parents, children)#

Add DAG edge between parents and children jobs.

Parameters#

parentslist [str]

Contains parent job name(s).

childrenlist [str]

Contains children job name(s).

add_service_job(job)#

Add an HTCJob for the SERVICE job in HTCDag.

Parameters#

jobHTCJob

HTCJob to add to the HTCDag as a FINAL job.

del_job(job_name)#

Delete the job from the DAG.

Parameters#

job_namestr

Name of job in DAG to delete.

dump(fh)#

Dump DAG info to output stream.

Parameters#

fhio.IO or str

Where to dump DAG info as text.

write(submit_path, job_subdir='', dag_subdir='', dag_rel_path='')#

Write DAG to a file.

Parameters#

submit_pathstr

Prefix path for all outputs.

job_subdirstr, optional

Template for job subdir (submit_path + job_subdir).

dag_subdirstr, optional

DAG subdir (submit_path + dag_subdir).

dag_rel_pathstr, optional

Prefix to job_subdir for jobs inside subdag.

write_dot(filename)#

Write a dot version of the DAG.

Parameters#

filenamestr

Name of the dot file.