{ "info": { "author": "Anu Joy", "author_email": "oss@cartographix.org", "bugtrack_url": null, "classifiers": [ "Development Status :: 5 - Production/Stable", "License :: OSI Approved :: MIT License", "Operating System :: OS Independent", "Programming Language :: Python :: 2.7", "Programming Language :: Python :: 3.4", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: 3.7", "Topic :: Scientific/Engineering :: GIS", "Topic :: Software Development :: Libraries :: Python Modules" ], "description": "[![Build Status](https://travis-ci.org/joyanujoy/geolib.svg?branch=master)](https://travis-ci.org/joyanujoy/geolib) ![python 2.7|3.4|3.5|3.6|3.7](https://img.shields.io/badge/python-2.7|3.4|3.5|3.6|3.7-blue.svg)[![Downloads](https://pepy.tech/badge/geolib)](https://pepy.tech/project/geolib)\n\n# Geolib\nA python library for geohash encoding, decoding and finding neighbour cells. This is a python port of [Chris Veness' javascript implementation](https://www.movable-type.co.uk/scripts/geohash.html).\n\n[Wikipedia reference](http://en.wikipedia.org/wiki/Geohash)\n## Installation\n```pipenv install geolib```\nor\n```pip install geolib```\n## Usage\n\n from geolib import geohash\n ### Encode a latitude, longtiude to geohash\n geohash.encode(latitude, longitude, precision)\n >>> geohash.encode('70.2995', '-27.9993', 7)\n >>> gkkpfve\n\n ### Decode a geohash to latitude, longitude\n geohash.decode(geohash), returns latitude, longitude as tuple of decimals\n >>> geohash.decode('gkkpfve')\n >>> (70.2995, -27.9993)\n\n ### Find neighbouring cells of a geohash\n geohash.neighbours(geohash) \n retuns a namedtuple (n, ne, e, se, s, sw, w, nw) \n\n >>> neighbours = geohash.neighbours('gcpuyph')\n >>> neighbours\n >>> ('gcpuypk', 'gcpuypm', 'gcpuypj', 'gcpuynv', 'gcpuynu', 'gcpuyng', 'gcpuyp5', 'gcpuyp7')\n >>> neighbours.ne\n >>> gcpuypm\n\n ### Find adjacent cell in a given direction\n geohash.adjacent(geohash, direction)\n >>> geohash.adjacent('gcpuyph', 'n')\n >>> gcpuypk\n\n ### Find SW/NE latitude/longitude bounds of a geohash\n geohash.bounds(geohash)\n returns a namedtuple ((sw_lat, sw_lon), ((ne_lat, ne_lon))\n >>> bounds = geohash.bounds('ezs42')\n >>> bounds\n >>> ((42.583, -5.625), (42.627, -5.58)))\n >>> bounds.sw.lat \n >>> 42.583\n\n## Documentation\n [Geolib readthedocs](https://geolib.readthedocs.io/en/latest/)\n\n\n", "description_content_type": "text/markdown", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/joyanujoy/geolib", "keywords": "", "license": "", "maintainer": "", "maintainer_email": "", "name": "geolib", "package_url": "https://pypi.org/project/geolib/", "platform": "", "project_url": "https://pypi.org/project/geolib/", "project_urls": { "Homepage": "https://github.com/joyanujoy/geolib" }, "release_url": "https://pypi.org/project/geolib/1.0.7/", "requires_dist": [ "future" ], "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "summary": "A library for geohash encoding, decoding and associated functions", "version": "1.0.7" }, "last_serial": 5226760, "releases": { "1.0.5": [ { "comment_text": "", "digests": { "md5": "458c7be2c959500a70bc8710cfbfbb70", "sha256": "35848a01315b5c243bcdb72d0bfb4ca3c4c50b38cb744153071912a37420945a" }, "downloads": -1, "filename": "geolib-1.0.5-py3-none-any.whl", "has_sig": false, "md5_digest": "458c7be2c959500a70bc8710cfbfbb70", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4742, "upload_time": "2018-09-20T12:38:46", "url": "https://files.pythonhosted.org/packages/7c/0e/ddf258fb580809f16aead2bc1e61e5f0071b7beebd262657ec693dc54343/geolib-1.0.5-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "bfda5e7a610afdc5a8dc942f8950921b", "sha256": "bfb227a82ecc9c845ff17221c3cfc2bae47c44d0c562599d59499a47574ebcef" }, "downloads": -1, "filename": "geolib-1.0.5.tar.gz", "has_sig": false, "md5_digest": "bfda5e7a610afdc5a8dc942f8950921b", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4234, "upload_time": "2018-09-20T12:38:48", "url": "https://files.pythonhosted.org/packages/6d/cb/4a7aba75f2593a95202f5041875dab32359ed4d78d684c0b04ce37afe963/geolib-1.0.5.tar.gz" } ], "1.0.6": [ { "comment_text": "", "digests": { "md5": "7e8ef1b63ae5149a92f25e000ac6ed88", "sha256": "67e08ce17bccb8ca95a13fa51b5420cf013f317b41e7c469c2993fbd7f23d493" }, "downloads": -1, "filename": "geolib-1.0.6-py3-none-any.whl", "has_sig": false, "md5_digest": "7e8ef1b63ae5149a92f25e000ac6ed88", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4736, "upload_time": "2018-09-20T12:46:30", "url": "https://files.pythonhosted.org/packages/af/51/ab1ea7ac4993058050f26ef0bcc6c8517e632e9e70496d602e646913622b/geolib-1.0.6-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "3b5dc48b4d696cced09600b2ac87bdcf", "sha256": "88b3316160a8d10d365184edb7eb8e7f439b813d18ae5b092d2917b1f8453992" }, "downloads": -1, "filename": "geolib-1.0.6.tar.gz", "has_sig": false, "md5_digest": "3b5dc48b4d696cced09600b2ac87bdcf", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4234, "upload_time": "2018-09-20T12:46:31", "url": "https://files.pythonhosted.org/packages/c6/fb/5791c399562e1e155cdd337b8f4a64eb6fdfae619ebc200973673e134ccd/geolib-1.0.6.tar.gz" } ], "1.0.7": [ { "comment_text": "", "digests": { "md5": "5af0d7ff81d015fe68a59b3fff5b09db", "sha256": "88a6b70dbcae49c51aa417e50d07e871d09e342c6bd060d88a76c921fcb34a75" }, "downloads": -1, "filename": "geolib-1.0.7-py3-none-any.whl", "has_sig": false, "md5_digest": "5af0d7ff81d015fe68a59b3fff5b09db", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 5538, "upload_time": "2019-05-04T22:20:17", "url": "https://files.pythonhosted.org/packages/f2/46/e08d831615af9670819432f84f63e30f65fdd4b9976faa093998e0af43ad/geolib-1.0.7-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "082d8d4aa5ad1ce055ec6750e689e352", "sha256": "5d617fafbf337d333dc65b893b1893a664ca0383e3e4143932009761cf25962f" }, "downloads": -1, "filename": "geolib-1.0.7.tar.gz", "has_sig": false, "md5_digest": "082d8d4aa5ad1ce055ec6750e689e352", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4228, "upload_time": "2019-05-04T22:20:18", "url": "https://files.pythonhosted.org/packages/c6/df/0d7bac8eadd310b9ea92b8bdb0b9b879a8567370859bf42e15a6b435ec31/geolib-1.0.7.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "5af0d7ff81d015fe68a59b3fff5b09db", "sha256": "88a6b70dbcae49c51aa417e50d07e871d09e342c6bd060d88a76c921fcb34a75" }, "downloads": -1, "filename": "geolib-1.0.7-py3-none-any.whl", "has_sig": false, "md5_digest": "5af0d7ff81d015fe68a59b3fff5b09db", "packagetype": "bdist_wheel", "python_version": "py3", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 5538, "upload_time": "2019-05-04T22:20:17", "url": "https://files.pythonhosted.org/packages/f2/46/e08d831615af9670819432f84f63e30f65fdd4b9976faa093998e0af43ad/geolib-1.0.7-py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "082d8d4aa5ad1ce055ec6750e689e352", "sha256": "5d617fafbf337d333dc65b893b1893a664ca0383e3e4143932009761cf25962f" }, "downloads": -1, "filename": "geolib-1.0.7.tar.gz", "has_sig": false, "md5_digest": "082d8d4aa5ad1ce055ec6750e689e352", "packagetype": "sdist", "python_version": "source", "requires_python": ">=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*", "size": 4228, "upload_time": "2019-05-04T22:20:18", "url": "https://files.pythonhosted.org/packages/c6/df/0d7bac8eadd310b9ea92b8bdb0b9b879a8567370859bf42e15a6b435ec31/geolib-1.0.7.tar.gz" } ] }