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

SciPy2019-ModuleNotFound Error notebook #39

Closed
thedatalass opened this issue Jul 13, 2019 · 12 comments
Closed

SciPy2019-ModuleNotFound Error notebook #39

thedatalass opened this issue Jul 13, 2019 · 12 comments
Assignees
Labels
bug Something isn't working priority:medium

Comments

@thedatalass
Copy link

thedatalass commented Jul 13, 2019

Lifecycle Model Example

# Initial imports and notebook setup, click arrow to show

import HARK.ConsumptionSaving.ConsIndShockModel as Model        # The consumption-saving micro model
import HARK.SolvingMicroDSOPs.EstimationParameters as Params    # Parameters for the consumer type and the estimation
from HARK.utilities import plotFuncsDer, plotFuncs              # Some tools

import numpy as np
---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-1-d26969f29899> in <module>
      2 
      3 import HARK.ConsumptionSaving.ConsIndShockModel as Model        # The consumption-saving micro model
----> 4 import HARK.SolvingMicroDSOPs.EstimationParameters as Params    # Parameters for the consumer type and the estimation
      5 from HARK.utilities import plotFuncsDer, plotFuncs              # Some tools
      6 

ModuleNotFoundError: No module named 'HARK.SolvingMicroDSOPs.EstimationParameters'
---------------------------------------------------------------------------
NameError                                 Traceback (most recent call last)
<ipython-input-2-0734f7422d0c> in <module>
      1 # Set up default values for CRRA, DiscFac, and simulation variables in the dictionary
----> 2 Params.init_consumer_objects["CRRA"]= 2.00            # Default coefficient of relative risk aversion (rho)
      3 Params.init_consumer_objects["DiscFac"]= 0.97         # Default intertemporal discount factor (beta)
      4 Params.init_consumer_objects["PermGroFacAgg"]= 1.0    # Aggregate permanent income growth factor
      5 Params.init_consumer_objects["aNrmInitMean"]= -10.0   # Mean of log initial assets

NameError: name 'Params' is not defined
@TamerKhraisha
Copy link

I'm seeing the same problem

@llorracc llorracc added priority:medium bug Something isn't working and removed priority:medium labels Jul 19, 2019
@mnwhite
Copy link
Collaborator

mnwhite commented Jul 19, 2019 via email

@mnwhite
Copy link
Collaborator

mnwhite commented Jul 19, 2019 via email

@shaunagm
Copy link
Contributor

Has anyone submitted a PR to change this reference? If it's just HARK.SolvingMicroDSOPs.EstimationParameters I can do it, but if other things got moved around it's probably better if someone else does it.

@shaunagm
Copy link
Contributor

Actually, probably the thing to do for nearly all the notebooks for now, except those that need 0.10.1, is to add a !pip install econ-ark==0.9.1 at the top of them. I'll keep trying to find if there's a less cumbersome way to pin different notebooks to different versions of a requirement.

@shaunagm
Copy link
Contributor

Weirdly, on mybinder this works by default and changing it to use the new folder structure breaks it. Which is weird, because AFAIK mybinder uses the version of econ-ark in requirements.txt, which is 0.10.1, which has the new structure - but mybinder is behaving as if it's using 0.9.1. But maybe (probably!) I'm misunderstanding how mybinder.org works.

@shaunagm
Copy link
Contributor

Okay, I can't reproduce the "mybinder is working and that's weird" issue - it's breaking now as would be expected. And I don't see any other reference to SolvingMicroDSOPs in any of the other notebooks. So we just need to make the minor change specified here, which I will handle.

@llorracc
Copy link
Collaborator

dev3 release fixed this problem for my students in Budapest

@shaunagm
Copy link
Contributor

To confirm, the notebook Lifecycle Model Example worked fine for your students in Budapest? Were they running from AlphaCruncher caching mybinder, or something else? Because I looked at this notebook on mybinder.org not an hour ago and it was broken.

@llorracc
Copy link
Collaborator

llorracc commented Jul 24, 2019

In Budapest we are only using a few notebooks -- not including the LifeCycleModelExample. So I haven't tested it.

I don't remember what (if anything) the Alphacruncher people said about this particular notebook.

@shaunagm
Copy link
Contributor

This is an issue for a different error, the one you are referring to is #43 and is now closed.

@MridulS
Copy link
Member

MridulS commented Oct 31, 2019

tested this notebook, fixed in #54

@MridulS MridulS closed this as completed Oct 31, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working priority:medium
Projects
None yet
Development

No branches or pull requests

6 participants