(N=1)
| 103 | |
| 104 | |
| 105 | def test_euclidean(N=1): |
| 106 | np.random.seed(12345) |
| 107 | i = 0 |
| 108 | while i < N: |
| 109 | N = np.random.randint(1, 100) |
| 110 | x = np.random.rand(N) |
| 111 | y = np.random.rand(N) |
| 112 | mine = euclidean(x, y) |
| 113 | theirs = scipy.spatial.distance.euclidean(x, y) |
| 114 | np.testing.assert_almost_equal(mine, theirs) |
| 115 | print("PASSED") |
| 116 | i += 1 |
| 117 | |
| 118 | |
| 119 | def test_hamming(N=1): |
nothing calls this directly
no test coverage detected