Skip to content

Computational Environment

Judit Zádor edited this page Jun 16, 2024 · 3 revisions

Back to Input

parameter default description
queuing pbs 'pbs' or 'slurm' or 'fireworks' or 'local'
scratch '' Scratch directory of the calculations
username '' User name, required.
queue_name 'medium' Queue name where the calculations are submitted to.
queue_template '' The user can supply a queue submission script. The parameter is the name of the file. For details see below this table. When queuing is set to 'fireworks' a Fireworks Queue Adapter .yaml file is expected.
slurm_feature '' The SLURM feature defined after the -C, see here.
ppn 1 Number of cores per quantum chemistry calculation, e.g., in Gaussian the number after %nprocshared.
single_point_ppn 4 Number of cores to run the single-point calculations on.
zf 4 Number of characters in file numbers.
delete_intermediate_files 0 Delete chk, py and pbs or sbatch files. Can be useful is disk space is limited. However, care must be taken. If for instance the barrier_threshold is increased, the deleted chk files will prevent the IRC calculations to proceed. Use this keyword wisely.
queue_job_limit -1 If set to a positive number, no more than queue_job_limit jobs from user username are submitted to the queue. This counts jobs from other KinBot jobs or any other application from the user and it is checked every 30 seconds. In fireworks mode this is the number of jobs submitted to the queue at the beginning of the simulation.
lpad_file my_launchpad.yaml Only when using Fireworks. File with the necessary configuration to access the MongoDB server to manage FireWorks tasks. See examples below.
fworker_file my_fworker.yaml Only when using Fireworks. File with the necessary configuration to set up a worker carrying out the FireWorks tasks. See examples below.

While KinBot is fully restartable, some parameters cannot be changed upon restart without compromising the calculations. These are marked with an asterisk (*).

For the queuing system it is often necessary to include system-specific commands in the job submission script. Importantly, when using KinBot in a conda environment, one also has to modify the script to allow the activation and deactivation on the given nodes. To have maximum flexibility, KinBot allows the user to define her or his own script, which overwrites the default. The default template in KinBot for PBS is the following:

#! /bin/bash -f
#PBS -N {name}
#PBS -l nodes=1:ppn={ppn}
#PBS -q {queue_name}
#PBS -o {errdir}/$PBS_JOBNAME.stdout
#PBS -e {errdir}/$PBS_JOBNAME.err
#PBS -m n

while it is the following for SLURM:

#! /bin/bash -f

#SBATCH -N 1
#SBATCH -c {ppn}
#SBATCH -q {queue_name}
#SBATCH -o {errdir}/{name}.stdout
#SBATCH -e {errdir}/{name}.err
{slurm_feature}

When queuing is set to 'local', no jobs are submitted and KinBot just performs a 'dry run' evaluating data from already existing files. When it is set to 'fireworks', instead, KinBot expects a file called my_qadapter.yaml to be present in the execution directory if 'queue_template' is not specifed.

The user can supply a file placed in the same directory as the input file, which will be used instead of the above defaults (see queue_template keyword). When providing custom templates, it is important to use these original templates and add the necessary lines to them, i.e., do not delete any of the original lines. If a certain line is creating some problems on the given system, it should be commented out rather than deleted. Useful to remember:

  • A line beginning with # is a comment, while a line beginning with #PBS or #SBATCH is a directive.
  • Substitutions can be used on other lines, but no additional substitutions are allowed. Everything else has to be hardwired. The substitution keys are:
    • {ppn} = 'ppn' keyword's value
    • {name} = name of the job, as generated by KinBot
    • {errdir} = the directory as determined by KinBot
    • {queue_name} = the 'queue_name' keyword's value
    • {slurm_feature} = the 'slurm_feature' keyword's value

Examples of Fireworks configuration files:

  • my_qadapter.yaml
_fw_name: CommonAdapter
_fw_q_type: SLURM
rocket_launch: srun -n 8 rlaunch rapidfire --nlaunches infinite
nodes: 4
ntasks: 32
cpus_per_task: 1
ntasks_per_node: 8
walltime: '48:00:00'
qos: regular  
job_name: KB_FW

pre_rocket: "conda activate kinbot\nmodule load qchem"
post_rocket: null
  • my_launchpad.yaml
authsource: KinBot
host: mongodb07
logdir: null
mongoclient_kwargs: {}
name: KinBot
password: *************
port: 27017
ssl: false
ssl_ca_certs: null
ssl_certfile: null
ssl_keyfile: null
ssl_pem_passphrase: null
strm_lvl: WARNING
uri_mode: false
user_indices: []
username: KinBot_admin
wf_user_indices: []
  • my_fworker.yaml
name: CoriNode
category: ''
query: '{}'