I tried to read gml file using Networkx with this code : G=nx.read_gml("cond-mat-2003.gml",relabel="true"). But I found this error : networkxerror: failed to relabel nodes : duplicate node label founds. Use relabel=False. I need the labels for further process. How to solve this problem? Thanks a lot.
0
votes
1 Answers
0
votes
I believe this error means that more than one node has been given the same label in cond-mat-2003.gml. There's not much you can do about that. Perhaps find the node(s) and figure out whether it's a real duplicate or not (it's a big file, so this may not be trivial). It might be worth emailing the person responsible for the gml file - but he's fairly busy, so I'd first figure out what nodes are causing the problem and call his attention to it then.
relabel="true"? - Joelrelabel="true"doesn't appear to be the source of your error, but you mean to userelabel=True(error still remains for that file) - Joel