{"id":19858941,"url":"https://github.com/joaocarabetta/osm-road-length","last_synced_at":"2025-05-02T02:31:18.581Z","repository":{"id":57449753,"uuid":"257612745","full_name":"JoaoCarabetta/osm-road-length","owner":"JoaoCarabetta","description":"Calculate Open Street Maps road length for any polygon","archived":false,"fork":false,"pushed_at":"2023-05-22T23:23:59.000Z","size":51,"stargazers_count":17,"open_issues_count":3,"forks_count":2,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-22T16:06:20.086Z","etag":null,"topics":["data-science","osm","python","urban-analytics","urban-data-science"],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/JoaoCarabetta.png","metadata":{"files":{"readme":"README.rst","changelog":"HISTORY.rst","contributing":"CONTRIBUTING.rst","funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS.rst","dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-04-21T13:56:15.000Z","updated_at":"2024-06-20T16:24:42.000Z","dependencies_parsed_at":"2024-11-12T14:37:10.044Z","dependency_job_id":null,"html_url":"https://github.com/JoaoCarabetta/osm-road-length","commit_stats":{"total_commits":22,"total_committers":2,"mean_commits":11.0,"dds":0.4545454545454546,"last_synced_commit":"fb4e12eb0d11445a00b77c2a459e8b707cb77140"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoaoCarabetta%2Fosm-road-length","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoaoCarabetta%2Fosm-road-length/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoaoCarabetta%2Fosm-road-length/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/JoaoCarabetta%2Fosm-road-length/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/JoaoCarabetta","download_url":"https://codeload.github.com/JoaoCarabetta/osm-road-length/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":251972491,"owners_count":21673613,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["data-science","osm","python","urban-analytics","urban-data-science"],"created_at":"2024-11-12T14:25:00.879Z","updated_at":"2025-05-02T02:31:17.525Z","avatar_url":"https://github.com/JoaoCarabetta.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"===============\nOSM Road Length\n===============\n\n|Maintenance yes|\n|PyPI version fury.io|\n|PyPI download total|\n|PyPI download month|\n\n.. |PyPI version fury.io| image:: https://badge.fury.io/py/osm-road-length.svg\n   :target: https://badge.fury.io/py/osm-road-length\n.. |PyPI download month| image:: https://pepy.tech/badge/osm-road-length/month\n   :target: https://pepy.tech/project/osm-road-length/month\n.. |PyPI download total| image:: https://pepy.tech/badge/osm-road-length\n   :target: https://pepy.tech/project/osm-road-length\n.. |Maintenance yes| image:: https://img.shields.io/badge/Maintained%3F-yes-green.svg\n   :target: https://GitHub.com/Naereen/StrapDown.js/graphs/commit-activity\n\nDISCONTINUED!\nUSE OSMPY\nhttps://github.com/JoaoCarabetta/osmpy\n\nA tool to get the highway length from Open Street Maps of a region using Python using Overpass Turbo API.\n\nIt supports any region size and shape. From cities to continents.\n\nInstalling\n-----------\n.. code:: bash\n\n   pip install osm-road-length\n\nUsing\n-----\n\n.. code:: python        \n        \n        import osm_road_length\n        from shapely import wkt\n\n        geometry = wkt.loads('POLYGON((-43.2958811591311 -22.853167273541693,-43.30961406928735 -23.035275736044728,-43.115980036084224 -23.02010939749927,-43.157178766552974 -22.832917893834313,-43.2958811591311 -22.853167273541693))')\n\n        length = osm_road_length.get(geometry)\n\nWhy not OSMnx?\n--------------\n\nOSMnx_ is a great package if you want to analyse the road infrastructure in depth. But, sometimes we just want simple numbers to do comparissons. This package does not load all road data to memory (imagine loading a whole country to your RAM). The package fetches the Overpass API directly. If the region is too large, it splits the region in a smart way to handle the Overpass API constrains. \n\n.. _OSMnx: https://github.com/gboeing/osmnx\n\nCredits\n-------\n\n* Free software: MIT license\n\nFunction `katana` from snorfalorpagus_.\n\n.. _snorfalorpagus: https://snorfalorpagus.net/blog/2016/03/13/splitting-large-polygons-for-faster-intersections/\n\nThis package was created with Cookiecutter_ and the `audreyr/cookiecutter-pypackage`_ project template.\n\n.. _Cookiecutter: https://github.com/audreyr/cookiecutter\n.. _`audreyr/cookiecutter-pypackage`: https://github.com/audreyr/cookiecutter-pypackage\n    \n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoaocarabetta%2Fosm-road-length","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjoaocarabetta%2Fosm-road-length","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjoaocarabetta%2Fosm-road-length/lists"}