NumpyTensorSpace.broadcast_to

NumpyTensorSpace.broadcast_to(inp: int | float | complex | list | tuple | ndarray) ndarray[source]

Broadcasts the an inputs to the shape of the TensorSpace. Also performs a device conversion if necessary

Args:

inp (int | float | complex | list | tuple | xp.ndarray): Input to be broadcasted

Returns:

xp.ndarray: Returned array broadcasted to the TensorSpace shape and device