torch.chunk
torch.chunk(input, chunks, dim=0) -> List of Tensors
Attempts to split a tensor into the specified number of chunks.
   Each chunk is a view of the input tensor.
Note:
 This function may return fewer than the specified number of
 chunks!

See also:
 "torch.tensor_split()" a function that always returns exactly the
 specified number of chunks

If the tensor size along the given dimension "dim" is divisible by
   "chunks", all returned chunks will be the same size. If the tensor
   size along the given dimension "dim" is not divisible by "chunks",
   all returned chunks will be the same size, except the last one. If
   such division is not possible, this function may return fewer than
   the specified number of chunks.
Parameters:
      * input (Tensor) -- the tensor to split
  * **chunks** (*int*) -- number of chunks to return

  * **dim** (*int*) -- dimension along which to split the tensor

-[ Example ]-