qmmd.qmcalc.genScripts

Attributes

inpDirPath

Functions

writeGaussInpFile(→ None)

Generate a Gaussian input file based on specified inputs.

writeHPCJobScript(→ None)

Generate a HPC jobscript based on specified inputs.

genAllScripts(→ None)

Generate Gaussian input job files and submission files for molecules under all directories under a specified directory ('inpDirPath').

Module Contents

qmmd.qmcalc.genScripts.writeGaussInpFile(name: str, inpDirPath: str, keywordLine: str | None = None, mem: int | str = 4000, ncpus: int | str = 8, combination: str = ' m062x/6-311+g(d,p)', scrf: str = ' scrf=(cpcm,solvent=water)', freq: str = ' freq', grid: str = ' opt=calcfc int(grid=ultrafine)', charge: int = 0, spin: int = 1, verbose: bool = False) None[source]

Generate a Gaussian input file based on specified inputs.

Parameters:
  • name (str) – Name of the jobscript, also used for input and output file of the software to run.

  • inpDirPath (str) – Directory path to store the jobscript.

  • keywordLine (str, optional) – The line of keywords specification for Gaussian job.

  • mem (Union[int,str]) – Amount of memory to request for the Gaussian job.

  • ncpus (Union[int,str]) – Number of CPUs to request for the job.

  • combination (str) – Keyword for DFT method and basis set specification in Gaussian.

  • scrf (str) – Keyword for solvent specification in Gaussian.

  • freq (str) – Keyword for force constant and resulting vibrational frequencies computation in Gaussian.

  • grid (str) – Keyword for grid specification in Gaussian.

  • charge (int) – Charge of the molecule (pay special attention if you have a transition state).

  • spin (int) – Spin of the molecule.

  • verbose (bool) – Whether to display details of the process.

qmmd.qmcalc.genScripts.writeHPCJobScript(name: str, inpDirPath: str = '.', scheduler: str = 'pbs', cluster: str = 'gadi', ncpus: int | str = 8, walltime: str = '24:00:00', vmem: int | str = 8000, jobfs: int | str = 9000, project: str = 'p39', software: str = 'g16', version: str = 'c01', verbose: bool = False) None[source]

Generate a HPC jobscript based on specified inputs.

Parameters:
  • name (str) – Name of the jobscript, also used for input and output file of the software to run.

  • inpDirPath (str) – Directory path to store the jobscript.

  • scheduler (str) – Scheduler to submit the job to.

  • cluster ({'gadi', 'uq-rcc'}) – Cluster to run the job on.

  • ncpus (Union[int,str]) – Number of CPUs to request for the job.

  • walltime (str) – Wall time to request for the job.

  • vmem (Union[int,str]) – Amount of memory to request for the HPC job.

  • jobfs (Union[int,str]) – Amount of Jobfs memory to request for the job.

  • project (str) – Project ID on NCI Gadi, only used if ‘cluster’ = ‘gadi’.

  • software (str) – Gaussian software name to use for the job.

  • version (str) – Version of the Gaussian software.

  • verbose (bool) – Whether to display details of the process.

Notes

  • If your HPC system does not use PBS jobscript modifications will be needed for the function (open an issue on GitHub!).

  • Feel free to change the default values according to your most commonly used settings.

qmmd.qmcalc.genScripts.genAllScripts(inpDirPath: str, keywordLine: str | None = None, method: str = 'm062x', basisSet: str = '6-311+g(d,p)', solvent: str = 'water', solventModel: str = 'cpcm', mem: int | str = 4000, ncpus: int | str = 8, calcType: str = 'GOVF', charge: int = 0, spin: int = 1, scheduler: str = 'pbs', cluster: str = 'gadi', walltime: str = '24:00:00', vmem: int | str = 8000, jobfs: int | str = 9000, project: str = 'p39', software: str = 'g16', version: str = 'c01', verbose: bool = False) None[source]

Generate Gaussian input job files and submission files for molecules under all directories under a specified directory (‘inpDirPath’).

Parameters:
  • inpDirPath (str) – Directory path to the input directories.

  • keywordLine (str, optional) – The line of keywords specification for Gaussian job, the other input arguments will be used to compose the line if it is not provided.

  • method (str) – Keyword for DFT method specification in Gaussian.

  • basisSet (str) – Keyword for basis set specification in Gaussian.

  • solvent (str) – Keyword for solvent specification in Gaussian.

  • solventModel (str) – Keyword for SCRF method specification in Gaussian.

  • mem (Union[int,str]) – Amount of memory to request for the Gaussian job.

  • ncpus (Union[int,str]) – Number of CPUs to request for the job.

  • calcType (str) – Type of calculation (e.g. ‘GOVF’ for normal geometry optimisation; ‘TSGOVF’ for transition state geometry optimisation, ‘SPEiS’ for single point energy calculation, refer to ‘keywordDict’ for other options).

  • charge (int) – Charge of the molecule (pay special attention if you have a transition state).

  • spin (int) – Spin of the molecule.

  • scheduler (str) – Scheduler to submit the job to.

  • cluster ({'gadi', 'uq-rcc'}) – Cluster to run the job on.

  • walltime (str) – Wall time to request for the job.

  • vmem (Union[int,str]) – Amount of memory to request for the HPC job.

  • jobfs (Union[int,str]) – Amount of Jobfs memory to request for the job.

  • software (str) – Gaussian software name to use for the job.

  • version (str) – Version of the software.

  • verbose (bool) – Whether to display details of the process.

Notes

  • Users should organise their directories such that a directory is created for each molecule to be calculated, and all of these directories should be placed under the specified directory that this function takes in (‘inpDirPath’)

qmmd.qmcalc.genScripts.inpDirPath = '/mnt/c/Users/ASUS/Documents/qmmd/src/qmmd/data/exampleXYZs'