ORCA: Difference between revisions

From RCSWiki
Jump to navigation Jump to search
Line 137: Line 137:
Now you can submit the job to the SLURM scheduler and check the job:
Now you can submit the job to the SLURM scheduler and check the job:
<pre>
<pre>
$ sbatch trimer.inp
$ sbatch trimer.slurm
Submitted batch job 21550624
Submitted batch job 21550624



Revision as of 15:02, 12 September 2023

General

ORCA is a flexible, efficient and easy-to-use general-purpose tool for quantum chemistry with specific emphasis on spectroscopic properties of open-shell molecules. It features a wide variety of standard quantum chemical methods ranging from semiempirical methods to DFT to single- and multireference correlated ab initio methods. It can also treat environmental and relativistic effects.

Licensing

If you wish to use centrally installed prebuilt ORCA executables:

  1. You have to register at https://orcaforum.kofo.mpg.de/
  2. You will receive a first email to verify the email address and activate the account. Follow the instructions in that email.
  3. Once the registration is complete, you will get a second email stating that the "registration for ORCA download and usage has been completed".
  4. Contact us requesting access to ORCA with a copy of the second email at support@hpc.ucalgary.ca.


Note: You do not need to ask a permission from us, if you are willing to download ORCA and install it in your home directory on your own. You only need to contact us if you are planning on using the centrally installed ORCA using the module command.

ORCA on ARC

To see available versions of ORCA on ARC, use the module command:

$ module avail orca
----------------------- /global/software/Modules/4.6.0/modulefiles -----------------------
orca/5.0.3-shared  orca/5.0.3-static  

At the moment of writing there are two modules that provide the same version of ORCA, v5.0.3. The modules are based on the binary distributions provided by the developers, for shared and static builds of of the executable files.


For parallel runs orca needs an MPI library. On ARC it depends on the openmpi/4.1.1-gnu module.

Test case

Input file

ORCA input file, trimer.inp:

# Beryllium Hydroxo Cation Trimer 
%pal nprocs 48 end
! RHF TightSCF PModel
! opt

* xyz 3 1
BE    -0.8525564731   1.4385952336  -0.0568386129
BE    -0.8439106317  -1.4629929631  -0.0609922493
BE     1.6646301187  -0.0047356303  -0.0492110057
O     -1.4961121024   2.3487644892   1.2288561938
O     -1.3182244409  -2.4739274717   1.2229994716
O      2.7600572652  -0.0952297793  -1.3493767865
O     -1.3120368956   2.4299969307  -1.3624682759
O     -1.4647109135  -2.3581289822  -1.3693992968
O      2.7677255286   0.0905655941   1.2430198205
H     -1.8119923339   1.9892271297   2.0517208639
H     -0.8530364757  -2.5680042291   2.0481697576
H      3.5593293692   0.4144864646  -1.4503014673
H     -2.1528769106   2.8657164542  -1.4716703585
H     -1.4216692255  -3.3043858812  -1.4768305047
H      2.6169144032  -0.5871082502  -2.1516801328
H     -0.8074101333   2.5517677785  -2.1603597618
H     -1.8167790717  -1.9829473649  -2.1702654859
H      3.5918724943  -0.3831545116   1.3144677218
H     -1.5005192072   3.2996000227   1.2972549220
H     -2.1403067026  -2.9521565768   1.2875415691
H      2.6106062441   0.5414374312   2.0666175658
O      0.7464193743  -1.3117753249  -0.0488528410
O      0.7384467702   1.2969248953  -0.0443089227
O     -1.5167658775  -0.0143091197  -0.0541930119
H      1.2233662484  -2.1319290025  -0.0335893416
H      1.2100703374   2.1200534530  -0.0251688186
H     -2.4654622393  -0.0174143863  -0.0404919530
*

In this example, the number of MPI processes is set to 48, which is specific to the cpu2021 and cpu2021-bf24 partitions on ARC. Please, do not forget to change that number according to the partition you are going to run it on.

