spycci.tools sub-module

split_multixyz function

spycci.tools.split_multixyz(mol, file, suffix='', charge=None, spin=None, engine=None, remove_xyz_files=False)

Splits a .xyz file containing multiple structures into individual structures.

Parameters:
  • mol (System object) – Input molecule, giving the charge/spin (if not defined) and name of the output molecules

  • file (str) – .xyz file containing the multiple structures

  • suffix (str, optional) – suffix to add to the new molecule names. By default, empty.

  • charge (int, optional) – Charge of the output molecules, by default the same as the input molecule

  • spin (int, optional) – Spin of the output molecules, by default the same as the input molecule

  • engine (Engine, optional) – The engine used to produce the multiple xyz file (If given and if available, the energies included in the comment line will be added to each system parsed)

  • remove_xyz_files (bool) – If set to True will remove the temporary .xyz files used in generating the System list

Returns:

molecules_list – List containing the individual System object, whose structure is taken from the .xyz file

Return type:

list


compress_dftb_trajectory function

spycci.tools.compress_dftb_trajectory(filename, md_out='md.out', geo_xyz='geo_end.xyz')

Parses a geo_end.xyz trajectory and an md.out file to export a single compressed trajectory file also containing the energies for all frames

Parameters:
  • filename (str) – name of the output trajectory files

  • md_out (str, optional) – path to the md.out file containing energy info (by default, ./md.out)

  • geo_xyz (str, optional) – path to the geo_end.xyz file containing energy info (by default, ./geo_end.xyz)


maxdist function

spycci.tools.maxdist(inputmol, charge=None, output_format=None, no_charged_fragments=True, ignore_chiral=True, use_huckel=True)
Parameters:

inputmol (System) –


cyclization_check function

spycci.tools.cyclization_check(start_file, end_file)

Checks if a cyclization has occurred (e.g., during a geometry optimization), or if a ring opening has occurred.

Parameters:
  • start_file (str) – .xyz file containing the starting geometry

  • end_file (str) – .xyz file containing the final geometry

Return type:

If a change in the number of rings is detected, returns True.


dissociation_check function

spycci.tools.dissociation_check()

Checks if a dissociation has occurred (e.g., during a geometry optimization). Requires the presence of a .mol file in the current directory.

Returns:

  • True, if a dissociation is detected

  • False, if a dissociation is not detected


process_output function

spycci.tools.process_output(mol, method, calc, charge=None, spin=None, save_cubes=False)

Processes the output of a calculation, copying the output files to a safe directory (output_files) in the parent directory tree, and cleans the temporary directory if requested.

Parameters:
  • mol (System object) – Systems processed in the calculation

  • method (str) – String indicating the level of theory for the calculation

  • calc (str) – Type of calculation

  • charge (int, optional) – Charge of the molecule in the calculation

  • spin (int, optional) – Spin of the molecule in the calculation

  • save_cubes (bool) – If set to true will copy the .cube files in a safe directory (output_densities) in the parent directory tree


save_dftb_trajectory function

spycci.tools.save_dftb_trajectory(output_prefix)

Saves the geo_end.xyz and md.out files to a temporary directory where an MDTrajectory object can go read the data it needs.

Parameters:

output_prefix (str) – name of the output trajectory files prefix


reorder_energies function

spycci.tools.reorder_energies(system_list, ncores=None, maxcore=350, method_opt=None, method_el=None, method_vib=None)

Reorders a System list (generated by a CREST routine such as deprotonation) at a different level of theory.

Parameters:
  • system_list (list(System)) – list containing the System objects to be reordered (e.g., generated by a CREST routine)

  • ncores (int, optional) – number of cores, by default all available cores

  • maxcore (int, optional) – memory per core, in MB, by default 350

  • method_opt (XtbInput/OrcaInput, optional) – level of theory for the geometry optimization. By default converted to gfn2

  • method_el (XtbInput/OrcaInput, optional) – level of theory for the electronic part of the energy. By default converted to M06-2X

  • method_vib (XtbInput/OrcaInput, optional) – level of theory for the vibronic contribution to the energy. By default converted to gfn2

Returns:

molecule_list – System list, reordered at the new level of theory.

Return type:

list(System)

spycci.tools.vmdtools sub-module

spycci.tools.vmdtools.render_condensed_fukui(cubfile, resolution=4800, shadows=True, ambientocclusion=True, dof=True, VMD_PATH=None)

Given the path to a Fukui function cube file saves a .bmp render of the condensed Fukui functions.

Parameters:
  • cubefile (str) – The path to the .fukui.cube file that must be rendered.

  • resolution (int) – The resolution of the output image (default: 4800).

  • shadows (bool) – If set to True will enable the vmd shadows option

  • ambientocclusion (bool) – If set to True will enable the vmd ambientocclusion option

  • dof (bool) – If set to True will enable the vmd dof option

  • VMD_PATH (str) – The path to the vmd folder. Is set to None (default), will automatically search vmd in the system PATH.

  • cubfile (str) –

Return type:

None

spycci.tools.vmdtools.render_fukui_cube(cubfile, isovalue=0.003, include_negative=False, resolution=4800, shadows=True, ambientocclusion=True, dof=True, VMD_PATH=None)

Given the path to a Fukui function cube file saves a .bmp render the volumetric Fukui function.

Parameters:
  • cubefile (str) – The path to the .fukui.cube file that must be rendered.

  • isovalue (float) – The isovalue at which the contour must be plotted (default: 0.003).

  • include_negative (bool) – If set to True, will render also the negative part of the Fukui function. (default: False)

  • resolution (int) – The resolution of the output image (default: 4800).

  • shadows (bool) – If set to True will enable the vmd shadows option

  • ambientocclusion (bool) – If set to True will enable the vmd ambientocclusion option

  • dof (bool) – If set to True will enable the vmd dof option

  • VMD_PATH (str) – The path to the vmd folder. Is set to None (default), will automatically search vmd in the system PATH.

  • cubfile (str) –

Return type:

None

spycci.tools.vmdtools.render_spin_density_cube(cubfile, isovalue=0.005, resolution=4800, shadows=True, ambientocclusion=True, dof=True, VMD_PATH=None)

Given the path to a spin density cube file saves a .bmp render the function.

Parameters:
  • cubefile (str) – The path to the .fukui.cube file that must be rendered.

  • isovalue (float) – The isovalue at which the contour must be plotted (default: 0.003).

  • resolution (int) – The resolution of the output image (default: 4800).

  • shadows (bool) – If set to True will enable the vmd shadows option

  • ambientocclusion (bool) – If set to True will enable the vmd ambientocclusion option

  • dof (bool) – If set to True will enable the vmd dof option

  • VMD_PATH (str) – The path to the vmd folder. Is set to None (default), will automatically search vmd in the system PATH.

  • cubfile (str) –

Return type:

None

spycci.tools.moglitools sub-module