rlmesh.adapters.Concat
A multi-part numeric state input: several roles packed into one tensor.
Concat(
*parts: ConcatPart,
pad_to: int | None = None,
dtype: str = 'float32',
reshape: tuple[int, ...] | None = None,
container: Literal['array', 'list'] = 'array',
clip: tuple[float, float] | None = None,
)The multi-part state leaf. Parts are concatenated in order; each part is a
bare role string (sugar for a role-only State), a State
carrying part fields, or a Constant block. A single-role state is
State directly; this is the >1-part case. Both serialize to the same
{"type": "state", ...} wire form.
There is no key – placement in the input tree is the payload position.
Attributes
- partsRoles (or
State/Constantparts) concatenated in order. - pad_toZero-pad the concatenated vector to this length.
- dtypeNumPy dtype name of the resulting value.
- reshapeOptional target shape for the resulting value.
- containerEmit a NumPy array or a plain Python list.
- clipClamp the concatenated vector to
(low, high)after every part's own transforms and beforepad_to.
parts
attribute[source]parts: tuple[ConcatPart, ...]pad_to
attribute[source]pad_to: int | NoneZero-pad the concatenated vector to this length. Padding is the last step: every part is converted, ranged and scaled, the parts are concatenated in order, and only then is the result padded.
dtype
attribute[source]dtype: strNumPy dtype name of the resulting value.
reshape
attribute[source]reshape: tuple[int, ...] | NoneOptional target shape for the resulting value.
container
attribute[source]container: Literal['array', 'list']Emit a NumPy array or a plain Python list.
clip
attribute[source]clip: tuple[float, float] | NoneClamp the concatenated vector to (low, high) after every part’s own transforms and before pad_to.