dagstd.constants package

Submodules

dagstd.constants.constant module

constant.py contains a Constant function that acts as an op that returns whatever value is passed to it.

dagstd.constants.constant.Constant(value: Any, suffix: Optional[str] = None, make_unique: bool = True) Any[source]

Acts as an op that returns whatever value is passed to it on creation.

Parameters
  • value (Any) – The value to return.

  • suffix (str, default=None) – A suffix to append to the op name.

  • make_unique (bool, default=True) – If True, the op name will be suffixed with a UUID. Is overridden if the suffix argument is provided.

  • The name of the op is the value passed to it plus a unique ID to allow

  • having multiple constants with the same value. Alternatively, you can

  • pass a suffix to the Constant function to be used instead of the unique ID.

dagstd.constants.numbers module

numbers.py contains ops that return common numbers. These ops are capitalised to make them seem more like classes, which helps with readability.

(op)dagstd.constants.numbers.Eight() int[source]
(op)dagstd.constants.numbers.Fifty() int[source]
(op)dagstd.constants.numbers.Five() int[source]
(op)dagstd.constants.numbers.FiveHundred() int[source]
(op)dagstd.constants.numbers.Forty() int[source]
(op)dagstd.constants.numbers.Four() int[source]
(op)dagstd.constants.numbers.Nine() int[source]
(op)dagstd.constants.numbers.One() int[source]
(op)dagstd.constants.numbers.OneHundred() int[source]
(op)dagstd.constants.numbers.OneThousand() int[source]
(op)dagstd.constants.numbers.Seven() int[source]
(op)dagstd.constants.numbers.Six() int[source]
(op)dagstd.constants.numbers.Ten() int[source]
(op)dagstd.constants.numbers.Thirty() int[source]
(op)dagstd.constants.numbers.Three() int[source]
(op)dagstd.constants.numbers.Twenty() int[source]
(op)dagstd.constants.numbers.Two() int[source]
(op)dagstd.constants.numbers.Zero() int[source]

Module contents