code: def get_contiguous_stamps(stamps):
      """
      Return contiguous time stamps
      """
      lines = deepcopy(stamps)
      contiguous_stamps = []
      for i in range(len(lines) - 1):
          start, end, speaker = lines[i].split()
          next_start, next_end, next_speaker = lines[i + 1].split()
          if float(end) > float(next_start):
              avg = str((float(next_start) + float(end)) / 2.0)
              lines[i + 1] = " ".join([avg, next_end, next_speaker])
              contiguous_stamps.append(
                  start + " " + avg + " " + speaker
              )
          else:
              contiguous_stamps.append(
                  start + " " + end + " " + speaker
              )
      start, end, speaker = lines[-1].split()
      contiguous_stamps.append(start + " " + end + " " + speaker)
      return contiguous_stamps
  
imports: import gc
  import json
  import math
  import os
  import shutil
  from copy import deepcopy
  from typing import Dict, List, Tuple, Union
  import numpy
  import omegaconf
  import soundfile
  import torch
  from pyannote.core import Annotation, Segment
  from tqdm import tqdm
  from nemo.collections.asr.data.audio_to_label import repeat_signal
  from nemo.collections.asr.parts.utils.longform_clustering import LongFormSpeakerClustering
  from nemo.collections.asr.parts.utils.offline_clustering import SpeakerClustering, get_argmin_mat, split_input_data
  from nemo.utils import logging
label_desc: Use image node_id 8 for calling a global function with example usage: get_contiguous_stamps(stamps) and returns: contiguous_stamps