inputgen

Create an APBS input file using psize data.

Code author: Todd Dolinsky

Code author: Nathan Baker

class pdb2pqr.inputgen.Input(pqrpath, size, method, asyncflag, istrng=0, potdx=False)[source]

Each object of this class is one APBS input file.

__init__(pqrpath, size, method, asyncflag, istrng=0, potdx=False)[source]

Initialize the input file class.

Each input file contains a PQR name, a list of elec objects, and a list of strings containing print statements. For starters, assume two ELEC statements are needed, one for the inhomgenous and the other for the homogenous dielectric calculations.

Note

This assumes you have already run psize, either by size.run_psize(...)() or size.parse_string(...)() followed by size.set_all().

Parameters
  • pqrpath (str) – path to PQR file

  • size (Psize) – parameter sizing object

  • method (str) – solution method (e.g., mg-para, mg-auto, etc.)

  • asyncflag (bool) – perform an asynchronous parallel focusing calculation

  • istrng – ionic strength/concentration (M)

  • potdx (bool) – whether to write out potential information in DX format

print_input_files(output_path) List[str][source]

Generate the input file(s) associated with this object.

Parameters

output_path (str) – location for generated files

Returns

List of file paths which were generated

Return type

List[str]

pdb2pqr.inputgen.get_cli_args(args_str: Optional[str] = None) argparse.Namespace[source]

Define and parse command line arguments via argparse.

Parameters

args_str (str) – String representation of command line arguments

Returns

Parsed arguments object

Return type

argparse.Namespace

pdb2pqr.inputgen.main()[source]

Main driver

pdb2pqr.inputgen.split_input(filename: pathlib.Path, stem: Optional[str] = None) List[str][source]

Split the parallel input file into multiple async file names.

Parameters
  • filename (str) – the path to the original parallel input file

  • stem (str) – an optional file prefix for name

Returns

List of file paths which were generated

Return type

List[str]