@@ -34,6 +34,7 @@ def __init__(
3434 linear_encoder : dict = None ,
3535 prefix : str = None ,
3636 window_len : int = 12 ,
37+ fixed_window : bool = False ,
3738 requires_norm : bool = True ,
3839 return_masks : bool = False ,
3940 clouds : bool = True ,
@@ -81,6 +82,9 @@ def __init__(
8182 over the data. E.g. if `window_len` = 6 and `group_freq` = '1M', then
8283 a 6-month rolling window will be applied and each batch will contain
8384 6 months of training data and the corresponding label.
85+ fixed_window: boolean, default False
86+ If True, then a fixed window including months 4 (April) to 9 (September) is used
87+ instead of a rolling one.
8488 requires_norm: boolean, default True
8589 If True, then it normalizes the dataset to [0, 1] range.
8690 return_masks: boolean, default False
@@ -126,6 +130,7 @@ def __init__(
126130 self .linear_encoder = linear_encoder
127131 self .saved_medians = saved_medians
128132 self .window_len = window_len
133+ self .fixed_window = fixed_window
129134 self .requires_norm = requires_norm
130135 self .return_masks = return_masks
131136 self .clouds = clouds
@@ -190,6 +195,7 @@ def setup(self, stage=None):
190195 linear_encoder = self .linear_encoder ,
191196 saved_medians = self .saved_medians ,
192197 window_len = self .window_len ,
198+ fixed_window = self .fixed_window ,
193199 requires_norm = self .requires_norm ,
194200 return_masks = self .return_masks ,
195201 clouds = self .clouds ,
@@ -211,6 +217,7 @@ def setup(self, stage=None):
211217 linear_encoder = self .linear_encoder ,
212218 saved_medians = self .saved_medians ,
213219 window_len = self .window_len ,
220+ fixed_window = self .fixed_window ,
214221 requires_norm = self .requires_norm ,
215222 return_masks = self .return_masks ,
216223 clouds = self .clouds ,
@@ -236,6 +243,7 @@ def setup(self, stage=None):
236243 linear_encoder = self .linear_encoder ,
237244 saved_medians = self .saved_medians ,
238245 window_len = self .window_len ,
246+ fixed_window = self .fixed_window ,
239247 requires_norm = self .requires_norm ,
240248 return_masks = self .return_masks ,
241249 clouds = self .clouds ,
0 commit comments