-
-
Notifications
You must be signed in to change notification settings - Fork 120
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
Model crash when setting baseline_spending=True #782
Comments
@martinholmer. I have replicated your error. We definitely test specifications of |
@jdebacker. I think @martinholmer has discovered a bug in the
I think at least one place where the steady-state code is wrong is in lines 521-524 of if:
...
else:
BQ = guesses[3:-1]
TR = guesses[-1]
factor = factor_ss
if p.baseline_spending:
TR = TR_ss
if not p.budget_balance and not p.baseline_spending:
Y = TR / p.alpha_T[-1] Otherwise lines 521-524 in
Given this error, I suspect that there is another place in the code where I have to make this change. Because it seems like the steady state is solving, but we have an accounting issue after the steady-state has solved. I am going to keep looking for this fix, but you know this case of And finally, after we find the guilty lines of code, we need to include some tests in the local set of tests that include the case in which |
The steady-state now solves using the code updates currently in PR #786 with the experiment @martinholmer is proposing above. I will take the draft status off that PR once I have ensured that the TPI accounts for this case correctly and I have added tests for this case.
|
@rickecon and @martinholmer This isn't a bug. The combination of parameter values, Note that in |
In issue #782, @jdebacker said:
Thanks for pointing this out. For the benefit of novice users of the model, it would be a good idea to tell users that the model considers this an illegal specification. The Notice that in my original comment in this issue #782, I did not assert that this was a bug. I simply reported the details of the model crash and asked among other things: "Did I make a mistake in specifying the OG-Core example run?" So, thank you for pointing out that the answer to that question is yes. |
Thanks @martinholmer and thanks @jdebacker. The rest of this discussion will take place in the thread for PR #786. |
I'm estimating just the steady-state equilibrium for a simple model specification that is not too different from the one in the
run_examples/run_ogcore_example.py
script.With the following specification, I get the steady-state solution in about two minutes:
But when I change
baseline_spending
to be True, OG-Core crashes with the following error traceback:Did I make a mistake in specifying the OG-Core example run?
Or is the logic associated with
baseline_spending
=True not being tested?Or is something else going on that I don't understand?
The text was updated successfully, but these errors were encountered: