code: def _find_parent(parent, u):
      idx = []
      # parent is a fixed point
      while u != parent[u]:
          idx.append(u)
          u = parent[u]
      for i in idx:
          parent[i] = u
      return u
  
file_path: dgl/examples/pytorch/hilander/utils/deduce.py
imports: import dgl
  import numpy
  import torch
  from sklearn import mixture
  from .density import density_to_peaks, density_to_peaks_vectorize
label_desc: Use image node_id 1 for calling a global function with example usage: _find_parent(parent, u) and returns: u