1
0
mirror of https://github.com/opencv/opencv_contrib.git synced 2025-10-15 20:37:07 +08:00
Commit Graph

131 Commits

Author SHA1 Message Date
Liutong HAN
b9a460b857 Use new Universal Intrinsic API. 2023-10-14 09:21:42 +08:00
Maksim Shabunin
c56efb910e Fix clang 14 warnings 2023-02-06 23:16:18 +03:00
Mat&I
5a35eb1166 Merge pull request #3423 from matijazigic:fix_optflow_rlof
### 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
- [ ] There is accuracy test, performance test and test data in opencv_extra repository, if applicable
      Patch to opencv_extra has the same branch name.
- [ ] The feature is well documented and sample code can be built with the project CMake


The bug has already been reported and explained on the OpenCV forum:

- [optflow-calcopticalflowsparserlof-giving-assertion-error](https://forum.opencv.org/t/cv2-optflow-calcopticalflowsparserlof-giving-assertion-error/4835)
- [calcopticalflowsparserlof-assertion-error-in-initialflow](https://forum.opencv.org/t/calcopticalflowsparserlof-assertion-error-in-initialflow/8669)

The bug is manifested only if 'UseInitialFlow' is set to true and 'ForwardBackwardThreshold' > 0 (enabled).
2023-01-24 11:21:44 +03:00
Alexander Alekhin
2bc3e1a169 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2021-10-08 12:08:54 +00:00
Suleyman TURKMEN
1b39461321 cleanup old c 2021-10-08 01:29:51 +03:00
amir.tulegenov
61e0a2de73 [moved from opencv] fix getDefaultName()
original commit: cbb230fdfc
2021-02-21 20:07:54 +00:00
Alexander Alekhin
697d9e2c6c Merge pull request #2804 from MrKepzie:optflow-rlof-crash 2021-01-11 20:59:26 +00:00
MrKepzie
55f5303cf3 rlof optflow: fix crash when no match are found 2021-01-09 17:45:59 +01:00
Alexander Alekhin
21591028fb optflow(rlof): fix uninitialized variable 2020-10-27 11:34:16 +00:00
Tobias Senst
4b63202293 Merge pull request #2476 from tsenst:optimize_performance_rlof
Rework RLOF by using HAL universal instructions

* * distinguish between SSE2 and SSE 4.1 support
* SSE2 now implements no paralellized _blendv functiona and allows to compile with SSE2 instructions

* * add interface function do enable disable M-estimator framework
* bugfix blendv functions

* * make use of _mm_store and _mm_load functions in blendv_ps and blendv_epi function to fix compiler error

* * implement substitute of _mm_cvtepi8_epi16 and _mm_cvtepi16_epi32 when compiling with less than SSE 4.1 support

* * implement substitute of _mm_abs_epi16 when compiling with less than SSE 3 support

* * move _mm_abs_epi16 to SSE4 req.

* * add HAL intrinsic functions for RLOF ICA
* first tests are OK

* * HAL intrinsic functions -> RLOF ICA is ready now

* * add HAL functions for RLOF illumination model

* * add HAL for PLK ILL

* * add HAL functions for plk ica

* * commit HAL functions for beplk ica

* * add HAL functions for berlof ica

* * add HAL functions for BEPLK ILL

* *remove unused #ifdef

* * remove white spaces and unused variables

* * remove not used variables

* + remove get4BitMask function which contained pure SEE instructions

* * remove buffIdx which has not been used but initialized

* * fix replacement of #ifdef CV_SIMD128 with #if CV_SIMD128
* rename useMEstimator to setUseMEstimator

* *remove whitespace

* * remove unused variable abss

* * remove unused value

* * rename W_BITS1 to W_BITS since they contain same value
2020-03-31 15:20:18 +00:00
Alexander Alekhin
9c3e86b7ae Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2020-01-12 09:32:23 +00:00
Alexander Alekhin
ee3ef107db core(SIMD): allow to build modules with SIMD emulator 2019-12-29 21:06:48 +00:00
Tobias Senst
40b238b01d Merge pull request #2367 from tsenst:add_robust_interpolation_of_correspondence
Add RIC method for sparse match interpolation

* * add RIC

* sparse_match_interpolators EdgeAwareInterpolation - enhance limitation of the maximal number of matches to be interpolated from SHORT_MAX to INT_MAX by substituting short by int types

* * add RIC citation

* * update EdgeAwareInterpolatorImpl

* * add intermediate RIC implementation

* * implementation of new paralelization classes. First test where sucessfull.

* * update documentation RICInterpolatorImpl and RLOF

* * update CMakeLists.txt remove highgui
* add test for RIC
* add ASSERTION for curr image

* * add cost map interface

* * fix internal cost map allocation bug

* * remove white spaces
* fix warnings

* *fix compiler warnings

* * remove double whitespaces
* underscore from parameters
* substitute parallel_for_() classes with lambda functions
* remove complex assertion statements
* remove dead code
* substitute swap function with std::swap()
* ocv_define_module now contains video instead of tracking module

* * remove whitespace endings

* * documentation update

* * remove double declarations that lead to warnings

* * unrole tracker.py
*  remove double space
* use static for inner functions
* update create function
* modify mem init. to avoid manual memory management

* * uncomment parallel_for_ for parallelization

* * unrole unwanted changes
* uncomment paralellization

* * remove empty comment
* change CHECK to CHK_GD
* remove not necessary ;

* *documentation remove double space
2019-12-09 18:46:16 +03:00
Alexander Alekhin
35972a1ec4 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-11-18 07:19:57 +00:00
Alexander Alekhin
4c5f06128b build: GCC9 compilation 2019-11-12 18:50:43 +03:00
Alexander Alekhin
26129cfe69 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-09-25 18:55:28 +03:00
Alexander Alekhin
1a15cbc9ae Merge pull request #2271 from alalek:build_cxx11_warnings 2019-09-24 22:09:18 +00:00
Maksim Shabunin
cdd19ebead backport: Fixed warnings produced by clang-9.0.0
83fc27cb99
2019-09-24 12:32:41 +03:00
Moeed
4f524db434 Merge pull request #2269 from shaikmoeed:hotfix/samples-motempl-python-update
* Fix bug: Invalid Syntax at line 14(draw_motion_comp method)

* Fix bug: TypeError- integer argument expected, got float

* Fix bug: clean up the camera by adding .release()
2019-09-23 18:51:31 +03:00
Alexander Alekhin
fd10a4626c Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-04-18 19:59:16 +03:00
Tobias Senst
7ac648c2bd Merge pull request #2097 from tsenst:robust_optical_flow_fix
optflow: RLOF fixes (python-binding, status flag, flat textures) (#2097)

* * Bugfix for python-binding related to issue #2094. Copying the prevPtsMat to prevPoints was broken, when using python-binding.

* * Connect the blurred image correctly to CROSS support region segmentation. This allows to compute more robust support region shapes. Commit refers to issue #2094.

* * Bugfix to avoid the unintended assertion on flat textures discussed in issue #2094.

* * Bugfix on SparseRLOFOpticalFlow status was wrongly to to 0 if forward backward error < threshold, which is wrong. Inequation has been corrected. Refers to in issue #2087.

* small documentation changes

* bugfix on assertions and small test changes
2019-04-17 22:12:11 +03:00
Alexander Alekhin
8fce7e9fa7 optflow: fix RLOF SR_CROSS check 2019-04-16 20:24:45 +00:00
berak
5bf98275f4 optflow: add a check for 3 channel images for sparse RLOF 2019-04-14 12:31:30 +02:00
Alexander Alekhin
33f18dd60b Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2019-02-26 15:41:56 +03:00
Maksim Shabunin
b6767ccc43 Merge pull request #2011 from mshabunin:enable-narrowing-warning
* Fixed type narrowing issues
2019-02-26 13:15:23 +03:00
tsenst
1c9e23745c Merge pull request #1940 from tsenst:add_robust_optical_flow_implementation
Add robust local optical flow (RLOF) implementations (#1940)

* Add robust local optical flow (RLOF) implementations which is an improved pyramidal iterative Lucas-Kanade approach. This implementations contains interfaces for sparse optical flow for feature tracking and dense optical flow based on sparse-to-dense interpolation schemes.
Add performance and accuracy tests have been implementation as well as documentation with the related publications

* - exchange tabs with spaces
- fix optflow.bib indentation
- remove optflow_o.hpp
- change RLOFOpticalFlowParameter interfaces to Ptr<RLOFOpticalFlowParameter>
to remove error on building. Fix warnings

* introducing precompiler flag RLOD_SSE

* remove header that could not be found

* remove whitespaces
fix perf and accuracy tests

* remove x86intrin.h header

* fix ios and arm by removing last sse commands

* fix warnings for windows compilation

* fix documentation RLOFOpticalFlowParameter

* integrate cast to remove last warnings

* * add create method and function inferfaces to RLOFOpticalFlowParamter to enable python wrapper interfaces

* white space fixes / coding style

* fix perf test

* other changes: precomp.hpp / static

* use Matx44f and Vec4f instead of Mat

* normSigmas into constants

* replace ceil() calls

* maximum level is set to 5 so that it is similar value used in the papers

* implement paralellized horizontal cross segmentation as used in Geistert2016

* drop dead code

* Avoid using "data" and "step" calculations. Use .ptr<mat_type>(row, col) instead.

* Avoid using "data" and "step" calculations. Use .ptr<mat_type>(row, col) instead.

* bugfix on BEPLK with ica and adapt the accuracy tests

* more 'static' functions

* bugfix after changing ptr + step to .ptr(y,x) calls by adjusting ROI of
prevImage, currImage and derivI as well as changing the offset of the
points in the invoker classes.

* add some static_cast to avoid warning

* remove 50 grid size sample from perf test. This grid size is to sparse
for the epic interpolation

* remove notSameColor function since it is not used anymore
2018-12-30 13:10:21 +03:00
tompollok
9e5926200e use #if instead of #ifdef for CV_SIMD128 2018-11-11 23:22:51 +01:00
Alexander Alekhin
2f516f1af3 Merge pull request #1896 from alalek:docs_fix_bib_Kroeger2016
docs: fix Kroeger2016 bib reference

move from opencv_contrib
2018-11-10 20:12:28 +03:00
Vadim Pisarevsky
dbfa4d7228 TVL1 optical flow example moved from opencv to opencv_contrib 2018-11-09 16:10:57 +03:00
Vadim Pisarevsky
2cc5ead103 moved DIS optical flow from opencv_contrib to opencv, moved TVL1 from opencv to opencv_contrib 2018-11-09 00:48:48 +03:00
Vadim Pisarevsky
4cf4cb099b fixed compile error with the new C++ persistence in contrib (#1864) 2018-11-02 00:27:32 +03:00
Alexander Alekhin
c94997ec4f fix includes 2018-10-25 14:24:56 +03:00
Hamdi Sahloul
c880b7ea4d Utilize CV_UNUSED macro 2018-09-07 19:52:08 +09:00
Alexander Alekhin
1070e7042a Merge pull request #1733 from cv3d:minor/umat_getmat_access 2018-08-24 06:45:02 +00:00
Hamdi Sahloul
271f2bcf86 UMat::getMat(): Utilize ACCESS_READ instead of 0 2018-08-24 06:03:39 +09:00
trobro
ac7d1ca613 optflow: is depending on opencv_flann 2018-08-09 22:06:13 +02:00
Alexander Alekhin
fc69aa57bc opencv: use cv::AutoBuffer<>::data() 2018-06-13 19:11:18 +00:00
Vitaly Tuzov
1bcb634a12 Fixed coarse scale evaluation for DIS optical flow estimator 2018-05-15 13:22:51 +03:00
Alexander Alekhin
b8de57f8bd cleanup unnecessary setNumThreads() calls 2018-04-28 14:53:50 +03:00
Alexander Alekhin
036e699553 samples: apply CV_OVERRIDE/CV_FINAL 2018-03-28 17:25:51 +03:00
Alexander Alekhin
0aaaba08af optflow: apply CV_OVERRIDE/CV_FINAL 2018-03-28 16:49:59 +03:00
Alexander Alekhin
af58e08ee2 build: fix C++17 build 2018-02-08 18:00:59 +03:00
Alexander Alekhin
edfdf12c31 tests: refactor test files 2018-02-02 19:15:28 +03:00
Vadim Pisarevsky
53986aaa7d Merge pull request #996 from mshabunin:cmakeex 2017-12-15 10:47:38 +00:00
Vadim Pisarevsky
e53977f64b Merge pull request #1482 from terfendail:bitexact_resize 2017-12-14 20:48:10 +00:00
Vitaly Tuzov
8c394a4f2e Updated internal calls to linear resize to use bit-exact version 2017-12-14 13:00:09 +03:00
Alexander Alekhin
57ff363389 python: 'cv2.' -> 'cv.' via 'import cv2 as cv' 2017-12-11 16:14:46 +03:00
Maksim Shabunin
18a5391672 Fixed exports and removed contrib_world 2017-12-04 14:12:23 +03:00
Alexander Alekhin
b556c2a7c3 build: migrate to traits::Type / traits::Depth 2017-08-25 19:07:05 +03:00
Alexander Alekhin
b1408e33b0 Merge pull request #1292 from VladX:gpc_fix 2017-07-24 16:43:34 +00:00