You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I compared the 2026 SLP G0 profile to one I obtained from my local DSO (Stromnetz Berlin) and saw that e.g. January 1st and Easter are not modelled the same.
See the screenshots where I compare the two days with the profile from DSO (blue) with the library (orange).
Do you think, we should issue a warning if none are given, or alternatively do not just assume no holidays as a default. In the latter case, you could still give an empty list for no holidays, but cannot forget to give them.
Ah, okay. Indeed, this one is then also partly on (lazy) me! Didn't see the holidays argument in the ElecSlp constructor.
I think that a list of at least the national holidays (January 1st, Easter, May 1st, Himmelfahrt, October 3rd, Christmas) should be provided by default. I suppose that would make the default "more right" for most users, wouldn't it?
I have solved it for me now with the holidays package. Given that its so convinient you could consider integrating this to get the German holidays per default for each year and maybe even asking for the local state string (like "BE" for Berlin).
I actually dislike having a default that is silently wrong. (We have one now, though.) Thus, I can imagine the following options (just taking one profile for the example):
BDEW25Profile(timeindex) warns that no holidays are given, or
BDEW25Profile(timeindex) fails.
In case 1, either no holidays or another default could be assumed. (An example might be national holidays in Germany, it's BDEW after all.)
Independent from the decision between 1 and 2, it might be made possible to provide a regional code instead of a list. (If a default set of holidays is taken, of course it makes no sense to not expose this option.)
I would prefer 1. with the warning and a default of the German national holidays as as you mentioned it is Germany after all.
So the ones as returned by the holidays library for Germany (here for 2026):
Maybe you could allow for either a list or a string, which is stilly pythonic enough for my taste.
If it is a list of datetimes, then use them, if it is a string allow for the state strings for local holidays as provided by holidays library (States: BB (Brandenburg), BE (Berlin), BW (Baden-Württemberg), BY (Bayern), HB (Bremen), HE (Hessen), HH (Hamburg), MV (Mecklenburg-Vorpommern), NI (Niedersachsen), NW (Nordrhein-Westfalen), RP (Rheinland-Pfalz), SH (Schleswig-Holstein), SL (Saarland), SN (Sachsen), ST (Sachsen-Anhalt), TH (Thüringen); cities: Augsburg)
Activity
p-snft commentedon Jan 9, 2026
Thanks for bringing this up. I see that the documentation should be improved on this point: As holidays are regional, you need to provide them as an argument. Please see https://github.com/oemof/demandlib/blob/v0.2.2/examples/bdew_slp25.py for an example.
Do you think, we should issue a warning if none are given, or alternatively do not just assume no holidays as a default. In the latter case, you could still give an empty list for no holidays, but cannot forget to give them.
marcus-voss commentedon Jan 9, 2026
Ah, okay. Indeed, this one is then also partly on (lazy) me! Didn't see the holidays argument in the ElecSlp constructor.
I think that a list of at least the national holidays (January 1st, Easter, May 1st, Himmelfahrt, October 3rd, Christmas) should be provided by default. I suppose that would make the default "more right" for most users, wouldn't it?
marcus-voss commentedon Jan 9, 2026
I have solved it for me now with the holidays package. Given that its so convinient you could consider integrating this to get the German holidays per default for each year and maybe even asking for the local state string (like "BE" for Berlin).
p-snft commentedon Jan 9, 2026
I actually dislike having a default that is silently wrong. (We have one now, though.) Thus, I can imagine the following options (just taking one profile for the example):
BDEW25Profile(timeindex)warns that no holidays are given, orBDEW25Profile(timeindex)fails.In case 1, either no holidays or another default could be assumed. (An example might be national holidays in Germany, it's BDEW after all.)
Independent from the decision between 1 and 2, it might be made possible to provide a regional code instead of a list. (If a default set of holidays is taken, of course it makes no sense to not expose this option.)
marcus-voss commentedon Jan 11, 2026
I would prefer 1. with the warning and a default of the German national holidays as as you mentioned it is Germany after all.
So the ones as returned by the holidays library for Germany (here for 2026):
{datetime.date(2026, 1, 1): 'Neujahr', datetime.date(2026, 4, 3): 'Karfreitag', datetime.date(2026, 4, 6): 'Ostermontag', datetime.date(2026, 5, 1): 'Erster Mai', datetime.date(2026, 5, 14): 'Christi Himmelfahrt', datetime.date(2026, 5, 25): 'Pfingstmontag', datetime.date(2026, 10, 3): 'Tag der Deutschen Einheit', datetime.date(2026, 12, 25): 'Erster Weihnachtstag', datetime.date(2026, 12, 26): 'Zweiter Weihnachtstag'}
Maybe you could allow for either a list or a string, which is stilly pythonic enough for my taste.
If it is a list of datetimes, then use them, if it is a string allow for the state strings for local holidays as provided by holidays library (States: BB (Brandenburg), BE (Berlin), BW (Baden-Württemberg), BY (Bayern), HB (Bremen), HE (Hessen), HH (Hamburg), MV (Mecklenburg-Vorpommern), NI (Niedersachsen), NW (Nordrhein-Westfalen), RP (Rheinland-Pfalz), SH (Schleswig-Holstein), SL (Saarland), SN (Sachsen), ST (Sachsen-Anhalt), TH (Thüringen); cities: Augsburg)
Warn when a profile is created without holidays
Merge pull request #100 from asystemoffields/warn-when-no-holidays