pyrDown: offset HAL added, IPP removed#25970
Merged
asmorkalov merged 6 commits intoopencv:4.xfrom Aug 6, 2024
Merged
Conversation
asmorkalov
reviewed
Jul 31, 2024
asmorkalov
approved these changes
Aug 6, 2024
vpisarev
approved these changes
Aug 6, 2024
vpisarev
reviewed
Aug 6, 2024
| @param margin_bottom Bottom margins for source image | ||
| @param border_type Border type | ||
| */ | ||
| inline int hal_ni_pyrdown_offset(const uchar* src_data, size_t src_step, int src_width, int src_height, |
Contributor
There was a problem hiding this comment.
What is our plan to enable such feature in all filters. Starting with the name - shall we use _roi in the name? And pass the whole image size and roi inside?
How to make it python-compatible? (Numpy does not have a notion of roi)
Contributor
There was a problem hiding this comment.
- It's already done in current HAL API for filters.
- Python and Numpy is not related here. Unfortunately we do not have solution for it.
Contributor
Author
There was a problem hiding this comment.
- Numpy supports array slicing (though I am not sure if the slices can be passed outside of the Python)
- Taking the ROI from source image then applying filter should produce the same result as doing it vice versa (i.e. applying filter then taking the ROI of the result).
We can recommend Python users to stick to the second option at cost of performance.
fengyuentau
pushed a commit
to fengyuentau/opencv
that referenced
this pull request
Aug 15, 2024
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
Merged
savuor
added a commit
to savuor/opencv
that referenced
this pull request
Nov 1, 2024
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
6 tasks
savuor
added a commit
to savuor/opencv
that referenced
this pull request
Nov 5, 2024
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
savuor
added a commit
to savuor/opencv
that referenced
this pull request
Nov 8, 2024
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
savuor
added a commit
to savuor/opencv
that referenced
this pull request
Nov 21, 2024
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
thewoz
pushed a commit
to CobbsLab/OPENCV
that referenced
this pull request
Feb 13, 2025
pyrDown: offset HAL added, IPP removed opencv#25970 Resolves opencv#25976 ### Changes * HAL added for offset support so that border pixels can be fetched from outside of the image ROI (see `BORDER_ISOLATED` parameter) * IPP removed since there is `pyrUp` instead of `pyrDown` and there's no easy way to fix this other than rewriting it from scratch * replaced old C call by modern `cv::pyrDown` ### Pull Request Readiness Checklist See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request - [x] I agree to contribute to the project under Apache 2 License. - [x] To the best of my knowledge, the proposed patch is not based on a code under GPL or another license that is incompatible with OpenCV - [x] The PR is proposed to the proper branch - [ ] There is a reference to the original bug report and related work - [x] There is accuracy test, performance test and test data in opencv_extra repository, if applicable Patch to opencv_extra has the same branch name. - [x] The feature is well documented and sample code can be built with the project CMake
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.
Resolves #25976
Changes
BORDER_ISOLATEDparameter)pyrUpinstead ofpyrDownand there's no easy way to fix this other than rewriting it from scratchcv::pyrDownPull Request Readiness Checklist
See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request
Patch to opencv_extra has the same branch name.