quantax.utils.to_distributed_array#
- quantax.utils.to_distributed_array(array: Array | ndarray | bool | number | bool | int | float | complex) Array#
Place the array on all devices, sharded along its first dimension. See
get_distributed_shardingfor the sharding.Note
This expects a global array. In multi-host jobs use
local_to_globalto assemble host-local arrays into a global one instead.