Skip to content

Commit 9547d3d

Browse files
author
Joao Felipe Rocha
committed
Changed all atol to -12
1 parent 4c633a5 commit 9547d3d

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

test/test_exact.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -424,7 +424,7 @@ def test_exact_graph_fixed_bandwidth():
424424
assert isinstance(G2, graphtools.graphs.TraditionalGraph)
425425
assert G.N == G2.N
426426
np.testing.assert_allclose(G.dw, G2.dw)
427-
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-14)
427+
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-12)
428428
bandwidth = np.random.gamma(5, 0.5, len(data))
429429
K = np.exp(-1 * (pdx.T / bandwidth).T ** decay)
430430
K = K + K.T
@@ -445,7 +445,7 @@ def test_exact_graph_fixed_bandwidth():
445445
assert isinstance(G2, graphtools.graphs.TraditionalGraph)
446446
assert G.N == G2.N
447447
np.testing.assert_allclose(G.dw, G2.dw)
448-
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-14)
448+
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-12)
449449

450450

451451
def test_exact_graph_callable_bandwidth():
@@ -504,7 +504,7 @@ def bandwidth(x):
504504
assert isinstance(G2, graphtools.graphs.TraditionalGraph)
505505
assert G.N == G2.N
506506
np.testing.assert_allclose(G.dw, G2.dw)
507-
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-14)
507+
np.testing.assert_allclose((G2.W - G.W).data, 0, atol=1e-12)
508508

509509

510510
#####################################################

test/test_knn.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -348,7 +348,7 @@ def test_knn_graph_fixed_bandwidth():
348348
np.testing.assert_array_equal(G.N, G2.N)
349349
np.testing.assert_array_equal(G.d, G2.d)
350350
np.testing.assert_allclose(
351-
(G.W - G2.W).data, np.zeros_like((G.W - G2.W).data), atol=1e-14
351+
(G.W - G2.W).data, np.zeros_like((G.W - G2.W).data), atol=1e-12
352352
)
353353
bandwidth = np.random.gamma(20, 0.5, len(data))
354354
K = np.exp(-1 * (pdx.T / (bandwidth * bandwidth_scale)).T ** decay)

0 commit comments

Comments
 (0)