WARPXM v1.10.0
|
Classes | |
class | simulation |
Simulation base class. More... | |
Functions | |
def | recurse_remove_files (base_dir) |
def | format_walltime (t) |
def | load_configs (local_path=None, site_path='warpy_config.py') |
def | env_vars_to_str (args) |
Converts a dictionary of extra environment variables to a string that can be used on the command line. | |
def | replace_macros (macros, line) |
Replaces template macro vars in a single line. | |
def | write_git_info (rundir, git_repo) |
Writes git commit and working directory status information to text file in output directory. | |
def | setup_sim (category=None, local_path=None, site_path='warpy_config.py', input_file=None, sim=None, wxm_args=[], sim_param=None) |
Setups the simulation run directory. | |
def | run (category=None, local_path=None, site_path='warpy_config.py', input_file=None, sim=None, wxm_args=[], sim_param=None) |
runs a WARPXM simulation. | |
def | unique_h_acts_ (groups) |
def warpy.simulation.env_vars_to_str | ( | args | ) |
Converts a dictionary of extra environment variables to a string that can be used on the command line.
def warpy.simulation.format_walltime | ( | t | ) |
def warpy.simulation.load_configs | ( | local_path = None , |
|
site_path = 'warpy_config.py' |
|||
) |
def warpy.simulation.recurse_remove_files | ( | base_dir | ) |
def warpy.simulation.replace_macros | ( | macros, | |
line | |||
) |
Replaces template macro vars in a single line.
Syntax is similar to the one used by QtCreator. Available macros are in macros.
Can place a **:u** to convert the macro to upper case, and **:l** to convert to lower case. ex.: ProjectName:u% would expand to the project name in all caps.
macros | |
line |
def warpy.simulation.run | ( | category = None , |
|
local_path = None , |
|||
site_path = 'warpy_config.py' , |
|||
input_file = None , |
|||
sim = None , |
|||
wxm_args = [] , |
|||
sim_param = None |
|||
) |
runs a WARPXM simulation.
This may be either a pre-existing input file, or one to be generated by a given simulation object. Resolves parameters in the with the following priority (highest priority to lowest):
category | simulation category. Only used if sim is not None. |
local_path | path to the local config file, or None to not use any local config file. This is relative to the current working directory (if given a relative path). |
site_path | path to the site config file (if any). Path is relative to search the warpy install directory (if given a relative path). |
input_file | path of an input file to run. This is mutually exclusive to sim. |
sim | simulation to generate the input file from. This is mutually exclusive to input_file_path |
wxm_args | Extra arguments to pass to WARPXM |
def warpy.simulation.setup_sim | ( | category = None , |
|
local_path = None , |
|||
site_path = 'warpy_config.py' , |
|||
input_file = None , |
|||
sim = None , |
|||
wxm_args = [] , |
|||
sim_param = None |
|||
) |
Setups the simulation run directory.
This may be either a pre-existing input file, or one to be generated by a given simulation object. Resolves parameters in the with the following priority (highest priority to lowest):
category | simulation category. Only used if sim is not None. |
local_path | path to the local config file, or None to not use any local config file. This is relative to the current working directory (if given a relative path). |
site_path | path to the site config file (if any). Path is relative to search the warpy install directory (if given a relative path). |
input_file | path of an input file to run. This is mutually exclusive to sim. |
sim | simulation to generate the input file from. This is mutually exclusive to input_file_path |
wxm_args | Extra arguments to pass to WARPXM |
def warpy.simulation.unique_h_acts_ | ( | groups | ) |
def warpy.simulation.write_git_info | ( | rundir, | |
git_repo | |||
) |
Writes git commit and working directory status information to text file in output directory.
rundir | Output directory. |