code: def _find_duplicates_greedy(ious, iou_thresh):
      # Choose the largest subset of indices s.t. no two are within `iou_thresh`
      A = np.triu(ious, k=1) > iou_thresh
  
      dup_inds = []
      while True:
          i, j = np.nonzero(A)
          if j.size == 0:
              break
  
          # Remove most common value
          k = np.argmax(np.bincount(np.concatenate((i, j))))
          dup_inds.append(k)
          A[k, :] = False
          A[:, k] = False
  
      return sorted(dup_inds)
  
imports: import contextlib
  import itertools
  import logging
  import numpy
  import scipy.spatial
  import eta.core.numutils
  import eta.core.utils
  import fiftyone.core.labels
  import fiftyone.core.utils
  import fiftyone.core.validation
  from .utils3d import compute_cuboid_iou
label_desc: Use image node_id 10 for calling a global function with example usage: _find_duplicates_greedy(ious, iou_thresh) and returns: sorted