class_docstr: Describes a batch or sub-batch of work in sample mode that consists of SampleInfo
  instances with consecutive indices. It denotes range of samples within given `iteration`
  of given `epoch_idx`, optionally specifying a slice/sub-range of the sample range.
  It does not support spanning over multiple batches. Used to avoid linear dependency of the task
  description size on the batch size.
code: def _get_slice(self, range_slice: slice):
      if range_slice.step is not None and range_slice.step != 1:
          raise ValueError(
              "SampleRange only supports slicing with step 1"
          )
  
      slice_start = self._get_index(range_slice.start, self.slice_start)
      slice_end = self._get_index(range_slice.stop, self.slice_end)
      slice_start = min(slice_start, self.slice_end)
      slice_end = max(min(slice_end, self.slice_end), slice_start)
      return SampleRange(
          self.sample_start,
          self.sample_end,
          self.iteration,
          self.epoch_idx,
          slice_start=slice_start,
          slice_end=slice_end,
      )
  
imports: from typing import Optional
  from nvidia.dali.types import SampleInfo
  from nvidia.dali._multiproc.struct_message import Structure
label_desc: Use image node_id 3 for calling the SampleRange obj's underlying member method code with example usage: obj._get_slice(range_slice) and returns: SampleRange