Density-based common-nearest-neighbour (CommonNN) clustering can be applied to arbitrary data sets. Here we demonstrate how to use the commonnn Python package to assign cluster labels to data points in different contexts.
A Python package for common-nearest-neighbour clustering