Skip to content

[G-API] Fix bug of GArray<GArray> passing through a graph#19828

Merged
alalek merged 4 commits intoopencv:masterfrom
OrestChura:oc/fix_garray_garray_input
Apr 1, 2021
Merged

[G-API] Fix bug of GArray<GArray> passing through a graph#19828
alalek merged 4 commits intoopencv:masterfrom
OrestChura:oc/fix_garray_garray_input

Conversation

@OrestChura
Copy link
Copy Markdown
Contributor

If GArray<GArray> wasn't an input or an output of a graph, assertion would fail.

Added test to check the fix works

Pull Request Readiness Checklist

See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request

  • I agree to contribute to the project under Apache 2 License.
  • To the best of my knowledge, the proposed patch is not based on a code under GPL or other license that is incompatible with OpenCV
  • The PR is proposed to proper branch
  • There is reference to 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
force_builders=Custom,Custom Win,Custom Mac
build_gapi_standalone:Linux x64=ade-0.1.1f
build_gapi_standalone:Win64=ade-0.1.1f
build_gapi_standalone:Mac=ade-0.1.1f
build_gapi_standalone:Linux x64 Debug=ade-0.1.1f

build_image:Custom=centos:7
buildworker:Custom=linux-1
build_gapi_standalone:Custom=ade-0.1.1f

Xbuild_image:Custom=ubuntu-openvino-2021.3.0:20.04
build_image:Custom Win=openvino-2021.2.0
build_image:Custom Mac=openvino-2021.2.0

test_modules:Custom=gapi,python2,python3,java
test_modules:Custom Win=gapi,python2,python3,java
test_modules:Custom Mac=gapi,python2,python3,java

buildworker:Custom=linux-1
# disabled due high memory usage: test_opencl:Custom=ON
Xtest_opencl:Custom=OFF
Xtest_bigdata:Custom=1
Xtest_filter:Custom=*

Copy link
Copy Markdown
Contributor

@dmatveev dmatveev left a comment

Choose a reason for hiding this comment

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

Must be ok but please test more carefully

@dmatveev dmatveev added this to the 4.5.2 milestone Apr 1, 2021
@dmatveev dmatveev self-assigned this Apr 1, 2021
@dmatveev
Copy link
Copy Markdown
Contributor

dmatveev commented Apr 1, 2021

@alalek that's the 2nd part of the hotfix (now validated with a test)

@OrestChura OrestChura marked this pull request as ready for review April 1, 2021 13:22
@OrestChura OrestChura changed the title WIP: [G-API] Fix bug of GArray<GArray> passing through a graph [G-API] Fix bug of GArray<GArray> passing through a graph Apr 1, 2021
@OrestChura
Copy link
Copy Markdown
Contributor Author

@alalek fix & test reviewed, ready for merging

@alalek alalek merged commit 34a8a45 into opencv:master Apr 1, 2021
@dmatveev
Copy link
Copy Markdown
Contributor

dmatveev commented Apr 2, 2021

Fantastic, thanks!

@alalek alalek mentioned this pull request Apr 9, 2021
a-sajjad72 pushed a commit to a-sajjad72/opencv that referenced this pull request Mar 30, 2023
…input

[G-API] Fix bug of GArray<GArray> passing through a graph

* Add test to check GArray<GArray> passing through a graph (assertion failed)

* G-API: Flatten GArray<T> to std::vector<T> when capturing VCtr

- Also: Fix formatting in garray.hpp

* Refactored test, added valuable check

* Initialize size_t

Co-authored-by: Dmitry Matveev <dmitry.matveev@intel.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants