ORCA
ORCA is an ab initio quantum chemistry package which provides methods in the field of electronic structure theory, including density functional- as well as correlated wave function-based methods.
Access
Usage of ORCA requires registration with the ORCA Forum. In general the head of the research group should register and then forward the confirmation email to us. We will then enable access to ORCA for the group. If you are not a member of a registered group, you cannot use ORCA on our system.
#!/bin/bash
##BATCH --job-name=orca_job
#SBATCH --ntasks=4
#SBATCH --time=5-00:00:0
#SBATCH --mem-per-cpu=500
#SBATCH --nodes=1
#SBATCH --partition=main
#SBATCH --qos=standard
#SBATCH --mail-type=FAIL,BEGIN,END
# Name of input file
INPUT=$1
# Adjust nprocs/NPROCS
#
# WARNING: If your input file does not contain a line which specifies
# the number of processes of the form, say
#
# %PAL nprocs 8
#
# then the following will NOT cause the value from the job script to
# be used by ORCA
sed -ir "s/nprocs\s+[0-9]+/nprocs $SLURM_NTASKS/i" $INPUT.inp
# Load module - always specify the exact version
module load ORCA/5.0.4-gompi-2022b
# Create the scratch directory
export SCRATCHDIR=/scratch/$USER/orca/tmp.$SLURM_JOBID
if [ -d $SCRATCHDIR ]; then
echo "$SCRATCHDIR exists; double job start; exit"
exit 1
fi
mkdir -p $SCRATCHDIR
# Define the project directory
export PROJECT=`pwd`
set -e
# Define function to clean up after error
function catch_err {
if grep -q "ORCA TERMINATED NORMALLY" $INPUT.out
then
cp $SCRATCHDIR/* $PROJECT
else
mkdir $PROJECT/failed
cp $SCRATCHDIR/* $PROJECT/failed
fi
}
# Catch errors (signal EXIT), interrupts (signal INT), and kills (signal TERM)
trap catch_err EXIT INT TERM
# Copy Inputs to SCRATCHDIR and run ORCA job
cp -f $PROJECT/* $SCRATCHDIR
touch $PROJECT/$SLURM_NODELIST
cd $SCRATCHDIR
orcarun=`which orca`
$orcarun $INPUT.inp > $INPUT.out
# Check if run was successful and copy stuff back
trap - EXIT