Skip to main content

A Python wrapper for the Photon geocoder

Project description

Photon Geocoder

Overview

Photon Geocoder is a Python library designed to provide efficient and easy-to-use geocoding capabilities using OpenStreetMap data. It offers a robust solution for translating addresses into geographic coordinates and vice versa.

Features

  • Leverage OpenStreetMap data for accurate geocoding.
  • Support for various geocoding queries, including address, city, and postal code lookups.
  • Ability to filter results by specific OpenStreetMap tags.
  • Asynchronous API for efficient network operations.

Installation

To install Photon Geocoder, run the following command:

pip install photon-geocoder

Usage

Here's a quick example of how to use Photon Geocoder:

from photon_geocoder import PhotonGeocoder

# Create a geocoder instance
geocoder = PhotonGeocoder()

# Geocode an address
addresses = await geocoder.query("Brandenburg Gate, Berlin")
print(addresses)

API Reference

The main class in Photon Geocoder is PhotonGeocoder. It provides the following methods:

  • query(address, layers=None, osm_tags=None, limit=10): Performs a geocoding query.

Contributing

Contributions to Photon Geocoder are welcome! Please read our contribution guidelines for more information on how to contribute.

License

Photon Geocoder is licensed under the MIT License.

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

photon_geocoder-1.0.0.tar.gz (10.9 kB view hashes)

Uploaded Source

Built Distribution

photon_geocoder-1.0.0-py3-none-any.whl (11.8 kB view hashes)

Uploaded Python 3

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