File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -266,15 +266,17 @@ def __post_init__(self):
266266 'cached on the head_node. This can take a long time and might be '
267267 'worth doing as an independent preprocessing step instead.'
268268 )
269- if self . head_node and not all (
270- ( fp is None or os . path . exists ( fp ) )
271- for fp in self . get_exo_cache_files ( model )
272- ) :
269+ cache_check = any (
270+ 'cache_dir' in v for v in self . exo_handler_kwargs . values ( )
271+ )
272+ if self . head_node and cache_check :
273273 logger .warning (msg )
274274 warn (msg )
275275 _ = self .timer (self .load_exo_data , log = True )(model )
276276
277277 if not self .head_node :
278+ # This will either load cache files created on the head node or
279+ # directly load the exogenous data if no cache is being used.
278280 hr_shape = self .hr_lat_lon .shape [:- 1 ]
279281 self .gids = np .arange (np .prod (hr_shape )).reshape (hr_shape )
280282 self .exo_data = self .timer (self .load_exo_data , log = True )(model )
You can’t perform that action at this time.
0 commit comments