pyrosm | Read OpenStreetMap data from Protobuf files | Map library

 by   HTenkanen Python Version: v0.6.1 License: MIT

kandi X-RAY | pyrosm Summary

kandi X-RAY | pyrosm Summary

pyrosm is a Python library typically used in Geo, Map applications. pyrosm has no bugs, it has no vulnerabilities, it has build file available, it has a Permissive License and it has low support. You can download it from GitHub.

Pyrosm is a Python library for reading OpenStreetMap data from Protocolbuffer Binary Format -files (*.osm.pbf) into Geopandas GeoDataFrames. Pyrosm makes it easy to extract various datasets from OpenStreetMap pbf-dumps including e.g. road networks, buildings, Points of Interest (POI), landuse and natural elements. Also fully customized queries are supported which makes it possible to parse the data from OSM with more specific filters. Pyrosm is easy to use and it provides a somewhat similar user interface as OSMnx. The main difference between pyrosm and OSMnx is that OSMnx reads the data over internet using OverPass API, whereas pyrosm reads the data from local OSM data dumps that can be downloaded e.g. from GeoFabrik's website. This makes it possible to read data faster thus allowing e.g. parsing street networks for the whole country fairly efficiently (however, see caveats). The library has been developed by keeping performance in mind, hence, it is mainly written in Cython (Python with C-like performance) which makes it probably faster than any other Python alternatives for parsing OpenStreetMap data. Pyrosm is built on top of another Cython library called Pyrobuf which is a faster Cython alternative to Google's Protobuf library: It provides 2-4x boost in performance for deserializing the protocol buffer messages compared to Google's version with C++ backend. Google's Protocol Buffers is a commonly used and efficient method to serialize and compress structured data which is also used by OpenStreetMap contributors to distribute the OSM data in PBF format (Protocolbuffer Binary Format). Documentation is available at
Support
    Quality
      Security
        License
          Reuse

            kandi-support Support

              pyrosm has a low active ecosystem.
              It has 266 star(s) with 29 fork(s). There are 6 watchers for this library.
              OutlinedDot
              It had no major release in the last 12 months.
              There are 64 open issues and 75 have been closed. On average issues are closed in 59 days. There are 8 open pull requests and 0 closed requests.
              It has a neutral sentiment in the developer community.
              The latest version of pyrosm is v0.6.1

            kandi-Quality Quality

              pyrosm has 0 bugs and 76 code smells.

            kandi-Security Security

              pyrosm has no vulnerabilities reported, and its dependent libraries have no vulnerabilities reported.
              pyrosm code analysis shows 0 unresolved vulnerabilities.
              There are 1 security hotspots that need review.

            kandi-License License

              pyrosm is licensed under the MIT License. This license is Permissive.
              Permissive licenses have the least restrictions, and you can use them in most projects.

            kandi-Reuse Reuse

              pyrosm releases are available to install and integrate.
              Build file is available. You can build the component from source.
              Installation instructions are available. Examples and code snippets are not available.
              It has 4839 lines of code, 238 functions and 37 files.
              It has high code complexity. Code complexity directly impacts maintainability of the code.

            Top functions reviewed by kandi - BETA

            kandi has reviewed pyrosm and discovered the below as its top functions. This is intended to give you an instant insight into pyrosm implemented functionality, and help decide if they suit your requirements.
            • Returns the bounding box of a file
            • Validate a header block
            • Read file contents
            • Returns the filter for a given network type
            • Return a dict of drive filters
            • Return a dict of walking filters
            • Return a dictionary of cycling filters
            • Deprecated
            • Get data for a given dataset
            • Download data from given URL
            • Return the URL for a source
            • Convert size in bytes to GB
            • Download a file
            • Returns the size of a file
            • Read the long description
            • Calculate the length of a geometry
            • Calculate the great circle distance between two points
            • Calculates the length of a geom array
            Get all kandi verified functions for this library.

            pyrosm Key Features

            No Key Features are available at this moment for pyrosm.

            pyrosm Examples and Code Snippets

            No Code Snippets are available at this moment for pyrosm.

            Community Discussions

            QUESTION

            Python how to decode GIS boundary stored as bytes?
            Asked 2021-Nov-19 at 00:39

            I extracted some points of interest from Open Street Map (using the pyrosm package) that I later exported to a parquet file. Here are the geometries, which have type shapely.geometry:

            ...

            ANSWER

            Answered 2021-Nov-19 at 00:39

            The format seems to be WKB, see https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry

            There are many packages that can decode it, but it is geometry-specific binary format, so you would need to use some geometry-specific package like geopndas or parse_wkb to decode it.

            Source https://stackoverflow.com/questions/70027297

            Community Discussions, Code Snippets contain sources that include Stack Exchange Network

            Vulnerabilities

            No vulnerabilities reported

            Install pyrosm

            Pyrosm is distributed via PyPi and conda-forge.

            Support

            Notice that pyrosm requires geopandas to work. On Linux and Mac installing geopandas with pip should work without a problem, which is handled automatically when installing pyrosm. However, on Windows installing geopandas with pip is likely to cause issues, hence, it is recommended to install Geopandas before installing pyrosm. See instructions from Geopandas website.
            Find more information at:

            Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items

            Find more libraries
            CLONE
          • HTTPS

            https://github.com/HTenkanen/pyrosm.git

          • CLI

            gh repo clone HTenkanen/pyrosm

          • sshUrl

            git@github.com:HTenkanen/pyrosm.git

          • Stay Updated

            Subscribe to our newsletter for trending solutions and developer bootcamps

            Agree to Sign up and Terms & Conditions

            Share this Page

            share link