I got an error of ‘DGLError: Mutation is not supported in heterograph.’ when I try to add nodes/edges to a dgl.graph object. What I did was using the homograph API add_nodes/add_edge on a dgl.graph object.
Here is my code:
g = dgl.graph()
Is these API not supported for heterograph? Or is there any other methods to add nodes/edges to a dgl.graph in a loop instead of adding at the instantiation of a dgl.graph?