Skip to main content

OpenStreetMap Stats Generator : Commandline

Project description

OpenStreetMap Stats Generator

On the Fly Commandline Stats Generator for OpenStreetMap User Contributions

I tweet stats Every day/week/month for Global/Region and #hotosm hashtag at https://twitter.com/stats_osm and store them OSMSG Stats Dir

Monitored stats are available under stats, Currently Bot monitors OSM as whole , hotosm hashtag , Nepal Country : weekly,monthly and yearly stats are stored in github and twitter.

Usage:

For installation & Local Setup follow Installation

osmsg [-h] [--start_date START_DATE] [--end_date END_DATE] [--username USERNAME]
             [--password PASSWORD] [--timezone {Nepal,UTC}] [--name NAME]
             [--country COUNTRY [COUNTRY ...]] [--tags TAGS [TAGS ...]]
             [--hashtags HASHTAGS [HASHTAGS ...]] [--length LENGTH [LENGTH ...]] [--force]
             [--field_mappers] [--meta] [--tm_stats] [--rows ROWS] [--users USERS [USERS ...]]
             [--workers WORKERS] [--url URL [URL ...]] [--last_week] [--last_day] [--last_month]
             [--last_year] [--last_hour] [--days DAYS] [--charts] [--summary] [--exact_lookup]
             [--changeset] [--all_tags] [--temp]
             [--format {csv,json,excel,image,text} [{csv,json,excel,image,text} ...]]
             [--read_from_metadata READ_FROM_METADATA] [--boundary BOUNDARY] [--update]

Options:

Hit following command for listing out the option with their documentation

osmsg --help

Features

It is a python package that processes osm files live and produces stats on the fly

  1. It can Generate Stats on Country Level for countries based on geofabrik urls . Countries are available in here
  2. It can also take any other server replication changefile to extract stats (Tested with Geofabrik and Planet Replication)
  3. Can Generate hashtag statistics
  4. Supports multiple output formats , Visualize Automatic Stats Being Genarated here
  5. It can create summary charts automatically along with stats , Visualize them here
  6. Can generate stats for any custom timestamp provided
{"name":"username","uid":uid,"changesets":1,"nodes.create":1071,"nodes.modify":2100,"nodes.delete":0,"ways.create":146,"ways.modify":69,"ways.delete":0,"relations.create":0,"relations.modify":1,"relations.delete":0,"building.create":138,"building.modify":11,"building.delete":0,"highway.create":5,"highway.modify":49,"highway.delete":0,"waterway.create":0,"waterway.modify":4,"waterway.delete":0,"amenity.create":0,"amenity.modify":3,"amenity.delete":0,"landuse.create":3,"landuse.modify":1,"landuse.delete":0,"natural.create":0,"natural.modify":3,"natural.delete":0,"total_map_changes":3387}

Get Started :

  • Extract Stat of last hour and visualize stats/charts

    By default replication is minute url.

osmsg --last_hour
  • With Hashtags information
osmsg --last_hour --changeset
  • Last week data with summary & all tags info and using day replication
osmsg --last_week --url day --summary --all_tags

For More , Follow Manual

Contributing

Contributions are always welcome! Follow Contributing Guidelines & Go through Code of Conduct

Version Control

Follow Version Control Docs

Request Stats Tracking on Github

Follow stats_request_docs

Visualize stats with streamlit

pip install streamlit
streamlit run streamlit_app.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

osmsg-0.2.3.tar.gz (1.7 MB view details)

Uploaded Source

Built Distribution

osmsg-0.2.3-py3-none-any.whl (30.9 kB view details)

Uploaded Python 3

File details

Details for the file osmsg-0.2.3.tar.gz.

File metadata

  • Download URL: osmsg-0.2.3.tar.gz
  • Upload date:
  • Size: 1.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.12.1

File hashes

Hashes for osmsg-0.2.3.tar.gz
Algorithm Hash digest
SHA256 181731770ca6775503c97abd9f3532d9ac82aba2302a2ef2b9e1dac4a6459f77
MD5 78547acfe6c4d9c85e0ab3bbc3ae270b
BLAKE2b-256 02939a378ff8876e00adb973e0a734c59eaf4c70c5aa5059a23ea9cc73504da2

See more details on using hashes here.

File details

Details for the file osmsg-0.2.3-py3-none-any.whl.

File metadata

  • Download URL: osmsg-0.2.3-py3-none-any.whl
  • Upload date:
  • Size: 30.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.12.1

File hashes

Hashes for osmsg-0.2.3-py3-none-any.whl
Algorithm Hash digest
SHA256 77a0fcb8ede674c4dae3cf3f1eecd0c2c6f598454af64c8e29c99ceb314051a7
MD5 e54563a4702cc7533a868090e55c721f
BLAKE2b-256 a9ce6ecf1f818361407bdadef9ef494080186840a5a5734f6b5fe30951030f45

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page