Closed aminKMT closed 6 years ago
This needs to be adjusted to the new networkx 2.0 version (changing edges_iter() method into edges() method)
I corrected the networkx errors, to account for the new version networkx 2.0
Dear Dr. Simon,
Thanks a lot to update me,
Regards,
Amin,
On Tue, Feb 20, 2018 at 8:23 AM, simonscheider notifications@github.com wrote:
Closed #2 https://github.com/simonscheider/mapmatching/issues/2.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/simonscheider/mapmatching/issues/2#event-1482511955, or mute the thread https://github.com/notifications/unsubscribe-auth/AhT0fJfYogzkL-pf5jDjgHahvtPzG6ZTks5tWtVvgaJpZM4ROyiv .
Hi! I'm using mapmatcher python code, but when I run it with both my data and test data it gives me the attribute error (AttributeError: 'Graph' object has no attribute 'edges_iter'). I updated my networkx by pip install, but it still did not work and I got the same error. could you please let me know how I can solve it. Thanks, In the following you can see what I got in python:
track size:14 Number of segments: 745 C:\Users\amin.keramati\Desktop\tPRROMTO2\AminShp\testSegments.shp graph size (excluding unconnected parts): 573
Traceback (most recent call last): File "C:\Users\amin.keramati\Desktop\tPRROMTO2\mapmatcher\mapmatcher11.py", line 510, in opt = mapMatch(trackname, roadname, 20, 10, 50) File "C:\Users\amin.keramati\Desktop\tPRROMTO2\mapmatcher\mapmatcher11.py", line 87, in mapMatch graph = getNetworkGraph(segments,lengths) File "C:\Users\amin.keramati\Desktop\tPRROMTO2\mapmatcher\mapmatcher11.py", line 469, in getNetworkGraph for n0, n1 in sg.edges_iter(): AttributeError: 'Graph' object has no attribute 'edges_iter'