rnet.read_osm#

rnet.read_osm(path, *, crs=4326, layer_name='lines', exclude=[])#

Read a single OSM file.

Parameters
pathstr

OSM file path.

crsint, optional

EPSG code of desired CRS for point coordinates. OSM features are represented in EPSG:4326. The default is 4326. If another EPSG code is given, then point coordinates are transformed.

Returns
verticesVertexData

Vertices extracted from the OSM files.

linksLinkData

Undirected links extracted from the OSM files.

Other Parameters
layer_namestr, optional

Name of the layer from which OSM features are read. The default is ‘lines’.

excludeList[str], optional

Tags to exclude. By default, the following tags are included: ‘living_street’, ‘residential’, ‘unclassified’, ‘tertiary_link’, ‘tertiary’, ‘secondary_link’, ‘secondary’, ‘primary_link’, ‘primary’, ‘trunk_link’, ‘trunk’, ‘motorway_link’, ‘motorway’.

See also

read_osms()

Read multiple OSM files.

References

https://wiki.openstreetmap.org/wiki/Key:highway