fields.mixins.components.FieldComponentCoreMixin.broadcast_buffer_to_axes#

FieldComponentCoreMixin.broadcast_buffer_to_axes(axes: AxesInput, *args, buffer_class: Type[BufferBase] | None = None, buffer_registry: BufferRegistry | None = None, **kwargs) BufferBase[source]#

Return a new buffer instance with data broadcasted to a specified set of axes.

This returns a wrapped buffer aligned with the new axes, suitable for downstream use in field construction or data manipulation.

Parameters:
  • axes (list of str) – Target axes to broadcast over.

  • buffer_class (BufferBase, optional) – Optional override of the buffer class to use.

  • buffer_registry (BufferRegistry, optional) – If using a string identifier for buffer_class, this registry is used to resolve it.

  • *args – Additional arguments forwarded to the buffer constructor.

  • **kwargs – Additional arguments forwarded to the buffer constructor.

Returns:

A new buffer object whose shape and layout is compatible with axes.

Return type:

BufferBase