snek5000#
API reference
Sub-packages
resources for building |
|
Manage outputs |
|
Solver framework |
|
Miscellaneous utilities |
Modules
Cluster utilities |
|
Calculate physical constants |
|
Information classes |
|
Logging A logger instance (variable logger). |
|
IPython magic extensions |
|
Snakemake interface |
|
Operators |
|
Runtime parameters Scripting interface for Nek5000 parameter file. |
|
Utility for configuration files |
Module Attributes
|
Get status of a simulation run by verifying its contents. |
|
Load params and Simul for a restart. |
Functions
Path of Nek5000 source code. |
|
|
Fetches path of a file from subpackage |
|
Loads a simulation |
- snek5000.get_snek_resource(resource_name)[source]#
Fetches path of a file from subpackage
snek5000.resources
.- Parameters
resource_name (str) – Name of a file packaged in
snek5000.resources
- snek5000.get_status(path_dir, session_id=None, verbose=False)[source]#
Alias for
snek5000.util.restart.get_status()
- snek5000.load(path_dir='.', session_id=None, reader=True)#
Alias for
load_simul()
- snek5000.load_for_restart(path_dir='.', use_start_from=None, use_checkpoint=None, session_id=None, verify_contents=True, new_dir_results=False, only_check=False)[source]#
Alias for
snek5000.util.restart.load_for_restart()
- snek5000.load_params(path_dir='.')[source]#
Load a
snek5000.params.Parameters
instance from path_dir.- Parameters
path_dir (str or path-like) – Path to a simulation directory.
- Returns
params
- Return type
- snek5000.load_simul(path_dir='.', session_id=None, reader=True)[source]#
Loads a simulation
Todo
Now only the parameters are loaded. Load state too.
- Parameters
path_dir (str or path-like) – Path to a directory containing a simulation. If not provided the current directory is used.
session_id (int) – Indicate which session directory should be used to set
sim.output.path_session
. If not specified it would default to the session_id and path_session values last recorded in the params_simul.xml filereader (bool or str) – By default (reader=True) invokes
sim.output.phys_fields.init_reader()
. If a string is provided, it is passed ontosim.output.phys_fields.change_reader(reader)
.
Hint
An common use case of
session_id
parameter is to load field files from old sessions using thesim.output.get_field_file
method