code: def SaveLabels(IDs, labels, file):
      if ":" in file:
          file = file.split(":")[1]
      with open(file, "w") as f:
          for id in IDs:
              for i in range(len(IDs[id])):
                  f.write(
                      "{} {}\n".format(IDs[id][i], labels[id][i] + 1)
                  )
  
file_path: espnet/egs/libri_css/asr1/diarization/spec_clust.py
imports: import argparse
  import numpy
  import scipy
  from kaldiio import ReadHelper
  from sklearn.cluster import SpectralClustering
label_desc: Use image node_id 4 for calling a global function with example usage: SaveLabels(IDs, labels, file) without return types