Skip to content

Rename fly_thumb_georef → fly_georef, add bearing-based auto rotation#27

Merged
NewGraphEnvironment merged 2 commits intomainfrom
issue-25-bearing-rotation
Mar 12, 2026
Merged

Rename fly_thumb_georef → fly_georef, add bearing-based auto rotation#27
NewGraphEnvironment merged 2 commits intomainfrom
issue-25-bearing-rotation

Conversation

@NewGraphEnvironment
Copy link
Copy Markdown
Owner

Summary

  • BREAKING: Rename fly_thumb_georef()fly_georef() — works with any image, not just thumbnails (Rename fly_thumb_georef to fly_georef #24)
  • Add fly_bearing() — compute flight line bearing from consecutive centroids per roll
  • Add rotation param to fly_georef() with "auto" default — derives rotation from bearing via calibrated formula floor((bearing + 91) / 90) * 90 %% 360
  • Per-photo rotation override via rotation column on input sf
  • Add data-raw/test_georef_decades.R for visual QA across decades
  • 103 tests passing, v0.3.0

Auto rotation is correct for ~80% of photos (E-W flight lines). Diagonal flights (~45° off cardinal) are unreliable and need manual override — tracked in #26.

Fixes #24
Fixes #25
Relates to NewGraphEnvironment/sred-2025-2026#17

Test plan

  • 103 unit tests pass
  • Visual QA on 10 reference photos (1968–2019): 8/10 correct with auto, 2 diagonal edge cases documented
  • Decade QA script (data-raw/test_georef_decades.R) produces valid georefs
  • Verify in QGIS after merge

🤖 Generated with Claude Code

NewGraphEnvironment and others added 2 commits March 12, 2026 09:24
- Rename fly_thumb_georef() to fly_georef() — works with any image, not
  just thumbnails (#24)
- Add rotation param (0/90/180/270, default 180) to correct image
  orientation. Per-photo rotation via column on input sf (#25)
- Add fly_bearing() to compute flight line bearing from consecutive
  centroids per roll — diagnostic tool for determining rotation
- 102 tests passing

Fixes #24
Fixes #25

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
rotation="auto" (new default) computes flight bearing per-photo and
derives GCP rotation via floor((bearing + 91) / 90) * 90 %% 360.
Calibrated on 10 BC aerial photos (1968-2019), 8/10 correct. Diagonal
flights (~45° off cardinal) are unreliable — override with rotation
column.

Add data-raw/test_georef_decades.R for visual QA across decades.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@NewGraphEnvironment NewGraphEnvironment merged commit f943cc4 into main Mar 12, 2026
1 check passed
@NewGraphEnvironment NewGraphEnvironment deleted the issue-25-bearing-rotation branch March 12, 2026 17:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add bearing param to georef for flight line orientation Rename fly_thumb_georef to fly_georef

1 participant