schrodinger.application.jaguar.csmiles.conformer_smiles module¶
CSMILES - Conformer SMILES
This is a prototype implementation for encoding conformer information into SMILES strings. Please refer to https://pubs.acs.org/doi/abs/10.1021/acs.jcim.5c01613 for detailed discussion of the algorithm and considerations.
Broadly, CSMILES strings are formatted as conventional SMILES with added information describing bond dihedral angles placed by the SMILES bonds, e.g:
'C{30}C{60}C{90}C{120}O'
describes a specific conformer of 1-butanol, such that the first dihedral is 30 degrees, the second is 60, the third is 90, and the final is 120. Applying these angles to the dihedrals recovers the conformer encoded, assuming standard bond lengths and angles.
The present implementation serves as a functional prototype only.
- schrodinger.application.jaguar.csmiles.conformer_smiles.encode_mode_driver(structs: list[rdkit.Chem.rdchem.Mol], args: Namespace)¶
Driver function for CLI encoding tasks.
- Parameters:
structs – List of Mol objects to be encoded.
args – Command line options.
- schrodinger.application.jaguar.csmiles.conformer_smiles.decode_mode_driver(csmiles_strings: list[str], args: Namespace)¶
Driver function for CLI decoding.
- Parameters:
csmiles_strings – List of CSMILES strings to be decoded.
args – Command line options.
- schrodinger.application.jaguar.csmiles.conformer_smiles.diff_csmiles_mode_driver(csmiles_list: list[str], args: Namespace)¶
Driver for computing the CSMILES torsion differences between a set of CSMILES strings. All strings must parse to the same molecular graph, but do not have to be canonical.
- Parameters:
csmiles_list – The list of CSMILES strings to decode.
args – The command line arguments.
- schrodinger.application.jaguar.csmiles.conformer_smiles.diff_structure_mode_driver(structs: list[rdkit.Chem.rdchem.Mol], args: Namespace)¶
Driver for computing the CSMILES torsion differences between a set of structures.
- Parameters:
structs – List of structures to compute the diff for. The first structure in the list is taken as the reference against which the diff is computed.
args – The command line arguments.
- schrodinger.application.jaguar.csmiles.conformer_smiles.write_output_files(out_path: Path, structure_list: list[rdkit.Chem.rdchem.Mol], save_constraints: bool, constraint_list: list[dict[tuple[int, int, int, int], float]], ring_close_idxs_list: list[list[tuple[int, int]]])¶
Write the decoded structures to a file, determining the appropriate writer from the outfile’s suffix. If requested in
argsalso write a file recording the dihedral constraints and ring-close indices to a separate file.If .xyz format is requested and multiple structures were decoded then the files will be enumerated with
out_pathas the base file name.- Parameters:
out_path – The file path for the output structure file. The file suffix determines the format written.
structure_list – The list of decoded structures to be written.
save_constraints – Flag that we should record the dihedral constraints and ring-close indices to a file.
constraint_list – The list of dictionaries mapping dihedral indices to dihedral angle.
ring_close_idxs_list – The list of ring close bond indices.
- Raises:
RuntimeError – If the file format cannot be understood.
- schrodinger.application.jaguar.csmiles.conformer_smiles.main()¶
Execute script functionality
- schrodinger.application.jaguar.csmiles.conformer_smiles.parse_command_line()¶
Parse command line arguments