class_docstr: Extension of DistributedSampler, as discussed in
  https://github.com/pytorch/pytorch/issues/23430
  
  Example:
      dataset: [0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13]
      num_replicas: 4
      shuffle: False
  
  when group_size = 1
          RANK    |  shard_dataset
          =========================
          rank_0  |  [0, 4, 8, 12]
          rank_1  |  [1, 5, 9, 13]
          rank_2  |  [2, 6, 10, 0]
          rank_3  |  [3, 7, 11, 1]
  
  when group_size = 2
  
          RANK    |  shard_dataset
          =========================
          rank_0  |  [0, 1, 8, 9]
          rank_1  |  [2, 3, 10, 11]
          rank_2  |  [4, 5, 12, 13]
          rank_3  |  [6, 7, 0, 1]
code: def __len__(self) -> int:
      return self.num_samples
  
imports: import math
  from typing import cast, Iterator, List, Optional, Sized, Union
  import torch
  import torch.distributed
  from torch.utils.data import Sampler
  from torchvision.datasets.video_utils import VideoClips
label_desc: Use image node_id 3 for calling the DistributedSampler obj's underlying member method code with example usage: obj.__len__() and returns: self