Skip to content

AssertionError: NeighborSampler doesn't support mutable graphs. Please turn it into an immutable graph with DGLGraphStale.readonly #9

@HandsomeEffortMonster

Description

@HandsomeEffortMonster

DGLGraph now always supports mutable operations like add_nodes and add_edges.
return warnings.warn(message, category=category, stacklevel=1)
Traceback (most recent call last):
File "/tmp/pycharm_project_609/KPGNN/main.py", line 139, in
train_indices, indices_to_remove, model = KPGNN.initial_maintain(train_i, 0, data_split, metrics,
File "/tmp/pycharm_project_609/KPGNN/model.py", line 420, in initial_maintain
for batch_id, nf in enumerate(dgl.contrib.sampling.NeighborSampler(g,
File "/home/x/miniconda3/envs/python39/lib/python3.9/site-packages/dgl/contrib/sampling/sampler.py", line 320, in init
assert g.is_readonly, "NeighborSampler doesn't support mutable graphs. " +
AssertionError: NeighborSampler doesn't support mutable graphs. Please turn it into an immutable graph with DGLGraphStale.readonly
ERROR conda.cli.main_run:execute(125): conda run python /tmp/pycharm_project_609/KPGNN/main.py failed. (See above for error)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions