MCPcopy Create free account
hub / github.com/comaps/comaps / CalcMetrics

Method CalcMetrics

libs/map/benchmark_tool/api.cpp:20–35  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18}
19
20void Result::CalcMetrics()
21{
22 if (!m_time.empty())
23 {
24 sort(m_time.begin(), m_time.end());
25
26 m_max = m_time.back();
27 m_med = m_time[m_time.size() / 2];
28 m_all = accumulate(m_time.begin(), m_time.end(), 0.0);
29 m_avg = m_all / m_time.size();
30
31 m_time.clear();
32 }
33 else
34 m_all = -1.0;
35}
36
37void AllResult::Print()
38{

Callers 1

PrintMethod · 0.80

Calls 6

backMethod · 0.80
emptyMethod · 0.45
beginMethod · 0.45
endMethod · 0.45
sizeMethod · 0.45
clearMethod · 0.45

Tested by

no test coverage detected