=========
pygeohash
=========
[![Coverage Status](https://coveralls.io/repos/wdm0006/pygeohash/badge.svg?branch=master&service=github)](https://coveralls.io/github/wdm0006/pygeohash?branch=master) ![travis status](https://travis-ci.org/wdm0006/pygeohash.svg?branch=master)
Pygeohash is a Python module that provides functions for decoding and encoding geohashes to and from latitude and
longitude coordinates, and doing basic calculations and approximations with them.
It is based off of Leonard NorrgÄrd's [geohash](https://github.com/vinsci/geohash) module, but aims to add more
functionality while supporting python 3 as well.
Usage
=====
To use pygeohash:
import pygeohash as pgh
pgh.encode(42.6, -5.6)
# >>> 'ezs42e44yx96'
pgh.encode(42.6, -5.6, precision=5)
# >>> 'ezs42'
pgh.decode('ezs42')
# >>> ('42.6', '-5.6')
pgh.geohash_approximate_distance('bcd3u', 'bc83n')
# >>> 625441
Installation
============
Pygeohash has no requirements outside of the python stdlib, and aims to keep it that way if at all possible. To install:
pip install pygeohash
Liscense
========
A portion of this codebase (geohash.py), is from Leonard Norrgard's module, which carries the following license:
Copyright (C) 2015 [Leonard Norrgard](leonard.norrgard@gmail.com)
Geohash is free software: you can redistribute it and/or modify it
under the terms of the GNU Affero General Public License as published
by the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
Geohash is distributed in the hope that it will be useful, but WITHOUT
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public
License for more details.
You should have received a copy of the GNU Affero General Public
License along with Geohash. If not, see
[gnu.org](http://www.gnu.org/licenses/).
This derivative work likewise carries the same license:
Copyright (C) 2015 [Will McGinnis](will@pedalwrencher.com)
Raw data
{
"_id": null,
"home_page": "https://github.com/wdm0006/pygeohash",
"name": "pygeohash",
"maintainer": null,
"docs_url": null,
"requires_python": null,
"maintainer_email": null,
"keywords": "geohash gis",
"author": "Will McGinnis",
"author_email": "will@pedalwrencher.com",
"download_url": "https://files.pythonhosted.org/packages/2c/33/c912fa4476cedcd3ed9cd25c44c163583b92d319860438e6b632f7f42d0c/pygeohash-1.2.0.tar.gz",
"platform": "UNKNOWN",
"description": "=========\npygeohash\n=========\n\n[![Coverage Status](https://coveralls.io/repos/wdm0006/pygeohash/badge.svg?branch=master&service=github)](https://coveralls.io/github/wdm0006/pygeohash?branch=master) ![travis status](https://travis-ci.org/wdm0006/pygeohash.svg?branch=master) \n\nPygeohash is a Python module that provides functions for decoding and encoding geohashes to and from latitude and \nlongitude coordinates, and doing basic calculations and approximations with them.\n\nIt is based off of Leonard Norrg\u00e5rd's [geohash](https://github.com/vinsci/geohash) module, but aims to add more \nfunctionality while supporting python 3 as well.\n\n\nUsage\n=====\n\nTo use pygeohash:\n\n import pygeohash as pgh\n \n pgh.encode(42.6, -5.6)\n # >>> 'ezs42e44yx96'\n \n pgh.encode(42.6, -5.6, precision=5)\n # >>> 'ezs42'\n \n pgh.decode('ezs42')\n # >>> ('42.6', '-5.6')\n \n pgh.geohash_approximate_distance('bcd3u', 'bc83n')\n # >>> 625441\n\nInstallation\n============\n\nPygeohash has no requirements outside of the python stdlib, and aims to keep it that way if at all possible. To install:\n\n pip install pygeohash\n \nLiscense\n========\n\nA portion of this codebase (geohash.py), is from Leonard Norrgard's module, which carries the following license:\n\nCopyright (C) 2015 [Leonard Norrgard](leonard.norrgard@gmail.com)\n\nGeohash is free software: you can redistribute it and/or modify it\nunder the terms of the GNU Affero General Public License as published\nby the Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nGeohash is distributed in the hope that it will be useful, but WITHOUT\nANY WARRANTY; without even the implied warranty of MERCHANTABILITY or\nFITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public\nLicense for more details.\n\nYou should have received a copy of the GNU Affero General Public\nLicense along with Geohash. If not, see\n[gnu.org](http://www.gnu.org/licenses/).\n\nThis derivative work likewise carries the same license:\n\nCopyright (C) 2015 [Will McGinnis](will@pedalwrencher.com)",
"bugtrack_url": null,
"license": "GPL3",
"summary": "Python module for interacting with geohashes",
"version": "1.2.0",
"project_urls": {
"Download": "https://github.com/wdm0006/pygeohash/tarball/1.2.0",
"Homepage": "https://github.com/wdm0006/pygeohash"
},
"split_keywords": [
"geohash",
"gis"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "2c33c912fa4476cedcd3ed9cd25c44c163583b92d319860438e6b632f7f42d0c",
"md5": "f7da068e612ecdfad4eb78fed3cc1999",
"sha256": "750e51643e743eabd065a84fc8c1912c5843b648143137919e4a9776366d921e"
},
"downloads": -1,
"filename": "pygeohash-1.2.0.tar.gz",
"has_sig": false,
"md5_digest": "f7da068e612ecdfad4eb78fed3cc1999",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 4978,
"upload_time": "2016-04-05T15:59:51",
"upload_time_iso_8601": "2016-04-05T15:59:51.789337Z",
"url": "https://files.pythonhosted.org/packages/2c/33/c912fa4476cedcd3ed9cd25c44c163583b92d319860438e6b632f7f42d0c/pygeohash-1.2.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2016-04-05 15:59:51",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "wdm0006",
"github_project": "pygeohash",
"travis_ci": true,
"coveralls": false,
"github_actions": false,
"requirements": [],
"lcname": "pygeohash"
}