"git@developer.sourcefind.cn:OpenDAS/vision.git" did not exist on "fec39cd5d2e09bd5eda2b4b97b426708bd10b26d"
Unverified Commit 21ff161d authored by Quan (Andy) Gan's avatar Quan (Andy) Gan Committed by GitHub
Browse files

fix occasional assertion fail (#611)

parent 84702916
...@@ -4,6 +4,8 @@ import scipy as sp ...@@ -4,6 +4,8 @@ import scipy as sp
import dgl import dgl
from dgl import utils from dgl import utils
np.random.seed(42)
def generate_rand_graph(n): def generate_rand_graph(n):
arr = (sp.sparse.random(n, n, density=0.1, format='coo') != 0).astype(np.int64) arr = (sp.sparse.random(n, n, density=0.1, format='coo') != 0).astype(np.int64)
return dgl.DGLGraph(arr, readonly=True) return dgl.DGLGraph(arr, readonly=True)
......
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