21#include <sys/syslog.h>
24#include <sys/resource.h>
38 Timer(
char const * prefix,
size_t interval = 100,
int loglevel = LOG_INFO);
47 std::string
const &
stop(
double * seconds);
50 std::string
const &
stop();
53 std::string
const itsPrefix;
54 size_t const itsInterval;
55 int const itsLogLevel;
58 std::chrono::time_point<std::chrono::steady_clock> itsStartTime;
59 double itsSecs, itsMinSecs, itsMaxSecs;
62 rusage itsStartRusage;
63 std::chrono::time_point<std::chrono::steady_clock> itsStartTimeForCpu;
80 std::string
stop(
double * seconds);
86 std::string
const itsPrefix;
87 std::chrono::time_point<std::chrono::steady_clock> itsStartTime;
Simple one-shot timer class.
void start()
Start a time measurement period.
std::string stop()
Same as the other signature of stop() except does not provide seconds, for python bindings.
std::string const & stop()
Same as the other signature of stop() except does not provide seconds, for python bindings.
void start()
Start a time measurement period.
Main namespace for all JeVois classes and functions.