/** \page mpqcrunning Running MPQC This chapter explains how to run MPQC in a variety of environments. The first two sections give general information on running MPQC:
cd mpqc/lib tar cvf ../sclib.tar basis atominfo.kvThen transfer sclib.tar to the machine on which you want to run MPQC and do something like
mkdir ~/sclib cd ~/sclib tar xvf ../sclib.tar setenv SCLIBDIR ~/sclibThe setenv command is specific to the C-shell. You will need to do what is appropriate for your shell. The other three keywords specify objects. This is done by giving a mini ParsedKeyVal input in a string. The object is anonymous, that is, no keyword is associated with it. Here is an example:
setenv MESSAGEGRP "\section mpqcshmem Shared Memory Multiprocessor with SysV IPC By default, MPQC will run on only one CPU. To specify more, you can give a ShmMessageGrp object on the command line. The following would run MPQC in four processes::(n = 4)"
mpqc -messagegrp "Alternately, the ShmMessageGrp object can be given as an environmental variable::(n = 4)" input_file
setenv MESSAGEGRP "If MPQC should unexpectedly die, shared memory segments and semaphores will be left on the machine. These should be promptly cleaned up or other jobs may be prevented from running successfully. To see if you have any of these resources allocated, use the ipcs command. The output will look something like::(n = 4)" mpqc input_file
IPC status from /dev/kmem as of Wed Mar 13 14:42:18 1996 T ID KEY MODE OWNER GROUP Message Queues: Shared Memory: m 288800 0x00000000 --rw------- cljanss user Semaphores: s 390 0x00000000 --ra------- cljanss user s 391 0x00000000 --ra------- cljanss userTo remove the IPC resources used by cljanss in the above example on IRIX, type:
ipcrm -m 288800 ipcrm -s 390 ipcrm -s 391And on Linux, type:
ipcrm shm 288800 ipcrm sem 390 ipcrm sem 391\section mpqcpthr Shared Memory Multiprocessor with POSIX Threads By default, MPQC will run with only one thread. To specify more, you can give a PthreadThreadGrp object on the command line. MPQC is not parallelized to as large an extent with threads as it is with the more conventional distributed memory model, so you might not get the best performance using this technique. On the other the memory overhead is lower and no interprocess communication is needed. The following would run MPQC in four threads:
mpqc -threadgrp "Alternately, the PthreadThreadGrp object can be given as an environmental variable::(num_threads = 4)" input_file
setenv THREADGRP "\section mpqcmpi Shared or Distributed Memory Multiprocessor with MPI A MPIMessageGrp object is used to run using MPI. The number of nodes used is determined by the MPI run-time and is not specified as input data to MPIMessageGrp.:(num_threads = 4)" mpqc input_file
mpqc -messagegrp "Alternately, the MPIMessageGrp object can be given as an environmental variable::()" input_file
setenv MESSAGEGRP "Usually, a special command is needed to start MPI jobs; typically it is named mpirun. \section mpqcmp2 Special Notes for MP2 Gradients The MP2 gradient algorithm uses MemoryGrp object to access distributed shared memory. The MTMPIMemoryGrp class is the most efficient and reliable implementation of MemoryGrp. It requires a multi-thread aware MPI implementation, which is still not common. To run MP2 gradients on a machine with POSIX threads and an multi-thread aware MPI, use::()" mpqc input_file
mpqc -messagegrp "or:()" \ -threadgrp " :()" \ -memorygrp " :()" \ input_file
setenv MESSAGEGRP "\section mpqcmp2r12 Special Notes for MP2-R12 energies:()" setenv THREADGRP " :()" setenv MEMORYGRP " :()" mpqc input_file
Distributed Memory The MP2-R12 energy algorithm is similar to the MP2 energy algorithm that uses MemoryGrp object to access distributed memory. Hence the MTMPIMemoryGrp is the recommended implementation of MemoryGrp for such computations (see \ref mpqcmp2).
Disk I/O In contrast to the MP2 energy and gradient algorithms, the MP2-R12 energy algorithm may have to use disk to store transformed MO integrals if a single pass through the AO integrals is not possible due to insufficient memory. The best option in such case is to increase the total amount of memory available to the computation by either increasing the number of tasks or the amount of memory per task or both. When increasing memory further is not possible, the user has to specify which type of disk I/O should be used for the MP2-R12 energy algorithm. It is done through the r12ints keyword in input for the MBPT2_R12 object. The default choice is to use POSIX I/O on the node on which task 0 resides. This kind of disk I/O is guaranteed to work on all parallel machines, provided there's enough disk space on the node. However, this is hardly most efficient on machines with some sort of parallel I/O available. On machines which have an efficient implementation of MPI-IO the r12ints should be set instead to mpi-mem. This will force the MBPT2_R12 object to use MPI-IO for disk I/O. It is user's responsibility to make sure that the MO integrals file resides on an MPI-IO-compatible file system. Hence the r12ints_file keyword, which specifies the name of the MO integrals file, should be set to a location which is guaranteed to work properly with MPI-IO. For example, on IBM SP and other IBM machines which have General Parallel File System (GPFS), the user should set r12ints = mpi-mem and r12ints_file to a file on a GPFS file system.
Integral object
At the moment, MBPT2_R12 objects require specific specialization of Integral,
IntegralCints. Thus in order to compute MP2-R12 energies, your version of MPQC
needs to be compiled with support for IntegralCints. A free, open-source
library called libint is a prerequisite for IntegralCints\if html (see \ref compile)\endif.
In order to use IntegralCints as the default Integral object,
add -integral "
Common Component Architecture (CCA) Portions of MPQC functionality are being packaged into CCA components. For general overviews of CCA technology and framework usage, please see www.cca-forum.org (the tutorial in particular) and the cca-chem-apps documentation. MPQC components may be utilized directly within the ccaffeine framework, while some components may be instantiated and used within MPQC itself, making use of an embedded CCA framework.
CCA Runtime Environment For MPQC runs utilizing embedded components, the runtime environment for the CCA framework must be specified. The colon-separated path used to locate component libraries must be specified either using the -cca-path command-line option or using the cca_path key within the mpqc section of a keyval input. The colon-separated list of component sidl class names which will be referenced within the input must be specified using either the -cca-load command-line option or using the cca_load key within the mpqc section of a keyval input. If defaults for the cca-path and cca-load options are desired, do_cca must be set to yes in the keyval input. */