"src/git@developer.sourcefind.cn:renzhc/diffusers_dcu.git" did not exist on "d8bc1a4e5124cd70fede43ad6ce4aa4095f07de3"
Unverified Commit 23ef2ddd authored by Kunal Mukherjee's avatar Kunal Mukherjee Committed by GitHub
Browse files

[Fix] np.asscalar deprecated usage (#5557)


Co-authored-by: default avatarkxm180046 <kxm180046@utdallas.edu>
Co-authored-by: default avatarMufei Li <mufeili1996@gmail.com>
parent bea5c78b
...@@ -1313,8 +1313,8 @@ def test_convert(idtype): ...@@ -1313,8 +1313,8 @@ def test_convert(idtype):
dsttype = hg.ntypes[ntype_id[dst[i]]] dsttype = hg.ntypes[ntype_id[dst[i]]]
etype = hg.etypes[etype_id[i]] etype = hg.etypes[etype_id[i]]
src_i, dst_i = hg.find_edges([eid[i]], (srctype, etype, dsttype)) src_i, dst_i = hg.find_edges([eid[i]], (srctype, etype, dsttype))
assert np.asscalar(F.asnumpy(src_i)) == nid[src[i]] assert F.asnumpy(src_i).item() == nid[src[i]]
assert np.asscalar(F.asnumpy(dst_i)) == nid[dst[i]] assert F.asnumpy(dst_i).item() == nid[dst[i]]
mg = nx.MultiDiGraph( mg = nx.MultiDiGraph(
[ [
......
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