Repository navigation
fix(index): apply EXIF orientation before rendering local images - #173
Open
OrdoAbChao7 wants to merge 1 commit into
Open
OrdoAbChao7 wants to merge 1 commit into
OrdoAbChao7 wants to merge 1 commit into
Conversation
|
@OrdoAbChao7 is attempting to deploy a commit to the andylizf's projects Team on Vercel. A member of the Team first needs to authorize it. |
This branch has not been deployed
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.
Summary
Fixes #172. Applies EXIF display orientation before local-image alpha compositing, width limiting and JPEG tile generation. This is the photo-orientation follow-up left out of #119.
Previously, an 80x40 JPEG tagged with orientation 6 was written as an 80x40 tile without its orientation tag, rather than a correctly rotated 40x80 tile. Mirrored orientations were likewise lost. The 4000px width cap also used the wrong axes.
The production change is four added lines and one removed line in
pipelines.py: use Pillow'sImageOps.exif_transpose()while the source is open, then continue through the existing rendering path. No dependencies change. Existing cached tiles retain the normal reuse behavior; use the existing--forcerebuild to regenerate previously indexed photos.Regression tests
The new tests invoke the real
build()path and local source discovery, mocking only downstream chunk/embed/index subprocesses. No model, browser, API or download is needed.Evidence against upstream
c4a0f53052306e009a024a2e344ede8aa5eda407:Validation
On Windows / Python 3.13, with local source packages on
PYTHONPATH:Validation is scoped to rendering, chunking, local-source handling and incremental reruns; the full model/search pipeline was not executed.