From c0e946771c3a15e15e7cee0942efb95ce75c1c1e Mon Sep 17 00:00:00 2001 From: Andrei Ivanov Date: Wed, 16 Oct 2024 11:17:54 -0700 Subject: [PATCH] Fixing AttributeError: module 'numpy' has no attribute `exceptions` --- tests/python/common/sampling/test_sampling.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/python/common/sampling/test_sampling.py b/tests/python/common/sampling/test_sampling.py index f52ea3c2e5dc..74c2b000ba96 100644 --- a/tests/python/common/sampling/test_sampling.py +++ b/tests/python/common/sampling/test_sampling.py @@ -1774,7 +1774,7 @@ def contain_edge(g, sg, u, v): @pytest.mark.parametrize("dtype", ["int32", "int64"]) def test_global_uniform_negative_sampling(dtype): - warnings.simplefilter("ignore", np.exceptions.ComplexWarning) + warnings.simplefilter("ignore", np.ComplexWarning) g = dgl.graph(([], []), num_nodes=1000).to(F.ctx()) src, dst = dgl.sampling.global_uniform_negative_sampling( g, 2000, False, True