Repository navigation
feat(photos): star trail per night session in photos sort - #302
Merged
Merged
Conversation
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.
What
photos sortnow builds one star trail per night session, after the stacks and before the time-lapse (follow-up named in #300):trails/<first-group-id>.tifis the 16-bit master andtrails/<id>.jpgis the browser JPEG, vianight_products.render_master_preview. Each trail appendsOutput("trails", id, "trails/<id>.jpg"), so the feat(photos): one card per sequence on the sort index page #299 card shows it between the stacks and the video.astro_trails.render_trail(calibrated, unaligned, streaming per-pixel maximum), behind thepreflight_trailRAM/disk gate. A newGroupOps.star_trailsseam wraps it.classify_nightruns at most once per session, and both the trail and the time-lapse use its result. Lens-cap darks are never used as lights. Darks calibrate only whenbuild_validated_master_darkaccepts them; that check is now the shared_validated_darkshelper. A maximum keeps an unsubtracted hot pixel forever, so an unmatched set is dropped.TRAILS_MIN_FRAMES = 24usable lights, about 13 minutes at the measured 32 s interval. A shorter session storestrails-skip:v1, so--resumedoesn't decode it again.group_key("trails", members)+stack:v1. A failure becomes askipped.csvrow, its partial files are removed, and the run goes on.--no-stacksskips trails.Real-data smoke (default seam, no stubs; 2026-11-09 run, night-1, output to a scratch dir)
night-1: 19 RAWs →sg._star_trails→night-1.tif(107 MB) +night-1.jpg(3.1 MB) in 124 s at nice 19, beside a runningphotos sort --reprocess.astro_trailsdocstring expects for this camera's 15 s exposures on a 32 s interval. It is not black and shows no hot-pixel field.Test plan
pytest -n 0 -p no:cacheprovider --no-cov -q tests/test_photo_sort_groups.py→ 26 failed withTypeError: GroupOps.__init__() got an unexpected keyword argument 'star_trails'(tests/test_photo_sort_groups.py:118). The shared fake passes the new seam, and the 4 new tests failed too (nosg._star_trails, notrails/).tests/test_photo_sort_groups.py→ 34 passed.test_photo_sort*.py,test_astro_trails.py,test_astro_timelapse.py,test_docs_numbering.py,test_changelog.py→ 129 passed.ruff checkandruff format --checkclean.ci/secret_scan.pyclean._night_timelapseinto_validated_darks, which the trail reuses. Its existing unmatched-darks test still passes.Regression verified; test-first order not independently enforced.