blob: c3d4f56a0e0cb7c534a27e6f3b05b0d0ac81f6f6 [file] [log] [blame]
Michael Levit06fcf752022-01-12 11:53:46 +02001/*
Richard Burtonf32a86a2022-11-15 11:46:11 +00002 * SPDX-FileCopyrightText: Copyright 2022 Arm Limited and/or its affiliates <open-source-office@arm.com>
Michael Levit06fcf752022-01-12 11:53:46 +02003 * SPDX-License-Identifier: Apache-2.0
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
16 */
17#ifndef DETECTION_RESULT_HPP
18#define DETECTION_RESULT_HPP
19
20
21namespace arm {
22namespace app {
Isabella Gottardi3107aa22022-01-27 16:39:37 +000023namespace object_detection {
Michael Levit06fcf752022-01-12 11:53:46 +020024
25 /**
26 * @brief Class representing a single detection result.
27 */
28 class DetectionResult {
29 public:
Isabella Gottardi3107aa22022-01-27 16:39:37 +000030 /**
31 * @brief Constructor
32 * @param[in] normalisedVal Result normalized value
33 * @param[in] x0 Top corner x starting point
34 * @param[in] y0 Top corner y starting point
35 * @param[in] w Detection result width
36 * @param[in] h Detection result height
37 **/
Michael Levit06fcf752022-01-12 11:53:46 +020038 DetectionResult(double normalisedVal,int x0,int y0, int w,int h) :
39 m_normalisedVal(normalisedVal),
40 m_x0(x0),
41 m_y0(y0),
42 m_w(w),
Isabella Gottardi3107aa22022-01-27 16:39:37 +000043 m_h(h)
Michael Levit06fcf752022-01-12 11:53:46 +020044 {
45 }
Isabella Gottardi3107aa22022-01-27 16:39:37 +000046
47 DetectionResult() = default;
48 ~DetectionResult() = default;
49
50 double m_normalisedVal{0.0};
51 int m_x0{0};
52 int m_y0{0};
53 int m_w{0};
54 int m_h{0};
Michael Levit06fcf752022-01-12 11:53:46 +020055 };
56
Isabella Gottardi3107aa22022-01-27 16:39:37 +000057} /* namespace object_detection */
Michael Levit06fcf752022-01-12 11:53:46 +020058} /* namespace app */
59} /* namespace arm */
60
61#endif /* DETECTION_RESULT_HPP */