openmaptiles/openmaptiles-tools

Enhanced height parser.

Open

#463 opened on Dec 1, 2025

View on GitHub
 (0 comments) (0 reactions) (0 assignees)Python (147 forks)github user discovery
help wanted

Repository metrics

Stars
 (463 stars)
PR merge metrics
 (PR metrics pending)

Description

Based on taginfo, there are at least 137k heights with the value 2 m, 105k with value 3 m, 71k 6 m... The current function CleanNumeric handles simple strings and converts them to a number (SELECT cleannumeric('2.0'::text); -> 2::numeric).

The function should not replace CleanNumeric function, but be another function to deal with these non-numeric values (with m, m, ft, ", ' ",...)

The new function will be used for parsing heights for buildings, for mountain_peak, and for aerodrome_label layers.

One attempt was already discussed in #362.

Contributor guide