code: def prepare_data(
      self,
      split: str,
      layer: str,
      num_shards: int,
      feat_shape: Tuple[int, int],
  ):
      batch_size, feat_size = feat_shape
      total = batch_size * num_shards
  
      # Generate a dataset
      indices = np.arange(0, total)
      features = np.random.random(size=(total, feat_size))
      targets = np.random.randint(low=0, high=10, size=(total, 1))
  
      # Randomly shuffle it
      permutation = np.random.permutation(total)
      permuted_features = features[permutation]
      permuted_targets = targets[permutation]
      permuted_indices = indices[permutation]
  
      # And save each part in shards
      for i in range(num_shards):
          shard_features = permuted_features[
              i * batch_size : (i + 1) * batch_size
          ]
          shard_targets = permuted_targets[
              i * batch_size : (i + 1) * batch_size
          ]
          shard_indices = permuted_indices[
              i * batch_size : (i + 1) * batch_size
          ]
          save_file(
              shard_features, f"chunk{i}_{split}_{layer}_features.npy"
          )
          save_file(
              shard_targets, f"chunk{i}_{split}_{layer}_targets.npy"
          )
          save_file(shard_indices, f"chunk{i}_{split}_{layer}_inds.npy")
  
      # Return the data used to generate the files
      return indices, features, targets
  
file_path: vissl/tests/test_extract_features_utils.py
imports: import os
  import unittest
  from typing import Tuple
  import numpy
  from vissl.utils.extract_features_utils import ExtractedFeaturesLoader
  from vissl.utils.io import save_file
  from vissl.utils.test_utils import in_temporary_directory
label_desc: Use image node_id 1 for calling the TestExtractFeatureUtils obj's underlying member method code with example usage: obj.prepare_data(split, layer, num_shards, feat_shape) and returns: indices,  features,  targets