opencv
opencv copied to clipboard
More tests for normals
This PR contains
- Tests for normals changes:
- Random plane generation fixed (maxDepth issue, rendering issue, 32F to 16U transformation issue)
- Different scale issue fixed, checked for all normal computers and all output data types
- Rendered normals test added: calculated normals are compared to pre-rendered ones
- RNG fixed to follow TS's RNG
- Rewritten to parametric GTest
- Several fixes to normal computers:
- no
setMethod: usecreatestatic method instead - depth difference threshold for LINEMOD algorithm has been put into interface
- no
- Fix for
depthTo3dfunction for dense case with mask, test added CrossProduct- a new normal computer implementing the most naive way to calculate normals on a depth image, performing no filtering or any "smart" operations
Connected test data PR: https://github.com/opencv/opencv_extra/pull/991
TODO (next PRs):
- Implement 16U input support for all normal computers
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
- [x] 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
Also please pay attention that test data patch is very large. It makes sense to reduce it.
Looks like the footprint size is calculated incorrectly: the diff between 5.x and the branch in opencv_extra includes files that are already merged to 5.x.
It should be 1.7 MiB (I have no ideas on how to reduce it) while it shows something about 12 MiB.
@alalek do you know why is that?