Fix seam finder in stitching_detailed.py#19987
Merged
opencv-pushbot merged 1 commit intoopencv:masterfrom May 21, 2021
Merged
Conversation
6 tasks
Contributor
There was a problem hiding this comment.
With this changes I can solve this question
Maybe an even better change would be that detail_GraphCutSeamFinder
cv.detail_GraphCutSeamFinder.find( src, corners, masks ) -> None
returns "masks" instead of "None" as e.g. detail_VoronoiSeamFinder:
cv.detail_VoronoiSeamFinder.find( src, corners, masks ) -> masks
then the lines
SEAM_FIND_CHOICES['gc_color'] = cv.detail_GraphCutSeamFinder('COST_COLOR')
SEAM_FIND_CHOICES['gc_colorgrad'] = cv.detail_GraphCutSeamFinder('COST_COLOR_GRAD')
would not have to be deleted.
However I don't understand the Python API to OpenCV's C++ functionality well enough to implement it.
It's somewhere in seam_finders.hpp I guess.
Member
|
/cc @LaurentBerger |
Author
|
Do i need to change something because of the failed check? |
Merged
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.
Seam finder in stitching_detailed.py does not update the masks and output panorama looks blurry because of that. The blurryness problem was mentioned in issue #14413 and seam finder update problem was mention in issue #15520.
To fix the updating problem, DP and Voronoi seam finder result needs to be assigned to a variable. In addition, graph cut seam finder should be removed from the script as it returns None.
Pull 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.