Commit Graph

23052 Commits

Author SHA1 Message Date
Rostislav Vasilikhin
d49958141e
Merge pull request #22925 from savuor:pytsdf_from_scratch
Fixes #22799

Replaces #21559 which was taken as a base

Connected PR in contrib: [#3388@contrib](https://github.com/opencv/opencv_contrib/pull/3388)

### Changes
OK, now this is more Odometry-related PR than Volume-related. Anyway,
* `Volume` class gets wrapped
* The same was done for helper classes like `VolumeSettings`, `OdometryFrame` and `OdometrySettings`
* `OdometryFrame` constructor signature changed to more convenient where depth goes on 1st place, RGB image on 2nd.
This works better for depth-only `Odometry` algorithms.
* `OdometryFrame` is checked for amount of pyramid layers inside `Odometry::compute()`
* `Odometry` was fully wrapped + more docs added
* Added Python tests for `Odometry`, `OdometryFrame` and `Volume`
* Added Python sample for `Volume`
* Minor fixes including better var names

### 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
2022-12-12 09:40:12 +03:00
Rostislav Vasilikhin
86c6e07326
Merge pull request #22863 from savuor:tsdf_tests_join
### Changes
* Duplicated code removal in TSDF tests by implementing them with fixtures and GTest params
  * e.g. separate OCL tests file removed
  * as a result, more test cases are covered
  * the same's done for perf tests

### 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
2022-12-06 12:15:39 +03:00
Rostislav Vasilikhin
a423b07149
Merge pull request #22845 from savuor:volume_interface_etc
Corresponding contrib PR: #3382@contrib

Changes

- Volume::raycast(): camera intrinsics can be explicitly passed to the function. If not, the ones from current volume settings are used
- getVolumeDimensions() renamed to getVolumeStrides() because they are strides actually
- TSDF tests: OpenCLStatusRevert and parametrized fixture
- ColorTSDF::integrate(): extra RGB projector is redundant, removed
- Minor changes
2022-11-24 17:16:18 +03:00
Rostislav Vasilikhin
2407ab4e61
Merge pull request #22178 from savuor:hash_tsdf_fixes
This PR contains:

- a new property enableGrowth which controls should the HashTSDF be extended during integration by adding new volume units or not
- a new method getBoundingBox which calculates the size of currently occupied data
- a set of tests to check that new functionality
- a fix for TSDF GPU reset (data is correctly zeroed now using floatToTsdf() function)
    minor changes
2022-11-22 09:24:41 +03:00
Rostislav Vasilikhin
a9d98bfb34
Merge pull request #22741 from savuor:hashtsdf_volposerot_fix
There's a bug which appears when volume pose contains non-trivial rotation.
It results in wrong depth integration which can be observed during raycasting 
or points/normals export.

- This PR fixes the bug for both CPU and OpenCL
- There is a reproducer for the bug
- The copy behavior of VolumeSettings fixed (now copy constructor creates a deep copy)
- Minor changes (e.g. unused vars removed)
2022-11-17 09:10:35 +03:00
Yuhang Wang
d976272d23
Merge pull request #22682 from TsingYiPainter:5.x
3D: Handle cases where the depth of Octree setting is too large

* Handle cases where the depth setting is too large
2022-11-03 07:15:17 +00:00
Rostislav Vasilikhin
a09bb3c2f6 doc fixes 2022-10-25 22:37:38 +02:00
Rostislav Vasilikhin
95ab8517ae trailing whitespaces 2022-10-25 02:58:55 +02:00
Rostislav Vasilikhin
a1820ff3d4 unused function removed 2022-10-25 02:45:42 +02:00
Rostislav Vasilikhin
097b0245da getScaledDepth -> getProcessedDepth 2022-10-25 02:45:28 +02:00
Rostislav Vasilikhin
52d82bb44a docs for Odometry+Frame 2022-10-25 02:44:12 +02:00
Rostislav Vasilikhin
8b7e586faa
Merge pull request #22598 from savuor:icp_oframe_readonly
Complement PR: #3366@contrib
Changes

    OdometryFrame losts its getters: a user can provide data at construction stage only, pyramids and other generated data is read-only now
    OdometryFrame is based on UMats: no TMat templates inside, CPU operations are done with UMat::getMat() method, chaining issues are solved ad-hoc
    No more Odometry::createOdometryFrame() method, frames are compatible with all odometry algorithms
    Normals computer is cached inside Odometry and exposed to API as well as its settings
    Volume::raycast() won't return the result in OdometryFrame anymore
    Added test for Odometry::prepareFrame*() & other test fixes
    Minor code improvements

TODOs:

    fix TODOs in code
    lower acceptable accuracy errors
2022-10-24 16:34:01 +03:00
Alexander Smorkalov
5b97f6abec
Merge pull request #22136 from sturkmen72:HOGDescriptor_update
HOGDescriptor
2022-10-07 15:17:57 +03:00
Suleyman TURKMEN
07b62376af Update objdetect.hpp 2022-10-06 23:13:44 +03:00
Alexander Smorkalov
3857173845
Merge pull request #22287 from asenyaev:asen/disabled_compiling_warnings_5.x
Disabled compiling warnings in case of symbols in cmake for 5.x
2022-09-20 16:19:08 +03:00
Andrey Senyaev
752e5fdc26 Disabled compiling warnings in case of symbols in cmake for 5.x 2022-09-20 13:36:59 +03:00
Rostislav Vasilikhin
f92a1aa07d trying to fix MSVC compilation
double -> float warning

fix warnings in the rest 3d module files

extra var removed

try to fix warnings
2022-09-19 00:27:26 +02:00
Rostislav Vasilikhin
9ba4bb7355 initIntrisicParams2D() refactored
variables refactoring

levmarq fix

initIntrinsicParams2D() refactoring

undo LM fix

cameraCalcJErr: made a lambda; warnings fixed; vars rearranged & renamed, jacobian buffers, perViewErrors and allErrors fix, etc.

stereoCalibrate: internal vars in callback

stereoCalibrate: capture only useful variables

stereoCalibrate: perViewError fix + minors

rvecs and tvecs are not pointers anymore

no extra lambda

newObjPoints: no pointers

stdDevs: no pointers

_Jo removed: not used

Range::all() -> rowRange, colRange

param and mask are std::vectors now

indices shortened

tabs

less func-scoped vars; TODOs

less formatting & renaming changes

trailing whitespaces

less diff

less changes

less changes

Range::all() back

perViewErr ptr fix

NINTRINSIC captured

try to fix warning

trying to fix a warning

fix warnings, another attempt
2022-09-15 22:55:40 +02:00
Rostislav Vasilikhin
b1020639f1 perViewErr fix 2022-09-09 17:40:26 +02:00
Rostislav Vasilikhin
a8b4ffac50 volatile variable made mask-fixed as it should be 2022-09-05 18:42:17 +02:00
Rostislav Vasilikhin
8a43956a1b less pointers
rtsort + formatting

less pointers + more compact code

less reallocations, cleaner code

less pointers, less GEMMs

trailing whitespace
2022-09-05 18:42:15 +02:00
Rostislav Vasilikhin
bfc4bdd9d0 regression test added
test data moved to opencv_extra, loads from yaml.gz file now
2022-09-05 18:42:12 +02:00
Rostislav Vasilikhin
96e2d32618 fixing broken stereo calibration 2022-09-05 18:42:12 +02:00
Rostislav Vasilikhin
487619e5fe no address arithmetics
less address arithmetics

happy valgrind: copy recomputed intrinsics only
2022-09-05 18:42:09 +02:00
Alexander Smorkalov
335d7bd16e
Merge pull request #22241 from savuor:normals_scale_test
More tests for normals
2022-08-24 10:25:55 +03:00
Alexander Smorkalov
3a02561c40 Merge pull request #22417 from savuor:levmarq_log_level_fix 2022-08-24 07:17:22 +00:00
Rostislav Vasilikhin
eb571b500b fixes warnings 2022-08-23 10:22:28 +02:00
Alexander Smorkalov
505bbab75b
Merge pull request #22413 from savuor:levmarq_log_level
LevMarq: log level lowered
2022-08-23 09:22:39 +03:00
Rostislav Vasilikhin
3cf3e3f6f7 LevMarq: log level lowered 2022-08-22 23:53:49 +02:00
Rostislav Vasilikhin
232a83ecb8 check mask values 2022-08-22 16:07:07 +02:00
Alexander Alekhin
c25f776151 Merge branch 4.x 2022-08-21 15:27:31 +00:00
Anatoliy Talamanov
925ff6241f
Merge pull request #22393 from TolyaTalamanov:at/fix-gapi-vpl-windows-build
* Fix G-API OneVPL compilation

* Fix macro

__WIN32__ -> _WIN32
2022-08-20 20:24:41 +03:00
Rostislav Vasilikhin
48c10620cb depthTo3d: fixed bug, added regression test
RgbdNormals: setMethod() removed as useless

RgbdNormals: tests + cross product, to be fixed

+ cross product

LINEMOD: diffThreshold param added + tests fixed

minor

diffThreshold fix

points3dToDepth16U fix

normals computer diffThreshold fix

random plane generation fixed + diffThreshold fix

Rendered normals test rewritten to GTest Params

random plane generation: scale

RGBD_Normals tests: thresholds tuned

Rendered normals tests: 64F support added

Random planes normal tests rewritten to GTest Params

LINEMOD and CrossProduct fix

SRI threshold raised

NormalsRandomPlanes: thresholds raised

assert on unknown alg; minor

fix

frame size reduced

TIFF replaced by YAML.GZ

depthTo3d test changed

cv::transform is used

fix warning

nanMask()

flipAxes()

absDotPixel() + forgotten code

helper functions removed

RGBDNormals: checkNormals() and compare LINEMOD's pts3d to depth input

Rendered: another criteria; thresholds; LINEMOD's pts3d to depth input comparison

thresholds raised a bit

SRI slightly optimized

assert change

normal tests refactored, parametrized, split

trailing namespace, thresholds raised

SRI caching optimized a lot

normal tests rewritten to fixture, no loop

minor

runCase() joined with testIt()

thresholds were put into GTest params

ternary operator

RgbdNormalsTest merged into NormalsRandomPlanes; RgbdPlanes moved closer to tests

normal test minor refactoring

plane finder tests refactored to GTest Params

skip tests

thresholds raised

plane test minor

plane tests: timers dropped, nPlanes put into GTest Params; refactoring

generated normals tests: minor refactoring

flipAxes() templated

rendered normals tests refactored: thresholds to GTest Params

CV_Error -> ASSERT_FALSE
2022-08-19 20:16:08 +02:00
Alexander Smorkalov
e14c3cff85 Merge pull request #22403 from Biswa96:add-locale-header 2022-08-19 10:01:23 +00:00
Biswapriyo Nath
984e42b0bc videoio: Include missing locale header for std::wstring_convert
This fixes the following error with mingw toolchain:
opencv/modules/videoio/src/cap_msmf.cpp:1020: error: 'wstring_convert' is not a member of 'std'
 1020 |                                     std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>> conv;
      |                                          ^~~~~~~~~~~~~~~
opencv/modules/videoio/src/cap_ffmpeg_hw.hpp:230:26: error: 'wstring_convert' is not a member of 'std'
  230 |                     std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>> conv;
      |                          ^~~~~~~~~~~~~~~

The locale header is required according to C++ standard.
See https://en.cppreference.com/w/cpp/locale/wstring_convert
2022-08-19 13:15:58 +05:30
Alexander Smorkalov
0702685e7e Merge pull request #22395 from hzcyf:infinite_loop_fix 2022-08-19 07:11:09 +00:00
Alexander Smorkalov
7deb8f568f Merge pull request #22377 from Biswa96:condition_variable 2022-08-18 11:31:21 +00:00
Alexander Smorkalov
d8434e6875
Merge pull request #22396 from dmatveev:dm/ade-012
G-API: Bump ADE to version 0.1.2
2022-08-18 14:28:44 +03:00
Dmtiry Matveev
03130548ea G-API: Bump ADE to version 0.1.2 2022-08-18 07:50:22 +03:00
hzcyf
11c5a6bb4d Fix infinite loop in obsensor 2022-08-18 12:22:22 +08:00
Alexander Smorkalov
9fcf015214 Merge pull request #22376 from zihaomu:issue_22373 2022-08-15 10:00:11 +00:00
Alexander Smorkalov
ffccfa2ee9 Merge pull request #22325 from komakai:fix-quicklook 2022-08-15 09:25:43 +00:00
Zihao Mu
d3dcef4b8b add new check for vidcap.h 2022-08-15 16:44:25 +08:00
Alexander Alekhin
2ebdc04787 Merge remote-tracking branch 'upstream/3.4' into merge-3.4 2022-08-14 15:50:42 +00:00
Alexander Alekhin
cc8add9f66 Merge pull request #22370 from catree:fix_22242_filter2d_float_double_doc 2022-08-14 15:04:12 +00:00
Biswapriyo Nath
c2c539e3cc
videoio: Include missing condition_variable header
This fixes the following error with mingw toolchain:
opencv/modules/videoio/src/cap_obsensor/obsensor_stream_channel_msmf.hpp:160:10: error: 'condition_variable' in namespace 'std' does not name a type
  160 |     std::condition_variable streamStateCv_;
      |          ^~~~~~~~~~~~~~~~~~
2022-08-14 19:26:08 +05:30
Alexander Alekhin
d0d115321d Merge pull request #22350 from alalek:rework_psabi_warning 2022-08-13 15:05:41 +00:00
catree
3d8614cb47 Fix documentation about depth combinations for imgproc functions. 2022-08-12 12:53:01 +02:00
Alexander Smorkalov
bb71cb200e
Merge pull request #22199 from zihaomu:bug_fix_22195
DNN: Reduce Layer (add dynamic batch and ReduceSum support)
2022-08-11 12:59:51 +03:00
Jochen Sprickerhof
496eed950f
Add missing header for LIBAVCODEC_VERSION_INT 2022-08-08 23:33:28 +02:00