Adding compression to JPEG image types#253
Open
ramanakumars wants to merge 7 commits intozooniverse:masterfrom
Open
Adding compression to JPEG image types#253ramanakumars wants to merge 7 commits intozooniverse:masterfrom
ramanakumars wants to merge 7 commits intozooniverse:masterfrom
Conversation
lcjohnso
reviewed
Jul 28, 2023
lcjohnso
reviewed
Jul 28, 2023
adammcmaster
reviewed
Aug 2, 2023
adammcmaster
reviewed
Aug 2, 2023
adammcmaster
reviewed
Aug 2, 2023
| packages=find_packages(), | ||
| include_package_data=True, | ||
| install_requires=[ | ||
| 'Pillow>=5.4.0,<=7.0.0', |
Contributor
There was a problem hiding this comment.
Just noting that we should probably bump the version to 1.2 (rather than staying at 1.1.x) for the next release since Pillow is a relatively big dependency to add.
Collaborator
Author
There was a problem hiding this comment.
Sounds good! If this is approved, I can commit the update to setup.py to bump the version number. Is there anywhere else that this needs to be changed?
Member
There was a problem hiding this comment.
That'll be handled in a separate version release PR. If this feature needs the new version, update it here and I'll handle the new version release when this merges.
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.
Adding a
--compressoption to the CLI forsubject-set upload-subjectsto automatically compress JPEG images during the upload. Currently this is the only format that works consistently; PNG compression requires image size scaling rather than quality based compression.The compression code starts at 80% quality and successively reduces to 50% before throwing an error if the file size is still too large. For a ~2-3MB it seems like 2 iterations is enough for getting below the current 1MB limit so this should not take too long.