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

[Suggestion] Improve Pedestrain Trackor C++ Demo #2260

Open
wdkwyf opened this issue Mar 31, 2021 · 6 comments
Open

[Suggestion] Improve Pedestrain Trackor C++ Demo #2260

wdkwyf opened this issue Mar 31, 2021 · 6 comments
Labels
demo Issues with demo results, performance and etc. feature Adds new feature help wanted Extra attention is needed

Comments

@wdkwyf
Copy link
Contributor

wdkwyf commented Mar 31, 2021

Hi, OpenVINO guys, I learn a lot from your Pedestrain Trackor demo, however I wonder why some intel model can't be supported in this demo.
Such as person-detection-0203, person-detection-0106. Only person-detection-0201/0202 are supported.

I notice it's because the detection output is a little different, could you please improve the demo to let's try more detection models, because I want to try cascade-RCNN model to get better accuracy.

Thanks.

@wdkwyf wdkwyf added demo Issues with demo results, performance and etc. feature Adds new feature help wanted Extra attention is needed labels Mar 31, 2021
@vladimir-dudnik
Copy link
Contributor

vladimir-dudnik commented Mar 31, 2021

@wdkwyf Thanks for your interest and feedback, we will review that. Especially it make sense, since we have introduced, so called, Model API, which is a model class hierarchy, intended to simplify and unify use of different models, solving the same task, in apps

@wdkwyf
Copy link
Contributor Author

wdkwyf commented Mar 31, 2021

@vladimir-dudnik , Thank you. The 'model api' you mentioned is public now?

@vladimir-dudnik
Copy link
Contributor

@wdkwyf yes, you may take, for example, a look at C++ object_detection_demo (Python demo use similar approach) and you will find that a main application loop looks like (of course in simplified way):

std::unique_ptr model;
model.reset(new ModelYolo3(FLAGS_m, (float)FLAGS_t, FLAGS_auto_resize, FLAGS_yolo_af, (float)FLAGS_iou_t, labels));

InferenceEngine::Core core;
AsyncPipeline pipeline(std::move(model), ConfigFactory::getUserConfig(FLAGS_d, FLAGS_l, FLAGS_c, FLAGS_pc, FLAGS_nireq, FLAGS_nstreams, FLAGS_nthreads), core);

while (keepRunning)
{
curr_frame = cap->read();

frameNum = pipeline.submitData(ImageInputData(curr_frame), std::make_shared<ImageMetaData>(curr_frame, startTime));

pipeline.waitForData();

//--- Checking for results and rendering data if it's ready
result = pipeline.getResult())
cv::Mat outFrame = renderDetectionData(result->asRef<DetectionResult>(), palette);

int key = cv::waitKey(1);
if (27 == key || 'q' == key || 'Q' == key)
{
    // Esc
    keepRunning = false;
}

}

So, we have a base Model class and several derived Model specifc classes. This way, model specific pre and post processing are tightly coupled with appropriate model class and not spread across the application. And with unified representation of generalized model task results (like object detection task), we can easily support many different object detection model topologies in single application. That the difference between previous Open Model Zoo demos where we got several object detection demos (if you remember): object_detection_demo_centernet, oject_detection_demo_faceboxes, object_detection_demo_retinaface, object_detection_demo_ssd_async, object_detection_demo_yolov3_async - all these and even more now covered by single demo application.

@vladimir-dudnik
Copy link
Contributor

@wdkwyf FYI, we are working in applying OMZ Model API to pedestrian tracker demo, see #2654

@wdkwyf
Copy link
Contributor Author

wdkwyf commented Sep 13, 2021

in applying OMZ Mod

@vladimir-dudnik Thanks! I'll check.

@vladimir-dudnik
Copy link
Contributor

@wdkwyf #2654 merged and is now part of OpenVINO 2022.1 release

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
demo Issues with demo results, performance and etc. feature Adds new feature help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants