mindspore.ops.BatchToSpaceND

class mindspore.ops.BatchToSpaceND(block_shape, crops)[source]

ops.BatchToSpaceND is deprecated from version 2.0 and will be removed in a future version, use ops.batch_to_space_nd instead.

Supported Platforms:

Ascend GPU CPU

Examples

>>> block_size = 2
>>> crops = [[0, 0], [0, 0]]
>>> batch_to_space = ops.BatchToSpaceND(block_size, crops)
>>> input_x = Tensor(np.array([[[[1]]], [[[2]]], [[[3]]], [[[4]]]]), mindspore.float32)
>>> output = batch_to_space(input_x)
>>> print(output)
[[[[1.  2.]
   [3.  4.]]]]