Merged
Conversation
added 8 commits
February 12, 2026 14:32
b8fc5cd to
81dd1b1
Compare
Contributor
There was a problem hiding this comment.
Pull request overview
This PR migrates the image processing library from PIL/Pillow to OpenCV (cv2), eliminating the dependency on PIL and ImageMagick while maintaining the same image generation and resizing functionality.
Changes:
- Replaced PIL/Pillow with OpenCV for all image encoding, decoding, and resizing operations
- Removed ImageMagick dependency from functional tests by using OpenCV's native format conversion
- Updated image generation utilities to use numpy arrays and OpenCV encoding
Reviewed changes
Copilot reviewed 19 out of 20 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| pyproject.toml | Replaced pillow dependency with opencv-python-headless |
| src/resolver_athena_client/client/transformers/core.py | Migrated image resizing logic from PIL to OpenCV with new resampling algorithm enum |
| src/resolver_athena_client/client/athena_options.py | Updated resampling algorithm type from PIL.Image.Resampling to OpenCVResamplingAlgorithm |
| src/resolver_athena_client/image_generation.py | Converted image generation from PIL to OpenCV using numpy arrays |
| tests/utils/image_generation.py | Deleted original image generation utilities (moved to src) |
| tests/functional/conftest.py | Replaced ImageMagick-based format conversion with OpenCV encoding |
| tests/test_classify_single.py | Updated test image creation to use OpenCV instead of PIL |
| tests/client/transformers/test_core.py | Migrated test image creation from PIL to OpenCV |
| tests/client/transformers/test_hash_pipeline.py | Updated test image generation to use OpenCV |
| tests/functional/test_invalid_image.py | Changed expected exception from PIL's UnidentifiedImageError to ValueError |
| Multiple test files | Updated imports to use new image_generation module location |
| docs/api/transformers.rst | Updated documentation to reflect OpenCV resampling algorithm |
| README.md | Removed ImageMagick installation requirement |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
snus-kin
previously approved these changes
Feb 12, 2026
snus-kin
approved these changes
Feb 13, 2026
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.
No description provided.