1515
1616
1717def _as_view_item (obj ):
18- """Return None or a suitable iterable to build a _StepView ."""
18+ """Return None or a suitable iterable to build a _StepsView ."""
1919 try :
2020 iter (obj )
2121 return obj
@@ -327,7 +327,7 @@ def __getitem__(self, isnap):
327327 istep = self ._isteps .get (
328328 isnap , None if self ._all_isteps_known else UNDETERMINED )
329329 if istep is UNDETERMINED :
330- binfiles = self .sdat .binfiles_set (isnap )
330+ binfiles = self .sdat ._binfiles_set (isnap )
331331 if binfiles :
332332 istep = stagyyparsers .fields (binfiles .pop (), only_istep = True )
333333 else :
@@ -357,7 +357,7 @@ def __len__(self):
357357 rgx = re .compile (
358358 '^{}_([a-zA-Z]+)([0-9]{{5}})$' .format (out_stem ))
359359 fstems = set (fstem for fstem in phyvars .FIELD_FILES )
360- for fname in self .sdat .files :
360+ for fname in self .sdat ._files :
361361 match = rgx .match (fname .name )
362362 if match is not None and match .group (1 ) in fstems :
363363 self ._last = max (int (match .group (2 )), self ._last )
@@ -536,6 +536,7 @@ def __init__(self, path=None):
536536 steps (:class:`_Steps`): collection of time steps.
537537 snaps (:class:`_Snaps`): collection of snapshots.
538538 scales (:class:`_Scales`): dimensionful scaling factors.
539+ refstate (:class:`_Refstate`): reference state profiles.
539540 """
540541 if path is None :
541542 path = conf .core .path
@@ -657,7 +658,7 @@ def rtimes(self):
657658 return self ._rprof_and_times [1 ]
658659
659660 @property
660- def files (self ):
661+ def _files (self ):
661662 """Set of found binary files output by StagYY."""
662663 if self ._rundir ['ls' ] is UNDETERMINED :
663664 out_stem = pathlib .Path (self .par ['ioin' ]['output_file_stem' ] + '_' )
@@ -778,7 +779,7 @@ def filename(self, fname, timestep=None, suffix='', force_legacy=False):
778779 fpath = self .path / fpath
779780 return fpath
780781
781- def binfiles_set (self , isnap ):
782+ def _binfiles_set (self , isnap ):
782783 """Set of existing binary files at a given snap.
783784
784785 Args:
@@ -789,4 +790,4 @@ def binfiles_set(self, isnap):
789790 """
790791 possible_files = set (self .filename (fstem , isnap , force_legacy = True )
791792 for fstem in phyvars .FIELD_FILES )
792- return possible_files & self .files
793+ return possible_files & self ._files
0 commit comments