Skip to content

Commit 0bf7536

Browse files
committed
Merge pull request #5189 from GaelVaroquaux/pr_4779
Pr 4779: Implemented parallelised version of mean_shift and test function
2 parents 190abde + c4721f3 commit 0bf7536

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

sklearn/cluster/tests/test_mean_shift.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,13 +46,14 @@ def test_mean_shift():
4646
n_clusters_ = len(labels_unique)
4747
assert_equal(n_clusters_, n_clusters)
4848

49+
4950
def test_parallel():
50-
ms1 = MeanShift(n_jobs=-1)
51+
ms1 = MeanShift(n_jobs=2)
5152
ms1.fit(X)
52-
53+
5354
ms2 = MeanShift()
5455
ms2.fit(X)
55-
56+
5657
assert_array_equal(ms1.cluster_centers_,ms2.cluster_centers_)
5758
assert_array_equal(ms1.labels_,ms2.labels_)
5859

0 commit comments

Comments
 (0)