Untitled

 avatar
unknown
plain_text
2 months ago
219 B
4
Indexable
from sklearn.cluster import MeanShift, estimate_bandwidth

bandwidth = estimate_bandwidth(embeddings, quantile=0.2)
ms = MeanShift(bandwidth=bandwidth, bin_seeding=True)
cluster_labels = ms.fit_predict(embeddings)
Leave a Comment