Example #1
0
 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
Example #2
0
 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
Example #3
0
 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
Example #4
0
 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