Job script

The job script for the trimer example, trimer.slurm:

#! /bin/bash
# ===========================================================================
#SBATCH --job-name=orca_test
#SBATCH --nodes=1
#SBATCH --ntasks=48
#SBATCH --cpus-per-task=1
#SBATCH --mem=64GB
#SBATCH --time=0-5:00:00
#SBATCH --partition=cpu2021-bf24

# ===========================================================================
module load openmpi/4.1.1-gnu
module load orca/5.0.4-static

ORCA=`which orca`

$ORCA trimer.inp
# ===========================================================================

This job script requests 5 hours or run time on the cpu2021-bf24 partition, as well as 48 MPI processes and 64 Gb of RAM.


NOTE, that for parallel runs ORCA insists on being started using full absolute path. Not just with the orca commmad, but using /global/software/orca/5.0.4-static/orca full name.

This is why the line ORCA=`which orca` is required.

Running the test

You have to create a directory to contain all the files for this test case, and "change" to that directory:

$ cd 
$ mkdir -p my-jobs/orca-tests/trimer
$ cd my-jobs/orca-tests/trimer

Then you have to create the trimer.inp input file, as well as the job script, trimer.slurm. You can use the nano text editor for this and copy/paste the text for the files from this page.

$ nano trimer.inp
....
$ nano trimer.slurm
....

Once you create both the files, you can check if they are in the current directory:

$ pwd
/home/username/my-jobs/orca-tests/trimer

$ ls -l
-rw-r--r-- 1 username username    1445 Jul 25 09:18 trimer.inp
-rwxr-xr-x 1 username username     515 Jul 25 09:18 trimer.slurm

Now you can submit the job to the SLURM scheduler and check the job:

$ sbatch trimer.slurm
Submitted batch job 21550624

$ squeue-long -j 21550624
JOBID     USER      STATE   PARTITION TIME_LIMIT  TIME  NODES  TASKS  CPUS  MIN_MEMORY TRES_PER_NREASON   NODELIST
21550624  username  RUNNING cpu2021-bf5:00:00     0:21  1      48     48    64G        N/A       None     mc52                

After about 1 minute the job should terminate normally. The output is saved by SLURM to the slurm-21550624.out output file.

So, we can check the results:

$ ls -l
total 2160
-rw-r--r-- 1 username username  265079 Jul 25 09:38 slurm-21550624.out
-rw-r--r-- 1 username username  416925 Jul 25 09:38 trimer.densities
-rw-r--r-- 1 username username    3203 Jul 25 09:38 trimer.engrad
-rw-r--r-- 1 username username 1152724 Jul 25 09:38 trimer.gbw
-rw-r--r-- 1 username username    1445 Jul 25 09:37 trimer.inp
-rw-r--r-- 1 username username  288435 Jul 25 09:38 trimer.opt
-rwxr-xr-x 1 username username     515 Jul 25 09:37 trimer.slurm
-rw-r--r-- 1 username username    1861 Jul 25 09:38 trimer.xyz
-rw-r--r-- 1 username username   26260 Jul 25 09:38 trimer_property.txt
-rw-r--r-- 1 username username    7950 Jul 25 09:38 trimer_trj.xyz

$ tail slurm-21550624.out

Timings for individual modules:

Sum of individual times         ...       44.596 sec (=   0.743 min)
GTO integral calculation        ...        9.006 sec (=   0.150 min)  20.2 %
SCF iterations                  ...       25.763 sec (=   0.429 min)  57.8 %
SCF Gradient evaluation         ...        9.528 sec (=   0.159 min)  21.4 %
Geometry relaxation             ...        0.299 sec (=   0.005 min)   0.7 %
                             ****ORCA TERMINATED NORMALLY****
TOTAL RUN TIME: 0 days 0 hours 0 minutes 51 seconds 923 msec

Success!

Links

ARC Software pages