CoreModel.register_block_spec(
spec=None,
*,
name: str | None = None,
row_axes=None,
col_axes=None,
replace: bool = False,
)#

Register a semantic block specification on the current database.

Parameters:
  • spec – Pre-built block specification. When omitted, name, row_axes and col_axes are used to build one.

  • name – Name of the custom block to register when spec is not passed.

  • row_axes – Axis descriptors used to build a block specification on the fly.

  • col_axes – Axis descriptors used to build a block specification on the fly.

  • replace – When True, replace an already registered custom specification with the same name.

Returns:

The registered block specification.

Return type:

object