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

VARIABLE ERROR #20

Open
mhwahla opened this issue Oct 11, 2023 · 4 comments
Open

VARIABLE ERROR #20

mhwahla opened this issue Oct 11, 2023 · 4 comments

Comments

@mhwahla
Copy link

mhwahla commented Oct 11, 2023

Hello @daquinterop I hope you are doing great, we have got this error while creating weather instance, can you give us hint on this ? thanks

TypeError Traceback (most recent call last)
~\AppData\Local\Temp\ipykernel_7804\2970603011.py in
7 'Cumulative precipitation(mm)': 'RAIN',
8 'Cumulative solar radiation(MJ/m2)': 'SRAD',
----> 9 'Average relative humidity(%)': 'RHUM'
10 }
11 )

TypeError: init() got an unexpected keyword argument 'variables'
image

apologies if its very basic , we are super new to this.

Create a WeatherData instance

WTH_DATA = Weather(
dt,
variables={
'Absolute maximum temperature (°C)': 'TMAX',
'Absolute minimum temperature (°C)': 'TMIN',
'Cumulative precipitation(mm)': 'RAIN',
'Cumulative solar radiation(MJ/m2)': 'SRAD',
'Average relative humidity(%)': 'RHUM'
}
)

Write a weather data file

dt.to_csv('weather.csv')

# Create a WeatherStation instance

wth = WeatherStation(
WTH_DATA,
{
'ELEV': float(X_data['ELEV'].values[0]),
'LAT': float(X_data['LAT'].values[0]),
'LON': float(X_data['LON'].values[0]),
'INSI': X_data['INSI'].values[0]
}
)

thanks

@daquinterop
Copy link
Owner

Hi. Quick question, what version of the library are you using?

@mhwahla
Copy link
Author

mhwahla commented Oct 11, 2023

Heyy its 2.1.1

image

@mhwahla
Copy link
Author

mhwahla commented Oct 12, 2023

hello @daquinterop I hope you had great day.
changed the version of
error persists even with this older version.
image

@daquinterop
Copy link
Owner

daquinterop commented Oct 12, 2023 via email

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