Geonames Data Parser (CLI for Shapefile/KML)

0.1.3 · abandoned · verified Sat Apr 11

This `geonames` library (version 0.1.3) is an older Python package primarily designed as a Command Line Interface (CLI) tool. It parses downloaded GeoNames.org geographical data dump files (typically `.txt` files) and converts them into clean OGR Shapefile or KML formats. The library's last update was in 2015, indicating it is no longer actively maintained.

Warnings

Install

Imports

Quickstart

The primary use case for this `geonames` library is via its command-line interface to convert GeoNames dump files. Ensure you have downloaded a `.txt` dump file (e.g., `PH.txt` from `PH.zip`) before running the command. The `fiona` library and its GDAL/OGR dependencies must be installed for Shapefile/KML output to work.

# 1. Download a GeoNames dump file (e.g., for Philippines)
#    wget http://download.geonames.org/export/dump/PH.zip
#    unzip PH.zip

# 2. Convert the downloaded .txt file to a Shapefile using the CLI tool
geonames PH.txt

# This will generate a Shapefile (e.g., PH.shp, PH.shx, PH.dbf, etc.)
# in the current directory.

view raw JSON →