Poland: BDOT10k rzeźba terenu — contours (OT_RTLW_L poziomica) and peaks (OT_RTPW_P) #104
Labels
No labels
blocked
claude-wip
map-report
map:is
map:se
needs-review
No milestone
No project
No assignees
2 participants
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
art/ismap#104
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Scope: Poland's
contoursandpeaksfrom the BDOT10k rzeźba terenu group — one fetch widening, two layers.The source (2021 schema, Dz.U. 2021 poz. 1412 załącznik 2 — verified against the regulation, not the fetch list):
wysokosc— contour lines are a first-class class of the schema. Whether counties actually populatepoziomicaneeds an R6 check on first fetch (the class is not among the 17 fetched); the fallback is GUGiK's own national DEM (NMT grid ≤ 1 m, whole country, per-sheet download) that the "Warstwice" WMS draws from.wysokosc— the analogue of Iceland'shaedarpunktar: elevation markers, unnamed (names would come from PRNG).First steps:
OT_RTLW_Lrodzaj=poziomica rows before committing to the class as the source; record class GB/rows.peaksfromOT_RTPW_Pas elevation markers (filter_only, elevation thinning).From #84 — catalogue line in docs/country-poland.md.
#104 Poland contours + peaks — BLOCKED
Not implemented: after exhausting the national-data options, the only source that
satisfies "national, not a global DEM" is GUGiK's NMT raster, and it cannot be
delivered as a nationwide contours/peaks partition through the importer's mechanism
or within the disk/time budget. This is the sanctioned blocked outcome the issue's
fallback names; the recommendation below is the next attempt.
The R6 check (already done by the requester — accepted)
The 21 fetched BDOT10k county classes carry no contour/peak class.
OT_RTLW_L(poziomica) and
OT_RTPW_P(height points) are not among them. Resolved: the sourceis GUGiK's national DEM (the NMT grid), not the county packages.
Why the national DEM path is not feasible as specified
Verified against the live GUGiK services on 2026-08-20:
No national vector contours product exists. The full GUGiK WFS download
catalogue (
geoportal.gov.pl/pl/usluga/uslugi-pobierania-wfs/) lists no contourfeature type. The INSPIRE "Ukształtowanie terenu" WFS (
wss/service/wfsEL/guest)exposes only
el-cov:ElevationGridCoverage— a raster, no contour lines and nospot-height points. GUGiK's "Warstwice" contour layer is a WMS rendering only;
the underlying data is the NMT grid. So there is no vector contour product to
prefer; the DEM is the only national source.
The NMT grid is a per-sheet, dynamic catalogue and is TB-scale at fine
resolution. The download is a WFS "Skorowidze" service
(
NumerycznyModelTerenuEVRF2007/WFS/Skorowidze, plus a KRON86 twin). Each sheetis an ArcInfo ASCII GRID raster with a
url_do_pobranialink and a resolutionladder — 1 m @ 1:5000, 0.5 m @ 1:1000 (cities), 5 m/10 m @ 1:10000. Measured: a
5 m sheet is ~2 MB; a 1 m sheet ~50 MB. Poland is ~312 000 km², so the fine-grid
whole-country set is on the order of 100 000 sheets / ~1–5 TB — several times
the ~148 GB free on
/stuff(and/has ~196 GB). It also cannot be fetchedthrough the importer's
downloads:mechanism, which is a static URL list(
docs/importer-cli.md"Fetching"); a sheet-catalog WFS provider does not exist.DEM→contour tracing is not in the pure-Go toolchain. The importer has native
loaders for GeoPackage/GML/GTFS/shapefile and no raster code at all
(
importer/has no raster/contour/GDAL). Deriving contours from an ASCII GRIDwould need a grid parser, a marching-squares tracer with line assembly, a
PL-1992→3857 reprojection, and a local-maxima pass for peaks — a substantial new
subsystem (the size of an
arcgis.go/clms.goprovider plus a generalizer), not aconfig change, and too risky to land and verify in one unattended run.
Even the mountainous subset where contours actually matter (Tatras, Karkonosze,
Sudetes, Bieszczady, Świętokrzyskie, Roztocze) is thousands of sheets / several GB,
and still needs the full new contour engine.
Recommendation — the next attempt
Scope the DEM pilot to the mountainous arc, on the 5 m grid, with the machinery
built as a real importer feature (not a one-off):
arcgis.go/clms.go: reads the NMT SkorowidzeWFS, selects the sheets intersecting the relief area (a bbox list), follows each
sheet's
url_do_pobrania, and streams the ASCII GRID intodata/throughsharedtree.go(the chmod-enforced path).(interval_class 1 = 100 m index, source-cadence cascade like Sweden), and detect
spot-height local maxima for
peaks. Both feed the existing shared contracts asmap_contours_<z>_pl/map_peaks_<z>_plpartitions.simplify_line/filter_onlythen thin exactly as Sweden/Iceland do.This is a multi-day piece of work and should be its own issue (the #104 scope is
"one fetch widening, two layers" — the DEM machinery is a mechanism, not a fetch
widening).
Cheap fallback to try first (could close the chapter in ~30 lines if it hits):
re-probe BDOT10k county packages with
OT_RTLW_Lactually added to theBDOT10K_CLASSESfetch list for a Tatra and a Karkonosze county. The R6 "thecounties do not ship these classes" is a statement about the fetched set — those
two classes were never requested, so a delivery that contains them would never have
shown them. If any county ships
poziomicarows, the class mapping is a trivialconfig and both layers land with no DEM work at all.
Correction: the BLOCKED conclusion is wrong — the counties do ship both classes
The reasoning in the previous comment is circular, and its own last paragraph says
so without acting on it.
fetch-bdot10kbuilds itsunzippatterns fromBDOT10K_CLASSESand then deletes the county zip.OT_RTLW_LandOT_RTPW_Phave never been in that list. So "the 21 fetched classes carry no contour class" is
a statement about what we asked for, not about what GUGiK publishes — and a contour
class present in every delivery would look exactly like this.
This is the fourth time on Poland:
OT_SKPP_L(ferries),OT_OIPR_P(waterfalls/springs) and
OT_OIKM_P(metro entrances) were each declared absentfrom the national database and each was there all along.
docs/country-poland.md:154already says it in as many words — "a 'no source' claim about the fetch list is not
a claim about the database" — and both
docs/country-poland.md:160anddocs/workstream-a.md:258say the R6 check was still owed on first fetch. It hadnever been run.
Measured
Verified directly, 2026-08-20: 56 county zips downloaded and catalogued (8 chosen by
terrain, 48 a stratified random sample, 3 per voivodeship). 41 of 56 (73%) ship
both RT classes. Filenames are
PL.PZGiK.<provider>.BDOT10k.<TERYT>__OT_RTLW_L.gpkg/__OT_RTPW_P.gpkg; columnsare UPPERCASE (
RODZAJ,WYSOKOSC).Five counties read in full:
OT_RTLW_LOT_RTPW_PIndependently re-checked on 0206 before writing this: 47 102 / 44 859 poziomica /
2 243 skarpa, 1 702 height points, 0 NULL
WYSOKOSC, contours to 1602.5 m andpoints to 1603.3 m — Śnieżka is 1603 m, so the elevations are right.
It is a real product, not a scatter: coverage gridded to 1 km cells gives
cell-count/area ratios of 1.11–1.22 (wall-to-wall plus edge cells), interval is
adaptive 2.5 m in mountains / 1.25 m in lowlands, vertex spacing 5–13 m.
The premise that made this look hard is true and irrelevant
ZRODLODANYCHGEOMETRYCZNYCH = 'NMT'on 100% of rows. The contours are derivedfrom the national DEM — by GUGiK, who ship the vector result in the county GPKGs
the pipeline already downloads. No raster subsystem, no marching squares, no TB of
ASCII GRID. The previous comment's recommendation would have rebuilt work that is
already published as vectors.
Cost
A config change plus one re-fetch:
RTLW_L RTPW_PtoBDOT10K_CLASSES(Makefile:198);BDOT10K_MARKER— the expensive part: zips are deleted afterextraction, so widening forces the full ~25 GB re-pull of all 380 counties, the
cost the Makefile comment already documents for the
-bubdwidening;staging:glob-merge entries inconf/pl/staging.yaml, then wire to theexisting shared contracts —
conf/shared/contracts/18-contours.yamland19-peaks.yamlalready name #104 and Poland'spoziomica/OT_RTPW_P.Disk: mean
OT_RTLW_Lis 63 MB uncompressed over the 36 counties measured(
OT_RTPW_P0.77 MB) → roughly 18 GB nationally at the observed presence rate.An extrapolation, not a measurement — but two orders of magnitude below the TB-scale
raster path. Row-count extrapolation (~14M lines) is rougher still; the deep-read
sample skews mountainous, so treat it as an upper-ish bound.
The one real caveat — uneven county coverage
15 of 56 sampled counties ship no RT files: tatrzański, pruszkowski, pleszewski,
trzebnicki, wrocławski, limanowski, oświęcimski, proszowicki, głubczycki, niżański,
stalowowolski, tarnobrzeski, chojnicki, ostrzeszowski, rawicki. The gap tracks the
county authority, not the terrain, and it lands badly: małopolskie was 0/4 in
sample, including powiat tatrzański — the highest terrain in Poland. Podkarpackie
1/4, wielkopolskie 1/4; eight voivodeships were 100% present.
No file was present-but-empty (smallest
OT_RTLW_Lseen is 3.9 MB, vs ~100 KB foran empty GPKG) — though the small ones were not opened to confirm. A full 380-county
census was not possible: the opendata server ignores HTTP Range, so only full
downloads work.
The Tatras hole is the awkward fact and might justify a targeted NMT fallback for
that county later. It does not justify building a raster pipeline for the whole
country now.
Peaks are only half-solved
OT_RTPW_Pcarries elevations but no name column, asdocs/country-poland.md:166already states. Every named class in the karkonoskidelivery was scanned for summit features:
OT_OIPR_P's ladder is trees, boulders,isolated rocks, springs, cave entrances — no summit class, no elevation. So BDOT10k
gives peak elevations, not peak names; names would need PRNG, a separate register.
Also two gotchas for whoever implements:
WYSOKOSC = -999is a no-data sentinel onskarparows, and onOT_RTPW_Pthe value is absolute elevation only forpunkt wysokościowy w terenie— forkopiec lub hałdaanddółit is mound height/ pit depth (1.0–2.5 m), so a naive min/max mixes units. One outlier seen: a
bieszczadzki point at 7624.0 m.
Related: #203 — Sweden's peaks turned out to be a geodetic control network rather
than summits. "The national height-point layer" is not automatically a peaks layer,
and Poland's
OT_RTPW_Pdeserves the same look before it is trusted (rodzajpunkt wysokościowy w terenieis the terrain-sampling kind, which is the rightshape — but check the distribution against known summits before landing it).