fields.mixins.components.FieldComponentCoreMixin.empty_like#

classmethod FieldComponentCoreMixin.empty_like(other: Type[_SupFCCore], *args, **kwargs) _SupFCCore[source]#

Create an empty component with the same grid, axes, and element shape as another.

Parameters:
  • other (FieldComponent) – The reference component whose layout is used.

  • *args – Forwarded to the ones() constructor.

  • **kwargs – Forwarded to the ones() constructor.

Returns:

A new component with the same layout as other and uninitialized data.

Return type:

FieldComponent