File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -519,22 +519,28 @@ class StagyyData:
519519
520520 """Generic lazy interface to StagYY output data."""
521521
522- def __init__ (self , path ):
522+ def __init__ (self , path = None ):
523523 """Initialization of instances:
524524
525525 Args:
526526 path (pathlike): path of the StagYY run. It can either be the path
527527 of the directory containing the par file, or the path of the
528528 par file. If the path given is a directory, the path of the par
529- file is assumed to be path/par.
529+ file is assumed to be path/par. If no path is given (or None)
530+ it is set to ``conf.core.path``.
530531
531532 Attributes:
532533 steps (:class:`_Steps`): collection of time steps.
533534 snaps (:class:`_Snaps`): collection of snapshots.
534535 scales (:class:`_Scales`): dimensionful scaling factors.
535536 collected_fields (list of (int, str)): list of fields currently in
536537 memory, described by istep and field name.
538+
539+ Other Parameters:
540+ conf.core.path: the default path.
537541 """
542+ if path is None :
543+ path = conf .core .path
538544 runpath = pathlib .Path (path )
539545 if runpath .is_file ():
540546 parname = runpath .name
You can’t perform that action at this time.
0 commit comments