CARVIEW |
Navigation Menu
-
-
Notifications
You must be signed in to change notification settings - Fork 56.2k
[G-API] Support multiple asynchronous requests #19487
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
[G-API] Support multiple asynchronous requests #19487
Conversation
It seems a rebase is required |
@TolyaTalamanov can you please rebase to make the changeset clear? |
…port-nireq-option
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed ~40%, but didn't review the actual asynchronous pool part. Please clean-up code first (and, if possible, isolate changes for a single infer
only.
@@ -67,6 +67,9 @@ namespace detail { | |||
Kind kind; | |||
bool is_generic; | |||
IEConfig config; | |||
|
|||
// NB: Number of asyncrhonious infer requests | |||
size_t nireq; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just wondering why this and the above variables are not initialized by default.
Initially it was just num_in
/ num_out
I've left empty for some reason (as those are always initialized in ctor), but now it doesn't looks so good.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Didn't get your point, now it is initialized in ctor
. What's the problem ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The problem is when a new ctor is added (who knows), these fields may left uninitialized
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Partial initialization isn't supported in C++11
2ada749
to
13d7c1b
Compare
13d7c1b
to
5db2378
Compare
19be9a6
to
3a97e94
Compare
3a97e94
to
161a880
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's setup an overview call tomorrow.
What can be done for sure now is moving the async worker pool into something generic and unit-testable
…port-nireq-option
ff27092
to
115231f
Compare
115231f
to
ea0cf6f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approved if tests pass
return requests; | ||
} | ||
|
||
class cv::gimpl::ie::RequestPool { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
class cv::gimpl::ie::RequestPool {
struct RequestPool;
Warning on "Custom Win" builder:
C:\build\precommit_custom_windows\opencv\modules\gapi\src\backends\ie\giebackend.cpp(497): warning C4099: 'cv::gimpl::ie::RequestPool': type name first seen using 'struct' now seen using 'class' [C:\build\precommit_custom_windows\build\modules\gapi\opencv_gapi.vcxproj]
"Custom Mac":
/build/precommit_custom_mac/opencv/modules/gapi/src/backends/ie/giebackend.cpp:497:1: warning: 'RequestPool' defined as a class here but previously declared as a struct; this is valid, but may result in linker errors under the Microsoft C++ ABI [-Wmismatched-tags]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed
…option [G-API] Support multiple asynchronous requests * Support nireq option * Disable tests to check CI * Fix bug with hanging * WA to green CI * Snapshot * Simplify RequestPool * Add default values to id * Fix win warning
Pull Request Readiness Checklist
See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request
Patch to opencv_extra has the same branch name.
Build configuration