SI: editions back to 2019, and the four ways the campaigns differ - #231
Open
ivorbosloper wants to merge 1 commit into
Open
SI: editions back to 2019, and the four ways the campaigns differ#231ivorbosloper wants to merge 1 commit into
ivorbosloper wants to merge 1 commit into
Conversation
rkg.gov.si keeps KMRS_<year>.rar from 2019 onwards — 2018 and 2025 answer 404 — where the converter knew only 2021 and later. EuroCrops lists 2019-2021 for Slovenia from this same source, so this completes the national series. Reading the older campaigns took four fixes, each of which cost a conversion: - 2019 nests its shapefile in a folder of the same name; the others keep it at the archive root, so the target is globbed recursively now, as cz does. - 2021 ships no .prj at all and its geometries arrive naive. Every other campaign declares EPSG:3794, and 2021 covers the same ground in the same numbers (easting 377373..622579 against 2020's 377373..622579), so the grid is set where the archive leaves it out. - 2019 carries three attributes where the rest carry seven: it names the field POLJINA_ID rather than ID, and publishes neither an area nor a crop name. Both spellings are mapped, and the area is computed from the geometry. (2020 spells the Latin crop name CROP_LATIN, 2021 onwards CROP_LAT_E — same treatment.) - 2020 stores its crop codes without the leading zeros the KMRS list uses, so 120,164 of its 819,620 rows — 14.66% — matched no crop and would have been published without an HCAT code. None of those unpadded codes appears in any other campaign. Built and verified over all six editions: 820,151 fields in 2019 to 809,044 in 2024, unique ids throughout, no row without an HCAT code, and median field sizes moving smoothly from 2,789 m² to 2,748 m² — which is the check that the areas computed for 2019 are right. The local crop-mapping fixture makes the test hermetic. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01DVx9uQV2QPM8ecPAY3ZjXG
This was referenced Sep 11, 2026
This was referenced Sep 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
One of ~30 small PRs splitting the
publish-portolanbranch. This one is Slovenia: the converter, its test fixture, and a CHANGELOG line.rkg.gov.si keeps
KMRS_<year>.rarfrom 2019 onwards (2018 and 2025 are 404), where the converter knew 2021 and later. EuroCrops lists 2019-2021 for Slovenia from this same source, so this completes the national series.Each of the four fixes below cost a conversion before it was found:
KMRS_2019/folder; the others keep it at the archive root → glob recursively, asczdoes.prjat all, so geometries arrive naive and the conversion stops at the first transform. Every other campaign declares EPSG:3794 and 2021 covers the same ground in the same numbers (easting 377373..622579 against 2020's 377373..622579), so the grid is set where the archive omits itPOLJINA_ID, notID, and there is neither an area nor a crop name → both spellings mapped, area computed from the geometry(2020 also spells the Latin crop name
CROP_LATINwhere 2021+ useCROP_LAT_E; both are mapped.)Verified over all six editions
The median field sizes moving smoothly across the series is the check that the areas computed for 2019, where the source publishes none, are right. (The id counts that differ by a handful are multipart parts, the same rate as elsewhere in the catalog.)
All six editions are built and published in the harmonized field data catalog.
Original commits on
publish-portolan: fd9ca81, d5733d2, f8ccdb7, 643b085. The local crop-mapping fixture makes the test hermetic.🤖 Generated with Claude Code
https://claude.ai/code/session_01DVx9uQV2QPM8ecPAY3ZjXG