class_docstr: Samples elements randomly from a given list of indices, without replacement.
  
  Args:
      indices (sequence): a sequence of indices
      generator (Generator): Generator used in sampling.
class_docstr_tok: ["Samples","elements","randomly","from","a","given","list","of","indices",",","without","replacement",".","Args",":","indices","(","sequence",")",":","a","sequence","of","indices","generator","(","Generator",")",":","Generator","used","in","sampling","."]
code: def __iter__(self) -> Iterator[int]:
      return (
          self.indices[i]
          for i in torch.randperm(
              len(self.indices), generator=self.generator
          )
      )
  
imports: from typing import Iterator, Optional, Sized, Sequence
  import math
  from ....utils import require_not_none
label_desc: Use image node_id 2 for calling the SubsetRandomSampler obj's underlying member method code with example usage: obj.__iter__() and returns: unknown