Lane and Object Detection
Using OpenCV and YOLOv7
Loading...
Searching...
No Matches
Performance.hpp
1
#pragma once
2
3
#include <chrono>
4
#include <cstdint>
5
#include <string>
6
#include <vector>
7
8
#include "helpers/Information.hpp"
9
14
namespace
LaneAndObjectDetection
15
{
20
class
Performance
21
{
22
public
:
26
explicit
Performance
();
27
31
void
StartTimer
();
32
36
void
EndTimer
();
37
43
PerformanceInformation
GetInformation
();
44
50
std::vector<uint32_t>
GetFrameTimes
();
51
57
static
std::string
GetTimeUnit
();
58
64
static
uint32_t
GetTimeUnitConversion
();
65
69
void
ClearPerformanceInformation
();
70
71
private
:
75
PerformanceInformation
m_performanceInformation
;
76
80
std::vector<uint32_t>
m_frameTimes
;
81
85
std::chrono::time_point<std::chrono::high_resolution_clock>
m_startTime
;
86
};
87
}
LaneAndObjectDetection::Performance::GetInformation
PerformanceInformation GetInformation()
Get the PerformanceInformation struct.
Definition
Performance.cpp:34
LaneAndObjectDetection::Performance::Performance
Performance()
Constructs a new Performance object.
Definition
Performance.cpp:12
LaneAndObjectDetection::Performance::GetFrameTimes
std::vector< uint32_t > GetFrameTimes()
Get the times to compute each and every frame.
Definition
Performance.cpp:39
LaneAndObjectDetection::Performance::GetTimeUnit
static std::string GetTimeUnit()
Get the time unit for the frame times.
Definition
Performance.cpp:44
LaneAndObjectDetection::Performance::m_startTime
std::chrono::time_point< std::chrono::high_resolution_clock > m_startTime
The time the internal timer was started within StartTimer().
Definition
Performance.hpp:85
LaneAndObjectDetection::Performance::GetTimeUnitConversion
static uint32_t GetTimeUnitConversion()
Get the divisor needed to convert the frame times to seconds.
Definition
Performance.cpp:49
LaneAndObjectDetection::Performance::m_performanceInformation
PerformanceInformation m_performanceInformation
The PerformanceInformation struct containing all performance-related information.
Definition
Performance.hpp:75
LaneAndObjectDetection::Performance::ClearPerformanceInformation
void ClearPerformanceInformation()
Clears all performance-related information.
Definition
Performance.cpp:54
LaneAndObjectDetection::Performance::EndTimer
void EndTimer()
End the internal timer.
Definition
Performance.cpp:21
LaneAndObjectDetection::Performance::StartTimer
void StartTimer()
Start the internal timer.
Definition
Performance.cpp:16
LaneAndObjectDetection::Performance::m_frameTimes
std::vector< uint32_t > m_frameTimes
The frame times that have been measured.
Definition
Performance.hpp:80
LaneAndObjectDetection
Contains all Lane-and-Object-Detection objects.
LaneAndObjectDetection::PerformanceInformation
The information needed by FrameBuilder to update frame with performance information.
Definition
Information.hpp:87
include
helpers
Performance.hpp
Generated on
for Lane and Object Detection by
1.14.0