BenchmarkTools.jl icon indicating copy to clipboard operation
BenchmarkTools.jl copied to clipboard

define ratio and/or `/` for Trials

Open StefanKarpinski opened this issue 7 years ago • 1 comments

This would compute the ratio of all the relevant metrics:

  • memory estimate
  • allocs estimate
  • minimum time
  • median time
  • mean time
  • maximum time

Would it make sense to try to put some kind of confidence interval on the time based on all of the samples?

StefanKarpinski avatar Dec 12 '16 16:12 StefanKarpinski

Would it make sense to try to put some kind of confidence interval on the time based on all of the samples?

This is quite tricky to do correctly in the realm of non-i.i.d. statistics, which is the world benchmark timings generally live in. If you do the "usual calculations", you'll end up getting junk results a lot of the time.

A while ago, I developed a working prototype of a subsampling method for calculating p-values (which could be modified to compute confidence intervals), but it relies on getting the correct normalization coefficient for the test statistic + timing distribution (unique to each benchmark). IIRC, it worked decently on my test benchmark data, but only if I manually tuned the normalization coefficient for any given benchmark. There are methods out there for automatically estimating this coefficient, but I never got around to implementing them.

jrevels avatar Dec 12 '16 21:12 jrevels