code: def test_sparse_to_contiguous_ids(self) -> None:
      # Build the day .npy files. 3 days, 3 columns, 9 rows.
      unprocessed_data = [
          np.array([[10, 70, 10], [20, 80, 20], [30, 90, 30]]),  # day 0
          np.array([[20, 70, 40], [30, 80, 50], [40, 90, 60]]),  # day 1
          np.array([[20, 70, 70], [20, 80, 80], [30, 90, 90]]),  # day 2
      ]
  
      expected_data_no_freq_threshold = [
          np.array([[2, 2, 2], [3, 3, 3], [4, 4, 4]]),  # day 0
          np.array([[3, 2, 5], [4, 3, 6], [5, 4, 7]]),  # day 1
          np.array([[3, 2, 8], [3, 3, 9], [4, 4, 10]]),  # day 2
      ]
      self._validate_sparse_to_contiguous_preproc(
          unprocessed_data, expected_data_no_freq_threshold, 0, 3
      )
  
      expected_data_freq_threshold_2 = [
          np.array([[1, 2, 1], [2, 3, 1], [3, 4, 1]]),  # day 0
          np.array([[2, 2, 1], [3, 3, 1], [1, 4, 1]]),  # day 1
          np.array([[2, 2, 1], [2, 3, 1], [3, 4, 1]]),  # day 2
      ]
      self._validate_sparse_to_contiguous_preproc(
          unprocessed_data, expected_data_freq_threshold_2, 2, 3
      )
  
imports: import contextlib
  import math
  import os
  import random
  import tempfile
  from typing import Any, Dict, List, Optional
  import numpy
  from torch.utils.data import DataLoader
  from torchrec.datasets.criteo import BinaryCriteoUtils, CAT_FEATURE_COUNT, criteo_kaggle, criteo_terabyte, InMemoryBinaryCriteoIterDataPipe, INT_FEATURE_COUNT
  from torchrec.datasets.test_utils.criteo_test_utils import CriteoTest
  from torchrec.datasets.utils import Batch
label_desc: Use image node_id 5 for calling the TestBinaryCriteoUtils obj's underlying member method code with example usage: obj.test_sparse_to_contiguous_ids() without return types