MPQC
3.0.0-alpha
|
PsiExEnv specifies a Psi execution environment. More...
#include <chemistry/qc/psi/psiexenv.h>
Public Member Functions | |
PsiExEnv (const Ref< KeyVal > &) | |
A KeyVal constructor is used to generate a PsiExEnv object from the input. More... | |
Ref< PsiInput > | psi_input () const |
Returns the PsiInput object which PsiExEnv uses. | |
Ref< PsiFile11 > | psi_file11 () const |
Returns the PsiFile11 object which PsiExEnv uses. | |
Ref< PsiInput > | get_psi_input () |
Creates the PsiInput object which PsiExEnv uses. | |
Ref< PsiFile11 > | get_psi_file11 () |
Creates the PsiFile11 object which PsiExEnv uses. | |
void | run_psi (bool skip_input=false) |
Executes Psi input+driver. More... | |
void | run_psi_module (const char *module, const std::vector< std::string > &args=std::vector< std::string >()) |
Executes a Psi module using a system call. Throws if psi fails. | |
void | run_psiclean (bool fullclean=true) |
cleans Psi scratch files using the same approach as psiclean. More... | |
const std::string & | get_cwd () const |
Returns current working directory. | |
const std::string & | get_fileprefix () const |
Returns the Psi file prefix. | |
int | get_nscratch () const |
Returns the number of scratch locations. | |
const std::string & | get_scratch (int i) const |
Returns the ith scratch location. | |
psi::PSIO & | psio () |
Returns an instance of psi::PSIO. | |
psi::Chkpt & | chkpt () |
Returns an instance of psi::Chkpt. | |
void | print (std::ostream &o=ExEnv::out0()) const |
Print the object. | |
void | keep_output () |
this will cause psi driver to keep the output next time it's run. Must be called every time to prevent the output file from truncation | |
Public Member Functions inherited from sc::DescribedClass | |
DescribedClass (const DescribedClass &) | |
DescribedClass & | operator= (const DescribedClass &) |
ClassDesc * | class_desc () const MPQC__NOEXCEPT |
This returns the unique pointer to the ClassDesc corresponding to the given type_info object. More... | |
const char * | class_name () const |
Return the name of the object's exact type. | |
int | class_version () const |
Return the version of the class. | |
Ref< DescribedClass > | ref () |
Return this object wrapped up in a Ref smart pointer. More... | |
Public Member Functions inherited from sc::RefCount | |
size_t | identifier () const |
Return the unique identifier for this object that can be compared for different objects of different types. More... | |
int | lock_ptr () const |
Lock this object. | |
int | unlock_ptr () const |
Unlock this object. | |
void | use_locks (bool inVal) |
start and stop using locks on this object | |
refcount_t | nreference () const |
Return the reference count. | |
refcount_t | reference () |
Increment the reference count and return the new count. | |
refcount_t | dereference () |
Decrement the reference count and return the new count. | |
int | managed () const |
void | unmanage () |
Turn off the reference counting mechanism for this object. More... | |
Static Public Member Functions | |
static const Ref< PsiExEnv > & | get_default_instance () |
Additional Inherited Members | |
Protected Member Functions inherited from sc::RefCount | |
RefCount (const RefCount &) | |
RefCount & | operator= (const RefCount &) |
PsiExEnv specifies a Psi execution environment.
A KeyVal constructor is used to generate a PsiExEnv object from the input.
The full list of keywords that are accepted is below.
Keyword | Type | Default | Description |
cwd | string | . | the current working directory (small Psi files will be written here) |
fileprefix | string | filename.psi<td>the name prefix used for scratch files produced by Psi | |
stdout | string | fileprefix.stdout<td>the file to which Psi standard output will be written | |
stderr | string | fileprefix.stderr<td>the file to which Psi standard error will be written | |
scratch | array of strings | [ <ConsumableResources::disk_location()> ] | the location to which large scratch files will be written |
In addition, the location of Psi executables can be overridden by setting environmental variable PSIBIN
to the desired value. By default, Psi executables in the location specified with the –with-psi
configure script option will be used.
void sc::PsiExEnv::run_psi | ( | bool | skip_input = false | ) |
Executes Psi input+driver.
skip_input | whether to skip running "input" module. The default is false. |
void sc::PsiExEnv::run_psiclean | ( | bool | fullclean = true | ) |
cleans Psi scratch files using the same approach as psiclean.
fullclean | if set to true, clean out all files including the checkpoint file |