14#ifndef _PROGRESS_MONITOR_
15#define _PROGRESS_MONITOR_
28namespace chc = std::chrono;
29typedef chc::duration<float, std::milli>
float_ms;
31#define TOTAL_PERCENTAGE 100.0
32#define CHARACTER_WIDTH_PERCENTAGE 4
33#define TERMINAL_WIDTH 120
48 explicit ProgressMonitor(
size_t fr_total,
bool b_bar =
true,
float report_interval = 250.0, std::ostream &out = std::cerr);
57 float report_interval;
58 std::atomic<int> fr_count_a;
60 chc::time_point<chc::high_resolution_clock> time_stamp;
64 const char *unit_space;
66 void Report(
unsigned long idx,
float print_val);
chc::duration< float, std::milli > float_ms
std::atomic< bool > report_set
std::atomic< size_t > fr_count_i
static const int DEFAULT_WIDTH
ProgressMonitor & operator++()
std::atomic< size_t > fr_count
std::atomic< bool > report_set_public