trails/openspec/changes
Ullrich Schäfer 990bbaa99e
feat(gpx): elevation cleaning primitives (despike + hysteresis totals)
Task group 1 of elevation-profile-hardening. New pure module
elevation-clean.ts (not yet wired — group 2 does that):

- despike(points): interpolates out isolated peak/pit spikes (opposite-sign
  slope outliers both exceeding MAX_SLOPE_PERCENT=100); steep monotonic
  terrain (same-sign) is never touched; per-segment, no cross-gap interp.
- filteredTotals(points): hysteresis ascent/descent (NOISE_THRESHOLD_M=5)
  that suppresses sub-threshold jitter, returning {gain,loss,gainRaw,lossRaw}.
- cumulativeFilteredTotals(points): running filtered arrays for per-day
  splits (day total = cumulative[end] − cumulative[start]).

DESIGN NOTE for review: the spec's task 1.2 says the zero-filtered
fallback should "report raw", but the raw sum-of-deltas re-inflates the
very jitter we remove (a ±2 m wobble sums to several metres) — directly
contradicting task 1.4's "±2 m jitter → 0 totals". Resolved toward the
stated goal: fall back to NET change (end−start), so flat wobble reads ~0
while a genuine small net climb still surfaces. gainRaw/lossRaw still
expose the raw sums.

Verified: gpx typecheck+lint clean, 108/108; full pnpm test 11/11.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-07-14 00:46:13 +02:00
..
account-export docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
activity-duplicate-review docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
activity-locations docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
activity-photos Fix all OpenSpec validation failures (36/36 passing) 2026-04-06 22:17:52 +02:00
activity-privacy-controls docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
archive chore(openspec): archive gpx-parser-robustness 2026-07-14 00:36:45 +02:00
changelog Add 8 proposed changes and old trails analysis 2026-03-25 03:57:20 +01:00
credits-page docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
elevation-profile-hardening feat(gpx): elevation cleaning primitives (despike + hysteresis totals) 2026-07-14 00:46:13 +02:00
fit-parsing-hardening docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
garmin-import feat(journal): Garmin activity import — provider, webhook pipeline, backfill (§1–5) 2026-06-07 17:47:22 +02:00
hiking-foot-profile docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
hiking-time-estimate docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
link-share-tokens docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
mobile-app Implement mobile route editor with MapLibre and BRouter routing 2026-04-15 01:06:10 +02:00
route-discovery docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
route-features Add 8 proposed changes and old trails analysis 2026-03-25 03:57:20 +01:00
route-federation docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
route-sharing docs: fix stale route-sharing → social-federation dependency 2026-06-06 13:16:06 +02:00
self-hosting-guide docs+openspec: prior-art research (Organic Maps, Endurain, wanderer) and 15 proposals 2026-07-06 07:23:00 +02:00
visual-redesign Fix all OpenSpec validation failures (36/36 passing) 2026-04-06 22:17:52 +02:00
wahoo-production-cutover Add openspec changes for Wahoo production cutover and route updates 2026-05-01 11:37:42 +02:00