code: def test_constant_ranges():
      def data_gen():
          return [
              np.float32([[0, 1, 2], [3, 4, 5]]),
              np.float32([[0, 1], [2, 3], [4, 5]]),
          ]
  
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          1:, :2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          -1:, :-2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :-1, :-1
      ], None
      yield _test_indexing, data_gen, "AB", "B", lambda x: x[
          1, :2
      ], None
      yield _test_indexing, data_gen, "AB", "B", lambda x: x[
          1, :-2
      ], None
      yield _test_indexing, data_gen, "AB", "A", lambda x: x[
          :-1, -1
      ], None
      yield _test_indexing, data_gen, "AB", "A", lambda x: x[
          :-1, 0
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::-1, :
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::-2, :
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::2, :
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, ::-1
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, ::2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, ::-2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, 1::-2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, -2::-1
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :-2:2, :
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, 2::-2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          :, :1:-1
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::2, ::2
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::-1, ::-1
      ], None
      yield _test_indexing, data_gen, "AB", "AB", lambda x: x[
          ::-2, ::-2
      ], None
  
imports: from nvidia import dali
  from nvidia.dali import fn
  import numpy
  from nvidia.dali.pipeline import Pipeline
  from nose_utils import assert_raises
label_desc: Use image node_id 4 for calling a global function with example usage: test_constant_ranges() and returns: list