get_hg_checksum([strict]) | Return a string of the form <rev>_<checksum> where <rev> is the local revision number and <checksum> is the checksum of the current revision. |
run_cmd() | Return the run command for running python with this module as the |
get_pip_requirements() | Return the pip requirements file as a string. |
Running Programs
This module is intended to be used to manage important runs that generate data for a paper, etc.
For interactive use, start python as follows:
python -im mmf.utils.run
If you need to run a script, then use this module as the startup file with one of the following commands:
PYTHONSTARTUP=path_to_mmf/mmf/utils/run.py python file.py
PYTHONSTARTUP=path_to_mmf/mmf/utils/run.py python -c "import blah;..."
To find the full path for the previous commands, run:
python -c"import sys;sys._pymmf_no_init=True;import mmf;print mmf.run_cmd()"
This can be aliased for easy use.
The aim of this module is reproducibility:
Return a string of the form <rev>_<checksum> where <rev> is the local revision number and <checksum> is the checksum of the current revision. (Note: <rev> is not unique and may vary from repository to repository, but provides a simple chronological ordering for runs that is not intuitively deducible from the <checksum>.)
Parameters : | strict : bool
|
---|