Composed Schema
Composed Schema¤
neojax.data.schemas.composed_schema.ComposedSchema
¤
Schema that applies a sequence of schemas in order.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
schemas
|
Sequence[BaseSchema]
|
A tuple of schemas to compose. They will be applied sequentially in the order provided. |
required |
Raises:
| Type | Description |
|---|---|
ValueError
|
If |
Warns:
| Type | Description |
|---|---|
UserWarning
|
If |
Internal Attributes
- schemas (
tuple[BaseSchema]): Schemas to apply in sequentially in order.
Known Design Flaw
Not all schemas may be used in arbitrary order inside a ComposedSchema.
Have a look at the respective documentations for details on where to use each
schema.
transform(bundle: typing.Union[ForwardRef(DataBundle), Inexact[Array, ...], Inexact[ndarray, ...]], /, reference_bundle: neojax.data.bundles.data_bundle.DataBundle | None = None) -> typing.Union[ForwardRef(DataBundle), Inexact[Array, ...], Inexact[ndarray, ...]]
¤
Applies each schema's transform sequentially.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
bundle
|
Union[ForwardRef(DataBundle), Inexact[Array, ...], Inexact[ndarray, ...]]
|
The input DataBundle or PyTree. |
required |
reference_bundle
|
DataBundle | None
|
The original DataBundle to inherit geometries from. |
None
|
Returns:
| Type | Description |
|---|---|
Union[ForwardRef(DataBundle), Inexact[Array, ...], Inexact[ndarray, ...]]
|
The transformed bundle or PyTree. |