code: def test_whisper_pipeline_layers():
      num_test_cases = 4
      test_dict = {
          "num_encoder_layers": [2, 3, 2, 4],
          "num_decoder_layers": [2, 0, 2, 8],
          "num_stages": [2, 2, 4, 4],
          "layers_per_stage": [
              [[0, 2], [0, 2]],
              [[0, 1], [1, 3]],
              [[0, 1], [1, 2], [0, 1], [1, 2]],
              [[0, 4], [0, 3], [3, 6], [6, 8]],
          ],
      }
  
      for i in range(num_test_cases):
          (
              layers_per_stage,
              decoder_starting_stage,
          ) = WhisperPolicy.distribute_whisper_layers(
              test_dict["num_encoder_layers"][i],
              test_dict["num_decoder_layers"][i],
              test_dict["num_stages"][i],
          )
  
          for stage in range(test_dict["num_stages"][i]):
              start_idx, end_idx = test_dict["layers_per_stage"][i][
                  stage
              ]
              (
                  predicted_start,
                  predicted_end,
              ) = WhisperPolicy.get_whisper_stage_index(
                  layers_per_stage, stage, decoder_starting_stage
              )
              assert start_idx == predicted_start
              assert end_idx == predicted_end
  
label_desc: Use image node_id 2 for calling a global function with example usage: test_whisper_pipeline_layers() without return types