We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 84ad52d commit de05597Copy full SHA for de05597
sup3r/preprocessing/utilities.py
@@ -169,10 +169,10 @@ def get_date_range_kwargs(time_index):
169
nominal_ti = pd.date_range(**kwargs)
170
unique_freqs = set(np.diff(time_index))
171
172
- if unique_freqs > 1 and len(nominal_ti) > len(time_index):
+ if len(unique_freqs) > 1 and len(nominal_ti) > len(time_index):
173
kwargs['drop_leap'] = True
174
175
- elif unique_freqs > 1:
+ elif len(unique_freqs) > 1:
176
msg = (
177
f'Got more than one unique frequency ({unique_freqs}) for time '
178
f'index: {time_index}. This can occur if some input variables '
0 commit comments