Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(5.x) Merge 4.x #23189

Merged
merged 37 commits into from
Jan 30, 2023
Merged

(5.x) Merge 4.x #23189

merged 37 commits into from
Jan 30, 2023

Conversation

alalek
Copy link
Member

@alalek alalek commented Jan 28, 2023

#16189 from mshabunin:enable-two-channels
#23025 from savuor:backport3_stddev_calib_fix
#23047 from fengyuentau:layer_norm
#23073 from savuor:fix_graphcut_used_edges_dense
#23076 from inayd:22012-bugfixFillPoly
#23108 from crackwitz:issue-23107
#23111 from Yeatse:fix-apple-silicon-build
#23120 from alalek:fixup_22246_2
#23128 from Isydmr:update-fastNlMeansDenoising-documentation
#23145 from savuor:backport34_fix_inf
#23148 from alalek:perf_drop_calibration
#23154 from tomoaki0705:handleNonBitExact
#23162 from zihaomu:issue_23151
#23165 from labeeb-7z:optimizeDistanceTransform
#23172 from lilohuang:master
#23173 from tomoaki0705:fix_warning_master
#23179 from savuor:port34_stddev_calib_fisheye
#23185 from y-guyon:parallel_tsan_data_race

Previous "Merge 4.x": #23149

build_image:Docs=docs-js:18.04
build_image:Custom=javascript
buildworker:Custom=linux-1,linux-4,linux-f1

inayd and others added 30 commits January 3, 2023 16:29
Usage of imread(): magic number 0, unchecked result

* docs: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread()

* samples, apps: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread()

* tests: rewrite 0/1 to IMREAD_GRAYSCALE/IMREAD_COLOR in imread()

* doc/py_tutorials: check imread() result
…ng-documentation

Fix broken paper link for fastNlMeansDenoising

* Fix broken link

* Move citation to `opencv.bib`

* Cite researchgate reference

* Correct citation label

* Use semantic scholar BibTex
Add `estimateSE2(...)`, `estimateSE3(...)`, `estimateSIM2(...)`, `estimateSIM3(...)` for estimating an geometric transformation with rotation and translation (with scaling for SIM) using USAC: as alternative for `estimateAffinePartial2D` and `estimateAffine3D`.

Modified test module.

Remove unused variables.

Remove initializer of unused variable.

Add interfaces to accept UsacParams() and corresponding test codes.

Revise test code.

PartialNd removed

Umeyama rewritten for code quality & speed

comments & minors

rise number of points

fix, and +30% faster!

only one number should be that big

remove USAC code, leave fix only

big number
perf: drop runtime time adjustment calibration
…ense

USAC fix: GraphCut fails to allocate big dense matrices
Backport of opencv#22992 to 3.4

### 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
Adding HEVC/H265 FourCC support to MSMF video writer

* Adding HEVC/H265 fourcc to MSMF video writer

Adding HEVC/H265 fourcc to MSMF video writer. I have verified it with my own video input stream, and it works well on my workstation.

* Update video io testing

* Adding macro fence to get rid of compiler error

H265/HEVC encoder is only available in Windows or later. https://learn.microsoft.com/en-us/windows/win32/medfound/h-265---hevc-video-encoder

* Update test_video_io.cpp
Omit the first check of the double-checked locking pattern in
recordException() in parallel.cpp when CV_THREAD_SANITIZER is defined.
This should only slow recordException() down when the thread sanitizer
is used, and avoids the TSAN data race warning.
dnn: add layer normalization for vision transformers

* add layer norm onnx parser, impl and tests

* add onnx graph simplifier for layer norm expanded

* handle the case when constants are of type Initializer

* add test case for layer norm expanded with initializers

* use CV_Assert & CV_CheckType in place of CV_Assert_N; use forward_fallback for OCL_FP16

* use const ref / ref in parameters of invoker::run; extract inner const if from nested loop; use size_t in place of ull

* template hasBias

* remove trailing whitespace

* use pointer parameter with null check; move normSize division & mean_square division outside of loop; use std::max to ensure positive value before std::sqrt

* refactor implementation, optimize parallel_for

* disable layer norm expanded

* remove the removal of layer norm optional outputs
@alalek
Copy link
Member Author

alalek commented Jan 30, 2023

👍

@alalek alalek merged commit e880d51 into opencv:5.x Jan 30, 2023
@asmorkalov
Copy link
Contributor

@savuor Could you take a look on changes in 3d module?

Comment on lines +429 to +431
eps_tvec_noise[CALIB_HAND_EYE_TSAI] = 7.0e-2;
eps_tvec_noise[CALIB_HAND_EYE_PARK] = 7.0e-2;
eps_tvec_noise[CALIB_HAND_EYE_HORAUD] = 7.0e-2;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is it changed? I have not found related PR in 3.4 history.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is changed for 4.x branch in #23167. Failure message e.g. here: https://pullrequest.opencv.org/buildbot/builders/precommit_linux64/builds/102499/steps/test_calib3d/logs/stdio

There are many failures of unreliable tests after "fixing" of RNG behavior.
Need to drop unstable get_rng() call completely.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet