kwcoco.util.delayed_ops.delayed_base module¶
Abstract nodes
- class kwcoco.util.delayed_ops.delayed_base.DelayedOperation[source]¶
Bases:
NiceRepr
- property shape¶
Returns: None | Tuple[int | None, …]
- prepare()[source]¶
If metadata is missing, perform minimal IO operations in order to prepopulate metadata that could help us better optimize the operation tree.
- Returns
DelayedOperation2
- finalize(prepare=True, optimize=True, **kwargs)[source]¶
Evaluate the operation tree in full.
- Parameters
prepare (bool) – ensure prepare is called to ensure metadata exists if possible before optimizing. Defaults to True.
optimize (bool) – ensure the graph is optimized before loading. Default to True.
**kwargs – for backwards compatibility, these will allow for in-place modification of select nested parameters. In general these should not be used, and may be deprecated.
- Returns
ArrayLike
Notes
Do not overload this method. Overload
DelayedOperation2._finalize()
instead.
- class kwcoco.util.delayed_ops.delayed_base.DelayedNaryOperation(parts)[source]¶
Bases:
DelayedOperation
For operations that have multiple input arrays
- class kwcoco.util.delayed_ops.delayed_base.DelayedUnaryOperation(subdata)[source]¶
Bases:
DelayedOperation
For operations that have a single input array
- kwcoco.util.delayed_ops.delayed_base.DelayedOperation2¶
alias of
DelayedOperation
- kwcoco.util.delayed_ops.delayed_base.DelayedUnaryOperation2¶
alias of
DelayedUnaryOperation
- kwcoco.util.delayed_ops.delayed_base.DelayedNaryOperation2¶
alias of
DelayedNaryOperation