ImportIR#

class lsst.pipe.base.pipelineIR.ImportIR(location: str, include: list[str] | None = None, exclude: list[str] | None = None, rename: dict[str, str] = <factory>, importContracts: bool = True, importSteps: bool = True, labeledSubsetModifyMode: ~lsst.pipe.base.pipelineIR.PipelineSubsetCtrl = PipelineSubsetCtrl.DROP, instrument: ~typing.Literal[_Tags.KeepInstrument] | str | None = _Tags.KeepInstrument)#

Bases: object

An intermediate representation of imported pipelines.

Attributes Summary

exclude

list of tasks that should be excluded when inheriting this pipeline.

importContracts

Boolean attribute to dictate if contracts should be inherited with the pipeline or not.

importSteps

Boolean attribute to dictate if steps should be inherited with the pipeline or not.

include

list of tasks that should be included when inheriting this pipeline.

instrument

Instrument to assign to the Pipeline at import.

labeledSubsetModifyMode

Controls how labeled subsets are handled when an import ends up not including (either through an include or exclusion list) a task label that is defined in the Pipeline being imported.

location

This is the location of the pipeline to inherit.

rename

dict of tasks to rename, keyed by old name with new name value.

Methods Summary

toPipelineIR()

Load in the Pipeline specified by this object, and turn it into a PipelineIR instance.

Attributes Documentation

exclude: list[str] | None = None#

list of tasks that should be excluded when inheriting this pipeline. Either the include or exclude attributes may be specified, but not both.

importContracts: bool = True#

Boolean attribute to dictate if contracts should be inherited with the pipeline or not.

importSteps: bool = True#

Boolean attribute to dictate if steps should be inherited with the pipeline or not.

include: list[str] | None = None#

list of tasks that should be included when inheriting this pipeline. Either the include or exclude attributes may be specified, but not both.

instrument: Literal[_Tags.KeepInstrument] | str | None = 1#

Instrument to assign to the Pipeline at import. The default value of _Tags.KeepInstrument` indicates that whatever instrument the pipeline is declared with will not be modified. setting this value to None will drop any declared instrument prior to import.

labeledSubsetModifyMode: PipelineSubsetCtrl = 1#

Controls how labeled subsets are handled when an import ends up not including (either through an include or exclusion list) a task label that is defined in the Pipeline being imported. DROP will remove any subsets which contain a missing label. EDIT will change any subsets to not include the missing label.

location: str = <dataclasses._MISSING_TYPE object>#

This is the location of the pipeline to inherit. The path should be specified as an absolute path. Environment variables may be used in the path and should be specified as a python string template, with the name of the environment variable inside braces.

rename: dict[str, str] = <dataclasses._MISSING_TYPE object>#

dict of tasks to rename, keyed by old name with new name value.

Methods Documentation

toPipelineIR() PipelineIR#

Load in the Pipeline specified by this object, and turn it into a PipelineIR instance.

Returns#

pipelinePipelineIR

A pipeline generated from the imported pipeline file.