Cluster¶
IngeoML.cluster
API¶
- farthest_first_traversal(X: ndarray, num: int = 512)[source]¶
- Parameters:
X (np.ndarray) – Elements
num (int) – Number of elements
>>> from IngeoML.cluster import farthest_first_traversal >>> import numpy as np >>> data = np.array([[1, 0, 0, 0], [1, 0, 1, 0], [0, 1, 0, 0]]) >>> farthest_first_traversal(data, num=2) [0, 2]