Fix high duration bucket starting time
Given 3600 bucket size, high duration bucket start times don't end with 0s where they should.
class Histogram {
public:
Histogram(std::chrono::seconds bucket_size);
// iterator stuff, per bucket
};
// class?
struct Bucket {
int count;
std::chrono::seconds low, middle, high;
operator int() const; // count
};
random_access_range
and sized_range
?
https://github.com/ericniebler/range-v3/blob/master/include/range/v3/range/concepts.hpp
We might need a transform iterator to wrap std::*map
s iterator as Histogram
.
Replace https://gitlab.com/signal9/angonoka/-/blob/development/src/predict.h#L26-31 with the new class.
Edited by Andrew