コード例 #1
0
ファイル: tests.py プロジェクト: Nikita-Ting/kmeans
 def test_generate_k_three_dimensions(self, three_dimensional_points):
     for i in xrange(1000):
         centers = generate_k(three_dimensional_points, 10)
         for point in centers:
             assert 1 < point[0] < 6
             assert 2 < point[1] < 7
             assert 0 < point[1] < 8
コード例 #2
0
ファイル: tests.py プロジェクト: dhuib2016/kmeans
 def test_generate_k_three_dimensions(self, three_dimensional_points):
     for i in range(1000):
         centers = generate_k(three_dimensional_points, 10)
         for point in centers:
             assert 1 < point[0] < 6
             assert 2 < point[1] < 7
             assert 0 < point[1] < 8
コード例 #3
0
ファイル: tests.py プロジェクト: Nikita-Ting/kmeans
 def test_generate_k_two_dimensions(self, two_dimensional_points):
     for i in xrange(1000):
         centers = generate_k(two_dimensional_points, 10)
         for point in centers:
             assert 0 < point[0] < 10
             assert 5 < point[1] < 15
コード例 #4
0
ファイル: tests.py プロジェクト: dhuib2016/kmeans
 def test_generate_k_two_dimensions(self, two_dimensional_points):
     for i in range(1000):
         centers = generate_k(two_dimensional_points, 10)
         for point in centers:
             assert 0 < point[0] < 10
             assert 5 < point[1] < 15