Skip to content

Commit

Permalink
Change affinity to metric for AgglomerativeClustering
Browse files Browse the repository at this point in the history
  • Loading branch information
ncaptier committed Apr 23, 2024
1 parent 99bb7b6 commit 0b06882
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sica/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ def fit(self, X: np.ndarray, y: Optional[Any] = None) -> object:

# Cluster the components with hierarchical clustering
clustering = AgglomerativeClustering(
n_clusters=self.n_components, affinity="precomputed", linkage="average"
n_clusters=self.n_components, metric="precomputed", linkage="average"
).fit(1 - self._Sim)
self._clusters = clustering.labels_

Expand Down

0 comments on commit 0b06882

Please sign in to comment.