opencv_contrib
opencv_contrib copied to clipboard
Accept ksize equals -1 for ridge detection filter
System information (version)
- OpenCV => :grey_question:
- Operating System / Platform => :grey_question:
- Compiler => :grey_question:
Detailed description
I am working with the ridge detector, which is using eigenvalues of Hessian matrix. The Hessian matrix is calculated by taking derivate two times using Sobel operator, which currently accepts only kernel size in [1,3,5,7] (https://github.com/opencv/opencv_contrib/blob/master/modules/ximgproc/src/ridgedetectionfilter.cpp#L34) but I think there is no problem using Scharr operator to calculate this matrix. For that reason, I think this function could accept kernel size equals -1 so that the Scharr kernel will eventually be used.
Steps to reproduce
Issue submission checklist
- [ ] I report the issue, it's not a question
- [ ] I checked the problem with documentation, FAQ, open issues, forum.opencv.org, Stack Overflow, etc and have not found any solution
- [ ] I updated to the latest OpenCV version and the issue is still there
- [ ] There is reproducer code and related data files: videos, images, onnx, etc