Skip to content

Commit 20df1b9

Browse files
committed
Update dev docs
1 parent 0b21db9 commit 20df1b9

15 files changed

+165
-25
lines changed

docs/changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ nav_order: 2
77
# Change Log
88

99
## 2025.4.14
10+
* SYMPREC is now properly rounded when they are modified by custodian.
1011
* PR #362 from @Andrew-S-Rosen (#362)
1112
Anytime that we modify NCORE, we should also unset NPAR if it's present in the INCAR file since NPAR takes precedence. This is done throughout Custodian, but there was one spot missing it. I added it in.
1213
* PR #356 from @esoteric-ephemera (#356)

docs/custodian.ansible.interpreter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ Examples:
3636
Initializes a Modder from a list of supported actions.
3737

3838
* **Parameters**
39-
* **actions** (*[**Action**]*) – A sequence of supported actions. See
39+
* **actions** ( *[**Action**]*) – A sequence of supported actions. See
4040
[`custodian.ansible.actions`](custodian.ansible.actions.md#module-custodian.ansible.actions). Default is None,
4141
which means only DictActions are supported.
4242
* **strict** (*bool*) – Indicating whether to use strict mode. In non-strict

docs/custodian.cp2k.interpreter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ Initializes a Modder for Cp2kInput sets
2020
* **Parameters**
2121
* **filename** (*str*) – name of cp2k input file to modify. This file will be overwritten
2222
if actions are applied.
23-
* **actions** (*[**Action**]*) – A sequence of supported actions. See
23+
* **actions** ( *[**Action**]*) – A sequence of supported actions. See
2424
[`custodian.ansible.actions`](custodian.ansible.actions.md#module-custodian.ansible.actions). Default is None,
2525
which means DictActions and FileActions are supported.
2626
* **strict** (*bool*) – Indicating whether to use strict mode. In non-strict

docs/custodian.cp2k.jobs.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ of the static constructors. The defaults are usually fine too.
3737
* **backup** (*bool*) – Whether to backup the initial input files. If True,
3838
the input file will be copied with a
3939
“.orig” appended. Defaults to True.
40-
* **settings_override** (*[**actions**]*) – A list of actions. See the Cp2kModder
40+
* **settings_override** ( *[**actions**]*) – A list of actions. See the Cp2kModder
4141
in interpreter.py
4242
* **restart** (*bool*) – Whether to run in restart mode, i.e. this a continuation of
4343
a previous calculation. Default is False.

docs/custodian.custodian.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,11 @@ every 30 x 10 = 300 seconds, i.e., 5 minutes. -->
5252
Initializes a Custodian from a list of jobs and error handlers.
5353

5454
* **Parameters**
55-
* **handlers** (*[**ErrorHandler**]*) – Error handlers. In order of priority of
55+
* **handlers** ( *[**ErrorHandler**]*) – Error handlers. In order of priority of
5656
fixing.
57-
* **jobs** (*[**Job**]*) – Sequence of Jobs to be run. Note that this can be
57+
* **jobs** ( *[**Job**]*) – Sequence of Jobs to be run. Note that this can be
5858
any sequence or even a generator yielding jobs.
59-
* **validators** (*[**Validator**]*) – Validators to ensure job success
59+
* **validators** ( *[**Validator**]*) – Validators to ensure job success
6060
* **max_errors_per_job** (*int*) – Maximum number of errors per job allowed
6161
before exiting. Defaults to None, which means it is set to be
6262
equal to max_errors..

docs/custodian.feff.interpreter.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Bases: [`Modder`](custodian.ansible.interpreter.md#custodian.ansible.interpreter
1515
A Modder for FeffInput sets
1616

1717
* **Parameters**
18-
* **actions** (*[**Action**]*) – A sequence of supported actions. See
18+
* **actions** ( *[**Action**]*) – A sequence of supported actions. See
1919
* **actions** – A sequence of supported actions. See
2020
[`custodian.ansible.actions`](custodian.ansible.actions.md#module-custodian.ansible.actions). Default is None,
2121
which means DictActions and FileActions are supported.

docs/custodian.gaussian.handlers.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -41,17 +41,17 @@ Initialize the GaussianErrorHandler class.
4141
be monitored and plotted (convergence criteria versus cycle number) and
4242
saved to a file called ‘convergence.png’.
4343

44-
### GRID_NAMES *= (‘finegrid’, ‘fine’, ‘superfinegrid’, ‘superfine’, ‘coarsegrid’, ‘coarse’, ‘sg1grid’, ‘sg1’, ‘pass0grid’, ‘pass0’)*
44+
### GRID_NAMES *= (‘finegrid’, ‘fine’, ‘superfinegrid’, ‘superfine’, ‘coarsegrid’, ‘coarse’, ‘sg1grid’, ‘sg1’, ‘pass0grid’, ‘pass0’)*
4545

46-
### MEM_UNITS *= (‘kb’, ‘mb’, ‘gb’, ‘tb’, ‘kw’, ‘mw’, ‘gw’, ‘tw’)*
46+
### MEM_UNITS *= (‘kb’, ‘mb’, ‘gb’, ‘tb’, ‘kw’, ‘mw’, ‘gw’, ‘tw’)*
4747

48-
### activate_better_guess *= False*
48+
### activate_better_guess *= False*
4949

5050
### check(directory: str = ‘./’)
5151

5252
Check for errors in the Gaussian output file.
5353

54-
### conv_criteria\*: ClassVar\* *= {‘max_disp’: re.compile(’\\s+(Maximum Displacement)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘max_force’: re.compile(’\\s+(Maximum Force)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘rms_disp’: re.compile(’\\s+(RMS {5}Displacement)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘rms_force’: re.compile(’\\s+(RMS {5}Force)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’)}*
54+
### conv_criteria\*: ClassVar\* *= {‘max_disp’: re.compile(’\\s+(Maximum Displacement)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘max_force’: re.compile(’\\s+(Maximum Force)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘rms_disp’: re.compile(’\\s+(RMS {5}Displacement)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’), ‘rms_force’: re.compile(’\\s+(RMS {5}Force)\\s+(-?\\d+.?\\d\*|.\*)\\s+(-?\\d+.?\\d\*)’)}*
5555

5656
### *static* convert_mem(mem: float, unit: str)
5757

@@ -71,13 +71,13 @@ Convert memory size between different units to megabytes (MB).
7171

7272
Perform necessary actions to correct the errors in the Gaussian output.
7373

74-
### error_defs\*: ClassVar\* *= {‘A syntax error was detected in the input line.’: ‘syntax’, ‘Atom specifications unexpectedly found in input stream.’: ‘found_coords’, ‘Bad file opened by FileIO’: ‘bad_file’, ‘Convergence failure’: ‘scf_convergence’, ‘End of file in ZSymb’: ‘zmatrix’, ‘End of file reading connectivity.’: ‘coords’, ‘Error in internal coordinate system’: ‘internal_coords’, ‘FileIO operation on non-existent file.’: ‘missing_file’, ‘FormBX had a problem’: ‘linear_bend’, ‘Inv3 failed in PCMMkU’: ‘solute_solvent_surface’, ‘Linear angle in Tors.’: ‘linear_bend’, ‘No data on chk file.’: ‘empty_file’, ‘Optimization stopped’: ‘opt_steps’, ‘Out-of-memory error in routine’: ‘insufficient_mem’, ‘The combination of multiplicity ([0-9]+) and \\s+? ([0-9]+) electrons is impossible.’: ‘charge’, ‘There are no atoms in this input structure !’: ‘missing_mol’, ‘Z-matrix optimization but no Z-matrix variables.’: ‘coord_inputs’}*
74+
### error_defs\*: ClassVar\* *= {‘A syntax error was detected in the input line.’: ‘syntax’, ‘Atom specifications unexpectedly found in input stream.’: ‘found_coords’, ‘Bad file opened by FileIO’: ‘bad_file’, ‘Convergence failure’: ‘scf_convergence’, ‘End of file in ZSymb’: ‘zmatrix’, ‘End of file reading connectivity.’: ‘coords’, ‘Error in internal coordinate system’: ‘internal_coords’, ‘FileIO operation on non-existent file.’: ‘missing_file’, ‘FormBX had a problem’: ‘linear_bend’, ‘Inv3 failed in PCMMkU’: ‘solute_solvent_surface’, ‘Linear angle in Tors.’: ‘linear_bend’, ‘No data on chk file.’: ‘empty_file’, ‘Optimization stopped’: ‘opt_steps’, ‘Out-of-memory error in routine’: ‘insufficient_mem’, ‘The combination of multiplicity ([0-9]+) and \\s+? ([0-9]+) electrons is impossible.’: ‘charge’, ‘There are no atoms in this input structure !’: ‘missing_mol’, ‘Z-matrix optimization but no Z-matrix variables.’: ‘coord_inputs’}*
7575

76-
### error_patt *= re.compile(‘Optimization stopped|Convergence failure|FormBX had a problem|Linear angle in Tors.|Inv3 failed in PCMMkU|Error in internal coordinate system|End of file in ZSymb|There are no atoms in this input str)*
76+
### error_patt *= re.compile(‘Optimization stopped|Convergence failure|FormBX had a problem|Linear angle in Tors.|Inv3 failed in PCMMkU|Error in internal coordinate system|End of file in ZSymb|There are no atoms in this input str)*
7777

78-
### grid_patt *= re.compile(‘(-?\\d{5})’)*
78+
### grid_patt *= re.compile(‘(-?\\d{5})’)*
7979

80-
### recom_mem_patt *= re.compile(‘Use %mem=([0-9]+)MW to provide the minimum amount of memory required to complete this step.’)*
80+
### recom_mem_patt *= re.compile(‘Use %mem=([0-9]+)MW to provide the minimum amount of memory required to complete this step.’)*
8181

8282
## *class* custodian.gaussian.handlers.WallTimeErrorHandler(wall_time: int, buffer_time: int, input_file: str, output_file: str, stderr_file: str = ‘stderr.txt’, prefix: str = ‘error’)
8383

@@ -110,7 +110,7 @@ Check if the job is nearing the walltime. If so, return True, else False.
110110

111111
Perform the corrections.
112112

113-
### is_monitor\*: bool\* *= True*
113+
### is_monitor\*: bool\* *= True*
114114

115115
This class property indicates whether the error handler is a monitor,
116116
i.e., a handler that monitors a job as it is running. If a

docs/custodian.jdftx.jobs.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
layout: default
3+
title: custodian.jdftx.jobs.md
4+
nav_exclude: true
5+
---
6+
7+
# custodian.jdftx.jobs module
8+
9+
This module implements basic kinds of jobs for JDFTx runs.
10+
11+
### *class* custodian.jdftx.jobs.JDFTxJob(jdftx_cmd, input_file='init.in', output_file='jdftx.out', stderr_file='std_err.txt')
12+
13+
Bases: `Job`
14+
15+
A basic JDFTx job. Runs whatever is in the working directory.
16+
17+
* **Parameters:**
18+
* **jdftx_cmd** (*str*) – Command to run JDFTx as a string.
19+
* **input_file** (*str*) – Name of the file to use as input to JDFTx
20+
executable. Defaults to “init.in”
21+
* **output_file** (*str*) – Name of file to direct standard out to.
22+
Defaults to “jdftx.out”.
23+
* **stderr_file** (*str*) – Name of file to direct standard error to.
24+
Defaults to “std_err.txt”.
25+
26+
#### postprocess(directory='./') → None
27+
28+
No post-processing required.
29+
30+
#### run(directory='./')
31+
32+
Perform the actual JDFTx run.
33+
34+
## Returns:
35+
36+
> (subprocess.Popen) Used for monitoring.
37+
38+
#### setup(directory='./') → None
39+
40+
No setup required.
41+
42+
#### terminate(directory='./') → None
43+
44+
Terminate JDFTx.
45+
46+
#### *static* terminate_process(proc, timeout=5)
47+
48+
Terminate a process gracefully, then forcefully if necessary.

docs/custodian.jdftx.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
---
2+
layout: default
3+
title: custodian.jdftx.md
4+
nav_exclude: true
5+
---
6+
7+
# custodian.jdftx package
8+
9+
This package implements various JDFTx Jobs and Error Handlers.
10+
Used Cp2kJob developed by Nick Winner as a template.
11+
12+
13+
* [custodian.jdftx.jobs module](custodian.jdftx.jobs.md)
14+
* [`JDFTxJob`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob)
15+
* [`JDFTxJob.postprocess()`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob.postprocess)
16+
* [`JDFTxJob.run()`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob.run)
17+
* [`JDFTxJob.setup()`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob.setup)
18+
* [`JDFTxJob.terminate()`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob.terminate)
19+
* [`JDFTxJob.terminate_process()`](custodian.jdftx.jobs.md#custodian.jdftx.jobs.JDFTxJob.terminate_process)

docs/custodian.nwchem.jobs.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ A basic Nwchem job.
1717
Initializes a basic NwChem job.
1818

1919
* **Parameters**
20-
* **nwchem_cmd** (*[**str**]*) – Command to run Nwchem as a list of args. For
20+
* **nwchem_cmd** ( *[**str**]*) – Command to run Nwchem as a list of args. For
2121
example, [“nwchem”].
2222
* **input_file** (*str*) – Input file to run. Defaults to “mol.nw”.
2323
* **output_file** (*str*) – Name of file to direct standard out to.
@@ -27,7 +27,7 @@ Initializes a basic NwChem job.
2727
Defaults to True.
2828
* **gzipped** (*bool*) – Deprecated. Please use the Custodian class’s
2929
gzipped_output option instead.
30-
* **settings_override** (*[**dict**]*) – An ansible style list of dict to override changes.
30+
* **settings_override** ( *[**dict**]*) – An ansible style list of dict to override changes.
3131
#TODO: Not implemented yet.
3232

3333
### postprocess()

0 commit comments

Comments
 (0)