MCPcopy Create free account
hub / github.com/amov-lab/Prometheus / plot

Method plot

Modules/slam/include/timer.h:32–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

30 }
31
32 void plot () {
33 stop();
34 float total_time = 0;
35 for (int32_t i=0; i<desc.size(); i++) {
36 float curr_time = getTimeDifferenceMilliseconds(time[i],time[i+1]);
37 total_time += curr_time;
38 std::cout.width(30);
39 std::cout << desc[i] << " ";
40 std::cout << std::fixed << std::setprecision(1) << std::setw(6);
41 std::cout << curr_time;
42 std::cout << " ms" << std::endl;
43 }
44 std::cout << "========================================" << std::endl;
45 std::cout << " Total time ";
46 std::cout << std::fixed << std::setprecision(1) << std::setw(6);
47 std::cout << total_time;
48 std::cout << " ms" << std::endl << std::endl;
49 }
50
51 void reset () {
52 desc.clear();

Callers 1

processMethod · 0.80

Calls 2

widthMethod · 0.80
sizeMethod · 0.45

Tested by

no test coverage detected