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

Environment wind from ERA-5 #120

Open
gab1092 opened this issue May 23, 2022 · 2 comments
Open

Environment wind from ERA-5 #120

gab1092 opened this issue May 23, 2022 · 2 comments

Comments

@gab1092
Copy link

gab1092 commented May 23, 2022

Hello! I'm testing some configurations with different data sources, I was able to load data for the environment wind object from GFS, but I'm not able to load the data from ERA-5. The error message is ValueError: No compatible variable names found!
But when I used the same data for the wind movers, I could load the data without problem; any idea for loading the data as an environment variable?
Here is the code which I used.

wind_obj = GridWind.from_netCDF('/home/GNOME/ERA5/2015_2016.nc')
ValueError: No compatible variable names found!

for the movers, I could run without problems

file_wind='/home/GNOME/ERA5/2015_2016.nc'
w_mover=GridWindMover(file_wind)
model.movers += w_mover

Thank you!

@jay-hennen
Copy link
Contributor

The compatible variable names error happens when an environment object can not find compatible variables to use. That is to say, it simply could not find them. Passing a varnames = ['u_name', 'v_name'] kwarg would be enough for it to work.

What are your imports? I'm guessing you are using the legacy GridWindMover object (a self-contained mover), when only the new PyWindMover would use the GridWind environment object. If the GridWindMover could do the job though, that's good enough I suppose.

@gab1092
Copy link
Author

gab1092 commented May 27, 2022

Thank you! With your suggestion I could import the wind as environment object! However I need import as wind movers with GridWindMover because I can't use the wind_obj as a grid mover, but It's working.

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

2 participants