HPC/Applications/q-chem

From CNM Wiki
< HPC‎ | Applications
Revision as of 17:48, December 3, 2012 by Stern (talk | contribs) (→‎Example)
Jump to navigation Jump to search

Parallel jobs

To run Q-Chem in parallel, load the module in your shell startup, then use the -pbs -np $PBS_NP command line options in the PBS job script, as shown in:

$Q_CHEM_HOME/sample.job

All setup is done by the modulefile - you do not need to source a qcenv script. During the run various temporary files appear in the workding directory. These will normally be cleaned up when the program exits correctly, but some files may need to be removed manually.

Capabilities Matrix

As of v4.0.1 there is limited support for OpenMP (multithreading), though not yet for hybrid OpenMP/MPI.

Method OpenMP MPI
HF energy & gradient noa yes
DFT energy & gradient noa yes
MP2 energy and gradient yesb yes
Integral transformation no no
CCMAN & CCMAN2 methods yes no
ADC methods yes no
CIS no no
TDDFT no no

a Experimental code in version 4.0.1.
b To invoke an experimental OpenMP RI-MP2 code (RHF energies only), use CORR=primp2.

Using GPUs

RI-MP2 ("resolution of the identity") energies and gradients are implemented with GPU support; see Q-Chem manual, sec. 5.5.4.

Options

CUDA RI-MP2
Enables GPU implementation of RI-MP2
  • TYPE: logical; DEFAULT: FALSE.
  • Q-Chem recommendation: Set to 1 to use GPU-enabled MGEMM.
USECUBLAS THRESH
Sets threshold of matrix size sent to GPU (smaller size not worth sending to GPU).
  • TYPE: INTEGER; DEFAULT: 250
  • Q-Chem recommendation: Use the default value. Anything less can seriously hinder the GPU acceleration.
USE MGEMM
Use the mixed-precision matrix scheme (MGEMM) if you want to make calculations in your card in single-precision (or if you have a single-precision-only GPU), but leave some parts of the RI-MP2 calculation in double precision).
  • TYPE: INTEGER; DEFAULT: 0 (MGEMM disabled)
  • Carbon recommendation: leave at 0.
MGEMM THRESH
Sets MGEMM threshold to determine the separation between “large” and “small” matrix elements. A larger threshold value will result in a value closer to the single-precision result. Note that the desired factor should be multiplied by 10000 to ensure an integer value.
  • TYPE: INTEGER; DEFAULT: 10000 (corresponds to 1)
  • Q-Chem recommendation: For small molecules and basis sets up to triple-ζ, the default value suffices to not deviate too much from the double-precision values. Care should be taken to reduce this number for larger molecules and also larger basis-sets.

Example

Q-Chem manual example 5.5: RI-MP2 double-precision calculation

$comment
RI-MP2 double-precision example
$end
$molecule
0 1
c
h1 c 1.089665
h2 c 1.089665 h1 109.47122063
h3 c 1.089665 h1 109.47122063 h2 120. h4 c 1.089665 h1 109.47122063 h2 -120.
$end
$rem
jobtype sp
exchange hf
correlation rimp2
basis cc-pvdz
aux_basis rimp2-cc-pvdz
cuda_rimp2 1
$end