mims-harvard / ohmnet

OhmNet: Representation learning in multi-layer graphs
http://snap.stanford.edu/ohmnet
MIT License
79 stars 33 forks source link

Weighted graph mistakes #5

Open ghost opened 4 years ago

ghost commented 4 years ago

Dear professiors Marinka Zitnik and Jure Leskovec I get wrong messages when I want to run Weighted graph.The messages is "TypeError: read_edgelist() got an unexpected keyword argument 'inodetype' “. and I explored the source code. I find there is a mistake in read_net function which in utility.py file The source code is " if weighted: G = nx.read_edgelist(inodetype=int, data=(('weight', float),), create_using=nx.DiGraph()) " .It may be fixed as if weighted: G = nx.read_edgelist(fname, nodetype=int, data=(('weight', float),), create_using=nx.DiGraph()) sincerely He

marinkaz commented 4 years ago

Thank you for your comment! If you can make a pull request with this issue fixed, we would be excited to merge the request.