-
Notifications
You must be signed in to change notification settings - Fork 14
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
[FEATURE] Set Default timeindex in edisgo.set_time_series_active_power_predefined #456
Labels
Comments
khelfen
added a commit
that referenced
this issue
Feb 17, 2025
- Automatically set `EDisGo.TimeSeries.timeindex` to the default year of the database if it is empty. # - Added a logger warning to inform users about the default behavior and recommend setting the `timeindex` explicitly using `EDisGo.set_timeindex()`. # On branch feature/#456-feature-set-default-timeindex-in-edisgoset_time_series_active_power_predefined
12 tasks
khelfen
added a commit
that referenced
this issue
Feb 17, 2025
…-timeindex-in-edisgoset_time_series_active_power_predefined Fix missing timeindex in set_time_series_active_power_predefined
khelfen
added a commit
that referenced
this issue
Feb 17, 2025
…-timeindex-in-edisgoset_time_series_active_power_predefined Overwrite timeindex if given timeindex differs from existing timeinde…
khelfen
added a commit
that referenced
this issue
Feb 17, 2025
…-timeindex-in-edisgoset_time_series_active_power_predefined add logging and correct timeindex variable handling
khelfen
added a commit
that referenced
this issue
Feb 19, 2025
…-timeindex-in-edisgoset_time_series_active_power_predefined Feature/#456 feature set default timeindex in edisgoset time series active power predefined
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
Currently, when using
edisgo.set_time_series_active_power_predefined
, if thetimeindex
isNone
within anEdisgo.Timeseries
object and is not explicitly provided, the module imports data for the default year of the database. However, sinceedisgo.set_time_series_active_power_predefined
does not set thetimeindex
, the resultingEdisgo.Timeseries
object remains empty. This can cause confusion and unexpected behavior for users. Currently there is only a warning iftimeindex
is empty, but this does not solve the problem automatically and could disrupt workflows.Describe the solution you'd like
If
Edisgo.Timeseries.timeindex
is empty, it should automatically be set to the default year of the database before importing data. This ensures that the imported time series data is correctly linked to a validtimeindex
, preventing an emptyEdisgo.Timeseries
object.This could be done here:
eDisGo/edisgo/edisgo.py
Lines 559 to 566 in a0e83c9
Describe alternatives you've considered
timeindex
before callingedisgo.set_time_series_active_power_predefined
, but this adds an extra step that could be handled internally.Additional context
This feature would improve the robustness of the module by preventing unexpected empty time series results. It would also align with the existing behavior of importing data for the default database year.
The text was updated successfully, but these errors were encountered: