code: def _partition_tensor(self, tensor):
      partition = partition_uniform(
          num_items=tensor.numel(), num_parts=self.num_parts
      )
      start = partition[self.rank]
      length = partition[self.rank + 1] - start
      tensor_part = (
          tensor.detach()
          .contiguous()
          .view(-1)
          .narrow(0, start=start, length=length)
          .clone()
      )
  
      return tensor_part, partition
  
imports: from collections.abc import Iterable
  from deepspeed.moe.utils import is_moe_param
  import os
  import psutil
  import gc
  from math import sqrt
  from math import floor
  from bisect import bisect_left
  import torch
  from torch import inf
  from deepspeed import comm
  from deepspeed.utils import groups, logger
  from deepspeed.runtime.constants import PIPE_REPLICATED
  from numpy import prod
label_desc: Use image node_id 3 for calling the PartitionedTensor obj's underlying member method code with example usage: obj._partition_tensor(tensor) and returns: tensor_part,  partition