code: def __init__(
      self,
      keys: List[str],
      batch_size: int,
      hash_sizes: List[int],
      ids_per_features: List[int],
      num_dense: int,
      manual_seed: Optional[int] = None,
      num_generated_batches: int = 10,
      num_batches: Optional[int] = None,
      *,
      min_ids_per_features: Optional[List[int]] = None,
  ) -> None:
      self.keys = keys
      self.keys_length: int = len(keys)
      self.batch_size = batch_size
      self.hash_sizes = hash_sizes
      self.ids_per_features = ids_per_features
      self.min_ids_per_features: List[int] = (
          min_ids_per_features
          if min_ids_per_features
          else [0] * len(ids_per_features)
      )
      self.num_dense = num_dense
      self.num_batches = num_batches
      self.num_generated_batches = num_generated_batches
  
      if manual_seed is not None:
          self.generator = torch.Generator()
          self.generator.manual_seed(manual_seed)
      else:
          self.generator = None
  
      self._generated_batches: List[Batch] = [
          self._generate_batch() for _ in range(num_generated_batches)
      ]
      self.batch_index = 0
  
file_path: torchrec/torchrec/datasets/random.py
imports: import itertools
  import sys
  from typing import cast, Iterator, List, Optional
  import torch
  from torch.utils.data.dataset import IterableDataset
  from torchrec.datasets.utils import Batch
  from torchrec.sparse.jagged_tensor import KeyedJaggedTensor
label_desc: Use image node_id 1 to create a new _RandomRecBatch object  with example: obj = _RandomRecBatch(keys, batch_size, hash_sizes, ids_per_features, num_dense, manual_seed, num_generated_batches, num_batches)