Pyrosm Loading Nodes and Edges - Input must be valid geometry objects
Asked Answered
Y

0

8

Good morning all,

I am trying to load a .pbf file using the pyrosm library's documentation.

My code below.

import pyrosm

# Get filepath to test PBF dataset
fp = pyrosm.get_data("wisconsin")

# Initialize the OSM object 
osm = pyrosm.OSM(fp)

nodes, edges = osm.get_network(nodes=True)

print(f"Nodes {nodes} and edges {edges}")

I get the following error which seems to come from the library itself.

TypeError: Input must be valid geometry objects: MULTILINESTRING ((-89.5 44.5, -89.5 44.5), (-89.5 44.5, -89.5 44.5), (-89.5 44.5, -89.5 44.5), (-89.5 44.5, -89.5 44.5), (-89.5 44.5, -89.5 44.5))

Has anyone faced this issue before?

Thanks a lot

Yellow answered 28/10, 2021 at 9:34 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.