Skip to content

Commit

Permalink
improve Stat
Browse files Browse the repository at this point in the history
  • Loading branch information
qddyy committed Dec 21, 2024
1 parent e9ade53 commit 2fec513
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions inst/include/pmt/progress.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,9 @@ template <bool progress>
class Stat {
public:
Stat(R_xlen_t statistic_size = 1) :
_progress_i(0),
_progress_every(2),
_statistic_size(statistic_size) { }
_statistic_size(statistic_size),
_progress_every(0),
_progress_i(0) { }

template <typename T>
void init_statistic(T& update)
Expand Down Expand Up @@ -79,15 +79,15 @@ class Stat {
private:
RObject _statistic;

R_xlen_t _statistic_size;

NumericVector _statistic_buffer;

R_xlen_t _buffer_i;
R_xlen_t _buffer_size;
R_xlen_t _buffer_i;

R_xlen_t _progress_i;
R_xlen_t _progress_every;

R_xlen_t _statistic_size;
R_xlen_t _progress_i;

void _init_statistic_buffer(double n, R_xlen_t size)
{
Expand Down

0 comments on commit 2fec513

Please sign in to comment.