Skip to main content
Version: Main branch

component

superduper.components.component

Source code

build_context​

build_context(vars_dict: dict[str,
typing.Any] | None)
ParameterDescription
vars_dictDictionary of variables to set for the build context.

Context manager to set build variables for components.

current_build_vars​

current_build_vars(default: Optional[Any] = None) -> dict[str,
typing.Any] | None
ParameterDescription
defaultDefault value to return if no variables are set.

Get the current build variables.

ensure_setup​

ensure_setup(func)
ParameterDescription
funcDecorator function.

Decorator to ensure that the model is initialized before calling the function.

propagate_failure​

propagate_failure(f)
ParameterDescription
fFunction to decorate.

Propagate failure decorator.

Component​

Component(self,
identifier: str,
upstream: Optional[List[ForwardRef('Component')]] = None,
compute_kwargs: Dict = <factory>,
db: dataclasses.InitVar[typing.Optional[ForwardRef('Datalayer')]] = None) -> None
ParameterDescription
identifierIdentifier of the instance.
upstreamA list of upstream components.
compute_kwargsKeyword arguments to manage the compute environment.
dbDatalayer instance. Datalayer instance.

Base class for all components in superduper.io.

Class to represent superduper.io serializable entities that can be saved into a database.

:param db: Datalayer instance.