-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No max operation in formulas #797
Conversation
src/correct-round.rkt
Outdated
(define x (first srcs)) | ||
(define y (second srcs)) | ||
|
||
(define x-exp (ival-max-log2-approx x)) | ||
(define y-exp (ival-max-log2-approx y)) | ||
(define out-exp (ival-min-log2-approx output)) | ||
|
||
(make-list 2 (max 0 (- (+ x-exp y-exp) (* 2 (max x-exp y-exp)) out-exp)))] | ||
(make-list 2 (+ (- (+ x-exp y-exp) (* 2 (min x-exp y-exp)) out-exp) 1))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one was tricky. Turned out that I was over-approximating sum of logs, when it actually had to be under-approximated since we subtract this value. The overall exponent will be over-approximated with this change. Previously it was not enough
I've already reviewed this, if the nightly is good just merge it. |
And nightly looks great, just merge it. |
This branch introduces a change to the tuning formulas.
max
operation was removed and now exponents can be negative as well.Nevertheless, the final precision can not be less than
*base-tuning-bits*
, which is set to 73.This feature saves some precision during sampling and localize when number of iteration > 0.