Skip to content

Commit

Permalink
Fix buffer size calculation in TDigest
Browse files Browse the repository at this point in the history
  • Loading branch information
tdcmeehan committed Mar 11, 2022
1 parent 372956c commit b21d4fd
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ private TDigest(double compression)
this.compression = 2 * this.publicCompression;

// having a big buffer is good for speed
this.maxBufferSize = 5 * (int) ceil(this.publicCompression + sizeFudge);
this.maxBufferSize = 5 * (int) ceil(this.compression + sizeFudge);
this.maxCentroidCount = (int) ceil(this.compression + sizeFudge);

this.weight = new double[1];
Expand Down

0 comments on commit b21d4fd

Please sign in to comment.