"tutorial/capsule/Simple Routing.ipynb" did not exist on "9c135fd5dffcc9082f7a1ec0b7eae87543dcde65"
Unverified Commit 13cbad32 authored by Andrei Ivanov's avatar Andrei Ivanov Committed by GitHub
Browse files

Suppressing warnings generated by the `test_prop_nodes_topo` test. (#6651)


Co-authored-by: default avatarHongzhi (Steve), Chen <chenhongzhi.nkcs@gmail.com>
parent b569e4be
...@@ -100,6 +100,14 @@ def test_prop_nodes_topo(idtype): ...@@ -100,6 +100,14 @@ def test_prop_nodes_topo(idtype):
tree.ndata["x"] = F.zeros((5, 2)) tree.ndata["x"] = F.zeros((5, 2))
# set all leaf nodes to be ones # set all leaf nodes to be ones
tree.nodes[[1, 3, 4]].data["x"] = F.ones((3, 2)) tree.nodes[[1, 3, 4]].data["x"] = F.ones((3, 2))
# Filtering DGLWarning:
# The input graph for the user-defined edge
# function does not contain valid edges
import warnings
with warnings.catch_warnings():
warnings.simplefilter("ignore", category=UserWarning)
dgl.prop_nodes_topo( dgl.prop_nodes_topo(
tree, message_func=mfunc, reduce_func=rfunc, apply_node_func=None tree, message_func=mfunc, reduce_func=rfunc, apply_node_func=None
) )
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment