Skip to content
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

questions regarding min(1,exp(-g/t))*log2(n) #19

Closed
aaronlws95 opened this issue Dec 1, 2017 · 2 comments
Closed

questions regarding min(1,exp(-g/t))*log2(n) #19

aaronlws95 opened this issue Dec 1, 2017 · 2 comments

Comments

@aaronlws95
Copy link

Hi, isn't exp(-g/t) always going to be less than 1 as long as g/t is positive. Why is the min necessary? Also in the code:
capture
I noticed that g/t is less than 1 most of the time so it never does the exponential.

@nicholzk
Copy link

nicholzk commented Dec 4, 2017

I believe that the code intends to impose a penalty of exp(-g/t) for programs that exceed the time budget on the score ( g/t > 1), else score is simply log2(n). The mathematical formulation is certainly wrong, but I am not sure if there is a simple way to express this logic.

@m8pple
Copy link
Contributor

m8pple commented Dec 4, 2017

My intention was as stated by @nicholzk says:

  • The score is log2(n) if within budget.
  • The score is log2(n) * exp(-g/t) if the budget is exceeded.

So the cost function I was expecting was something like this:
image

So there is quite a big penalty for going over the time budget, with a bit of
a cliff, but still some reward. Originally I had min(1,exp(-g/t)/exp(-1)), but
then decided to penalise exceeding the budget a bit more - as @nichlzk says,
there isn't an elegant way of expressing that, and I seem not to have noticed
that the maths no longer follows the function.

Regardig @aaronlws95's point about g/t being less than 1 most of the time: that is because
the default prediction of n is extremely conservative. You'll want to try to make a better
prediction of n, so that you can get reasonably close to the g/t=1

@m8pple m8pple closed this as completed in e8b5072 Dec 4, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants