source: ThirdParty/mpqc_open/src/bin/mpqc/mpqcrunning.dox@ 482400e

Action_Thermostats Add_AtomRandomPerturbation Add_RotateAroundBondAction Add_SelectAtomByNameAction Adding_Graph_to_ChangeBondActions Adding_MD_integration_tests Adding_StructOpt_integration_tests Automaking_mpqc_open AutomationFragmentation_failures Candidate_v1.6.0 Candidate_v1.6.1 ChangeBugEmailaddress ChangingTestPorts ChemicalSpaceEvaluator Combining_Subpackages Debian_Package_split Debian_package_split_molecuildergui_only Disabling_MemDebug Docu_Python_wait EmpiricalPotential_contain_HomologyGraph_documentation Enable_parallel_make_install Enhance_userguide Enhanced_StructuralOptimization Enhanced_StructuralOptimization_continued Example_ManyWaysToTranslateAtom Exclude_Hydrogens_annealWithBondGraph FitPartialCharges_GlobalError Fix_ChronosMutex Fix_StatusMsg Fix_StepWorldTime_single_argument Fix_Verbose_Codepatterns ForceAnnealing_goodresults ForceAnnealing_oldresults ForceAnnealing_tocheck ForceAnnealing_with_BondGraph ForceAnnealing_with_BondGraph_continued ForceAnnealing_with_BondGraph_continued_betteresults ForceAnnealing_with_BondGraph_contraction-expansion GeometryObjects Gui_displays_atomic_force_velocity IndependentFragmentGrids_IntegrationTest JobMarket_RobustOnKillsSegFaults JobMarket_StableWorkerPool JobMarket_unresolvable_hostname_fix ODR_violation_mpqc_open PartialCharges_OrthogonalSummation PythonUI_with_named_parameters QtGui_reactivate_TimeChanged_changes Recreated_GuiChecks RotateToPrincipalAxisSystem_UndoRedo StoppableMakroAction Subpackage_levmar Subpackage_vmg ThirdParty_MPQC_rebuilt_buildsystem TremoloParser_IncreasedPrecision TremoloParser_MultipleTimesteps Ubuntu_1604_changes stable
Last change on this file since 482400e was 860145, checked in by Frederik Heber <heber@…>, 8 years ago

Merge commit '0b990dfaa8c6007a996d030163a25f7f5fc8a7e7' as 'ThirdParty/mpqc_open'

  • Property mode set to 100644
File size: 12.8 KB
Line 
1
2/** \page mpqcrunning Running MPQC
3
4This chapter explains how to run MPQC in a variety of environments.
5
6The first two sections give general information on running MPQC:
7
8<ul>
9 <li> \ref mpqccomline
10 <li> \ref mpqcenv
11</ul>
12
13The final sections given specific information on running MPQC in
14different environments:
15
16<ul>
17 <li> \ref mpqcshmem
18 <li> \ref mpqcpthr
19 <li> \ref mpqcmpi
20 <li> \ref mpqcmp2
21 <li> \ref mpqcmp2r12
22 <li> \ref mpqccca
23</ul>
24
25\section mpqccomline Command Line Options
26
27 MPQC can be given options followed by an optional input file
28name. If the input file name is not given, it will default to
29"mpqc.in". The following command line options are recognized:
30
31<dl>
32
33 <dt><tt>-o</tt><dd>Gives the name of the output file. The default is the
34 console.
35
36 <dt><tt>-i</tt><dd>Convert a simple input file to an object oriented
37 input file and write the result to the ouput. No
38 calculations are done.
39
40 <dt><tt>-messagegrp</tt><dd>A ParsedKeyVal specification of a MessageGrp
41 object. The default depends on how MPQC was compiled.
42
43 <dt><tt>-memorygrp</tt><dd>A ParsedKeyVal specification of a MemoryGrp
44 object. The default depends on how MPQC was compiled.
45
46 <dt><tt>-threadgrp</tt><dd>A ParsedKeyVal specification of a ThreadGrp
47 object. The default depends on how MPQC was compiled.
48
49 <dt><tt>-integral</tt><dd>A ParsedKeyVal specification of an Integral
50 object. The default is IntegralV3. Note that some
51 MolecularEnergy specializations require specific choices
52 of Integral specializations and may not work with IntegralV3.
53
54 <dt><tt>-l</tt><dd>Sets a limit on the number of basis functions. The
55 default is zero, which means an unlimited number of basis
56 functions.
57
58 <dt><tt>-W</tt><dd>Sets the working directory. The default is the
59 current directory.
60
61 <dt><tt>-c</tt><dd>Check the input and exit.
62
63 <dt><tt>-v</tt><dd>Print the version number.
64
65 <dt><tt>-w</tt><dd>Print the warranty information (there is no warranty).
66
67 <dt><tt>-d</tt><dd>If a debugger object was given in the input, start the
68 debugger running as soon as MPQC is started.
69
70 <dt><tt>-h</tt><dd>Print a list of options.
71
72 <dt><tt>-f</tt><dd>The name of an object-oriented input file. The
73 default is <tt>mpqc.in</tt>. This cannot be used if
74 another input file is specified. This option is
75 deprecated, as both input file formats can be read
76 by given the input file name on the command line
77 without any option flags.
78
79 <dt><tt>-cca-path</tt><dd>A colon-separated list of directories in which
80 CCA component libraries may be found.
81
82 <dt><tt>-cca-load</tt><dd>A colon-separated list of sidl class names for
83 CCA components which will be instantiated from the libraries
84 found in the path given by <tt>-cca-path</tt>
85
86</dl>
87
88Some MPI environments do not pass the command line to slave programs, but
89supply it when MPI_Init is called. To make MPQC call MPI_Init with the
90correct arguments as early as possible use the configure option
91<tt>--enable-always-use-mpi</tt>.
92
93\section mpqcenv Environmental Variables
94
95MPQC looks at five environmental variables to set up
96communication, find library files, and specify the default Integral
97object. Machine specific libraries
98and utilities to run programs in parallel might look
99at other environment variables as well. The five that
100apply on all platforms are:
101
102<dl>
103
104 <dt><tt>SCLIBDIR</tt><dd>The name of the library directory. See the
105 GaussianBasisSet documentation and look below for more
106 information.
107
108 <dt><tt>MESSAGEGRP</tt><dd>A ParsedKeyVal specification of a MessageGrp
109 object. The default depends on how MPQC was compiled.
110 See the MessageGrp class documentation for more
111 information.
112
113 <dt><tt>MEMORYGRP</tt><dd>A ParsedKeyVal specification of a MemoryGrp
114 object. The default depends on how MPQC was compiled
115 and the MessageGrp in use.
116
117 <dt><tt>THREADGRP</tt><dd>A ParsedKeyVal specification of a ThreadGrp
118 object. The default depends on how MPQC was compiled.
119
120 <dt><tt>INTEGRAL</tt><dd>A ParsedKeyVal specification of an Integral
121 object. The default is IntegralV3. Note that some
122 MolecularEnergy specializations require specific choices
123 of Integral specializations and may not work with IntegralV3.
124
125</dl>
126
127By default, MPQC tries to find library files first in the <tt>lib</tt>
128subdirectory of the installation directory and then the source code
129directory. If the library files cannot be found, MPQC must be notified of
130the new location with the environmental variable <tt>SCLIBDIR</tt>.
131
132For example, if you need to run MPQC on a machine that doesn't have the
133source code distribution in the same place as it was located on the machine
134on which MPQC is compiled you must do something like the following on the
135machine with the source code:
136
137<pre>
138cd mpqc/lib
139tar cvf ../sclib.tar basis atominfo.kv
140</pre>
141
142Then transfer <tt>sclib.tar</tt> to the machine on which you want to run MPQC
143and do something like
144
145<pre>
146mkdir ~/sclib
147cd ~/sclib
148tar xvf ../sclib.tar
149setenv SCLIBDIR ~/sclib
150</pre>
151
152The <tt>setenv</tt> command is specific to the C-shell. You will need to
153do what is appropriate for your shell.
154
155The other three keywords specify objects. This is done by giving a mini
156ParsedKeyVal input in a string. The object is anonymous, that is, no
157keyword is associated with it. Here is an example:
158
159<pre>
160setenv MESSAGEGRP "<ShmMessageGrp>:(n = 4)"
161</pre>
162
163\section mpqcshmem Shared Memory Multiprocessor with SysV IPC
164
165By default, MPQC will run on only one CPU. To specify more, you can give a
166ShmMessageGrp object on the command line.
167The following would run MPQC in four processes:
168<pre>
169mpqc -messagegrp "<ShmMessageGrp>:(n = 4)" input_file
170</pre>
171
172Alternately, the ShmMessageGrp object can
173be given as an environmental variable:
174<pre>
175setenv MESSAGEGRP "<ShmMessageGrp>:(n = 4)"
176mpqc input_file
177</pre>
178
179If MPQC should unexpectedly die, shared memory segments and semaphores will
180be left on the machine. These should be promptly cleaned up or other jobs
181may be prevented from running successfully. To see if you have any of
182these resources allocated, use the <tt>ipcs</tt> command. The output will
183look something like:
184
185<pre>
186IPC status from /dev/kmem as of Wed Mar 13 14:42:18 1996
187T ID KEY MODE OWNER GROUP
188Message Queues:
189Shared Memory:
190m 288800 0x00000000 --rw------- cljanss user
191Semaphores:
192s 390 0x00000000 --ra------- cljanss user
193s 391 0x00000000 --ra------- cljanss user
194</pre>
195
196To remove the IPC resources used by <tt>cljanss</tt> in
197the above example on IRIX, type:
198
199<pre>
200ipcrm -m 288800
201ipcrm -s 390
202ipcrm -s 391
203</pre>
204
205And on Linux, type:
206
207<pre>
208ipcrm shm 288800
209ipcrm sem 390
210ipcrm sem 391
211</pre>
212
213\section mpqcpthr Shared Memory Multiprocessor with POSIX Threads
214
215By default, MPQC will run with only one thread. To specify more, you can
216give a PthreadThreadGrp object on the command line. MPQC is not
217parallelized to as large an extent with threads as it is with the more
218conventional distributed memory model, so you might not get the best
219performance using this technique. On the other the memory overhead is
220lower and no interprocess communication is needed.
221
222The following would run MPQC in four threads:
223
224<pre>
225mpqc -threadgrp "<PthreadThreadGrp>:(num_threads = 4)" input_file
226</pre>
227
228Alternately, the PthreadThreadGrp object can
229be given as an environmental variable:
230<pre>
231setenv THREADGRP "<PthreadThreadGrp>:(num_threads = 4)"
232mpqc input_file
233</pre>
234
235\section mpqcmpi Shared or Distributed Memory Multiprocessor with MPI
236
237A MPIMessageGrp object is used to run using MPI. The number of nodes used
238is determined by the MPI run-time and is not specified as input data to
239MPIMessageGrp.
240
241<pre>
242mpqc -messagegrp "<MPIMessageGrp>:()" input_file
243</pre>
244
245Alternately, the MPIMessageGrp object can
246be given as an environmental variable:
247<pre>
248setenv MESSAGEGRP "<MPIMessageGrp>:()"
249mpqc input_file
250</pre>
251
252Usually, a special command is needed to start MPI jobs; typically it is
253named <tt>mpirun</tt>.
254
255\section mpqcmp2 Special Notes for MP2 Gradients
256
257The MP2 gradient algorithm uses MemoryGrp object to access distributed
258shared memory. The MTMPIMemoryGrp class is the most efficient and reliable
259implementation of MemoryGrp. It requires a multi-thread aware MPI
260implementation, which is still not common. To run MP2 gradients on a
261machine with POSIX threads and an multi-thread aware MPI, use:
262
263<pre>
264mpqc -messagegrp "<MPIMessageGrp>:()" \
265 -threadgrp "<PthreadThreadGrp>:()" \
266 -memorygrp "<MTMPIMemoryGrp>:()" \
267 input_file
268</pre>
269
270or
271
272<pre>
273setenv MESSAGEGRP "<MPIMessageGrp>:()"
274setenv THREADGRP "<PthreadThreadGrp>:()"
275setenv MEMORYGRP "<MTMPIMemoryGrp>:()"
276mpqc input_file
277</pre>
278
279\section mpqcmp2r12 Special Notes for MP2-R12 energies
280
281<p>
282<b>Distributed Memory</b>
283
284The MP2-R12 energy algorithm is similar to the MP2 energy algorithm that uses
285MemoryGrp object to access distributed memory. Hence the MTMPIMemoryGrp is the
286recommended implementation of MemoryGrp for such computations (see \ref mpqcmp2).
287</p>
288
289<p>
290<b>Disk I/O</b>
291
292In contrast to the MP2 energy and gradient algorithms, the MP2-R12 energy algorithm
293may have to use disk to store transformed MO integrals if a single pass through
294the AO integrals is not possible due to insufficient memory. The best option in such case
295is to increase the total amount of memory available to the computation by either
296increasing the number of tasks or the amount of memory per task or both.
297
298When increasing memory further is not possible, the user has to specify which
299type of disk I/O should be used for the MP2-R12 energy algorithm. It is done through
300the <tt>r12ints</tt> keyword in input for the MBPT2_R12 object. The default choice
301is to use POSIX I/O on the node on which task 0 resides. This kind of disk I/O
302is guaranteed to work on all parallel machines, provided there's enough disk space
303on the node. However, this is hardly most efficient on machines with
304some sort of parallel I/O available.
305On machines which have an efficient implementation of MPI-IO
306the <tt>r12ints</tt> should be set instead to <tt>mpi-mem</tt>.
307This will force the MBPT2_R12
308object to use MPI-IO for disk I/O. It is user's responsibility to make sure
309that the MO integrals file resides on an MPI-IO-compatible file system.
310Hence the <tt>r12ints_file</tt> keyword, which specifies the name of the MO integrals
311file, should be set to a location which is guaranteed to work properly with MPI-IO.
312For example, on IBM SP and other IBM machines which have General Parallel File System
313(GPFS), the user should set <tt>r12ints = mpi-mem</tt> and <tt>r12ints_file</tt>
314to a file on a GPFS file system.
315</p>
316
317<p>
318<b>Integral object</b>
319<br>
320
321At the moment, MBPT2_R12 objects require specific specialization of Integral,
322IntegralCints. Thus in order to compute MP2-R12 energies, your version of MPQC
323needs to be compiled with support for IntegralCints. A free, open-source
324library called <tt>libint</tt> is a prerequisite for IntegralCints\if html (see \ref compile)\endif.
325In order to use IntegralCints as the default Integral object,
326add <tt>-integral "<IntegralCints>:()"</tt> to the command line,
327or set environmental variable <tt>INTEGRAL</tt> to <tt>"<IntegralCints>:()"</tt>.
328</p>
329
330\section mpqccca Special Notes for CCA Components
331
332<p>
333<b>Common Component Architecture (CCA)</b>
334
335Portions of MPQC functionality are being packaged into CCA components.
336For general overviews of CCA technology and framework usage, please see
337<a href="http://www.cca-forum.org">www.cca-forum.org</a> (the tutorial in particular) and the
338<a href="http://www.cca-forum.org/~cca-chem/doc-apps-0.2/index.html">cca-chem-apps</a>
339documentation.
340MPQC components may be utilized directly within the ccaffeine framework, while some
341components may be instantiated and used within MPQC itself, making use of an embedded
342CCA framework.
343</p>
344
345<p>
346<b>CCA Runtime Environment</b>
347
348For MPQC runs utilizing embedded components, the runtime environment for the CCA
349framework must be specified.
350The colon-separated path used to locate component libraries must be specified either
351using the <tt>-cca-path</tt> command-line option or using the <tt>cca_path</tt> key
352within the <tt>mpqc</tt> section of a keyval input.
353The colon-separated list of component sidl class names which will be referenced within the
354input must be specified using either the <tt>-cca-load</tt> command-line option or using
355the <tt>cca_load</tt> key within the <tt>mpqc</tt> section of a keyval input.
356If defaults for the cca-path and cca-load options are desired, <tt>do_cca</tt> must be
357set to <tt>yes</tt> in the keyval input.
358
359*/
Note: See TracBrowser for help on using the repository browser.