wrappers
openvino
rs-vino
age-gender-detection.h
Go to the documentation of this file.
1
// License: Apache 2.0. See LICENSE file in root directory.
2
// Copyright(c) 2019 Intel Corporation. All Rights Reserved.
3
4
#pragma once
5
6
#include "
base-detection.h
"
7
8
9
namespace
openvino_helpers
10
{
11
/*
12
Detects age and gender for a give face
13
*/
14
class
age_gender_detection
:
public
base_detection
15
{
16
public
:
17
struct
Result
18
{
19
float
age
;
20
float
maleProb
;
21
};
22
23
private
:
24
std::string
input
;
25
std::string
outputAge
;
26
std::string
outputGender
;
27
int
_n_enqued_frames
;
28
29
public
:
30
age_gender_detection
(
const
std::string
&
pathToModel
,
31
bool
isAsync
=
true
,
32
int
maxBatch
= 1,
bool
isBatchDynamic
=
false
,
33
bool
doRawOutputMessages
=
false
);
34
35
InferenceEngine::CNNNetwork
read_network
()
override
;
36
void
submit_request
()
override
;
37
38
void
enqueue
(
const
cv::Mat &
face
);
39
Result
operator[]
(
int
idx
)
const
;
40
};
41
}
openvino_helpers::age_gender_detection::read_network
InferenceEngine::CNNNetwork read_network() override
Definition:
age-gender-detection.cpp:65
openvino_helpers::base_detection::isAsync
const bool isAsync
Definition:
base-detection.h:26
openvino_helpers::base_detection::maxBatch
const size_t maxBatch
Definition:
base-detection.h:24
openvino_helpers::age_gender_detection::Result::age
float age
Definition:
age-gender-detection.h:19
openvino_helpers::base_detection::pathToModel
std::string pathToModel
Definition:
base-detection.h:23
string
GLsizei const GLchar *const * string
Definition:
glad/glad/glad.h:2861
openvino_helpers::age_gender_detection::enqueue
void enqueue(const cv::Mat &face)
Definition:
age-gender-detection.cpp:35
openvino_helpers::base_detection::isBatchDynamic
bool isBatchDynamic
Definition:
base-detection.h:25
openvino_helpers::age_gender_detection::Result
Definition:
age-gender-detection.h:17
example3 - opencv deploy.idx
idx
Definition:
example3 - opencv deploy.py:49
openvino_helpers::age_gender_detection::submit_request
void submit_request() override
Definition:
age-gender-detection.cpp:26
openvino_helpers::base_detection::doRawOutputMessages
const bool doRawOutputMessages
Definition:
base-detection.h:29
openvino_helpers::age_gender_detection::age_gender_detection
age_gender_detection(const std::string &pathToModel, bool isAsync=true, int maxBatch=1, bool isBatchDynamic=false, bool doRawOutputMessages=false)
Definition:
age-gender-detection.cpp:14
openvino_helpers::age_gender_detection::outputGender
std::string outputGender
Definition:
age-gender-detection.h:26
openvino_helpers::age_gender_detection::operator[]
Result operator[](int idx) const
Definition:
age-gender-detection.cpp:49
openvino_helpers::age_gender_detection::_n_enqued_frames
int _n_enqued_frames
Definition:
age-gender-detection.h:27
openvino_helpers::age_gender_detection
Definition:
age-gender-detection.h:14
openvino_helpers
Definition:
age-gender-detection.cpp:12
openvino_helpers::age_gender_detection::outputAge
std::string outputAge
Definition:
age-gender-detection.h:25
openvino_helpers::age_gender_detection::input
std::string input
Definition:
age-gender-detection.h:24
openvino_helpers::age_gender_detection::Result::maleProb
float maleProb
Definition:
age-gender-detection.h:20
openvino_helpers::base_detection
Definition:
base-detection.h:18
base-detection.h
rs2::face
std::array< float3, 4 > face
Definition:
model-views.h:85
librealsense2
Author(s): LibRealSense ROS Team
autogenerated on Fri Aug 2 2024 08:30:00