From 060e2ee1c1ca73a782a98192a94ff300e6aa05a1 Mon Sep 17 00:00:00 2001 From: Erica Fischer Date: Tue, 17 Sep 2024 15:16:31 -0700 Subject: [PATCH] Fix a typo that broke accumulation --- Makefile | 6 +++--- clip.cpp | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index db6c6d8a..ff841afc 100644 --- a/Makefile +++ b/Makefile @@ -553,11 +553,11 @@ accumulate-test: test `./tippecanoe-decode -c tests/pbf/accum-0-0-0.pbf 0 0 0 | grep -v 'POP1950' | wc -l` == 2 # (which is the same as you get if you don't use -retain-points-multiplier when creating the tileset) # - # the clustered and megatile-filtered POP1950s add up to 183298 - test `./tippecanoe-decode -c tests/pbf/accum-0-0-0.pbf 0 0 0 | grep 'tippecanoe:sum:POP1950' | sed 's/.*"tippecanoe:sum:POP1950": //' | awk '{sum += $$1} END {print sum}'` == 183298 + # the clustered and megatile-filtered POP1950s add up to 146370 + test `./tippecanoe-decode -c tests/pbf/accum-0-0-0.pbf 0 0 0 | grep 'tippecanoe:sum:POP1950' | sed 's/.*"tippecanoe:sum:POP1950": //' | awk '{sum += $$1} END {print sum}'` == 146370 # the non-clustered but megatile-filtered POP1950s add up to 15220 test `./tippecanoe-decode -c tests/pbf/accum-0-0-0.pbf 0 0 0 | grep -v 'tippecanoe:sum:POP1950' | grep POP1950 | sed 's/.*"POP1950": //' | awk '{sum += $$1} END {print sum}'` == 15220 - # which does not add up to 161590 so something is wrong + # which add up to 161590 so we have the right global total join-filter-test: tippecanoe tippecanoe-decode tile-join # Comes out different from the direct tippecanoe run because null attributes are lost diff --git a/clip.cpp b/clip.cpp index 2b1a18dc..ac35837c 100644 --- a/clip.cpp +++ b/clip.cpp @@ -1228,7 +1228,7 @@ static void feature_out(std::vector const &features, mvt_layer &ou // same attribute, we want to use that one instead of this one. for (auto const &op : numeric_operations) { - std::string compound_key = "tipppecanoe:" + op.first + ":" + key; + std::string compound_key = "tippecanoe:" + op.first + ":" + key; auto compound_found = keys.find(compound_key); if (compound_found != keys.end()) { // found, so skip this one