Skip to content

Commit

Permalink
Merge pull request #4 from ncaptier/bugfix/issue-3/sklearn-affinity-d…
Browse files Browse the repository at this point in the history
…eprecated

Fix deprecated parameter for AgglomerativeClustering function
  • Loading branch information
ncaptier authored Apr 23, 2024
2 parents 99bb7b6 + 180540d commit 4bc17d0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
"networkx>=2.7.1",
"pandas>=1.4.2",
"python-picard>=0.7",
"scikit-learn>=1.0.2",
"scikit-learn>=1.2.0",
"tqdm>=4.64.0",
"umap-learn>=0.5.3",
],
Expand Down
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 4bc17d0

Please sign in to comment.