code: def template_clustering(
      data_path, intervals, density_threshold, **kwargs
  ):
      print("Sample: '%s'." % os.path.basename(data_path))
  
      data = read_sample(data_path)
  
      clique_instance = clique(data, intervals, density_threshold)
      clique_instance.process()
  
      clusters = clique_instance.get_clusters()
      noise = clique_instance.get_noise()
      cells = clique_instance.get_cells()
  
      print([len(cluster) for cluster in clusters])
  
      clique_visualizer.show_grid(cells, data)
  
      visualizer = cluster_visualizer()
      visualizer.append_clusters(clusters, data)
      visualizer.append_cluster(noise, data, marker="x")
      visualizer.show()
  
imports: import os
  from pyclustering.cluster import cluster_visualizer
  from pyclustering.cluster.clique import clique, clique_visualizer
  from pyclustering.utils import read_sample
  from pyclustering.samples.definitions import SIMPLE_SAMPLES, FCPS_SAMPLES
label_desc: Use image node_id 1 for calling a global function with example usage: template_clustering(data_path, intervals, density_threshold) without return types