Changelog

Version 0.4.0

Enhancements:

  • The strct.Structure and strct.StructureOperations now implement the function create_supercell which replicates the unit cell forming a supercell (PR #136).

  • plots.simpleplot.import_bar_data_set added new parameter y_error to add errors to height for backend matplotlib (PR #140).

  • strct.StructureOperations implements now the pipeline property and the run_pipeline function used to apply a series of manipulation methods at once (PR #144).

  • strct.Structure offers now an interface to the openmm Python package (PR #145).

  • io.read_fhiaims_proj_dos now also supports spin-polarized pDOS output files (PR #152).

  • aim2dat.aiida_workflows.utils:add_molecule, aim2dat.aiida_workflows.utils:find_equivalent_sites, and aim2dat.aiida_workflows.utils:rotate_molecule were added as a calcfunction (PR #153).

  • A workflow was added to calculate the adsorption energies [cp2k-adsorption-mofs-*] (PR #153, PR #184).

  • Hybrid functionals PBE0 and HSE06 with the ADMM method were implemented. As well as rVV10 and D3 dispersion corrections for R2SCAN and the hybrid functionals (PR #153).

  • aiida_workflows.cp2k.base_opt_work_chain._BaseOptimizationWorkChain contains now the option to fix atoms optimization_p.fixed_atoms and also to ignore scf convergence failure ignore_convergence_failure (PR #153).

  • aiida_workflows.MultipleWorkflowBuilder offers the possibility with return_remote_runtimes to return only the sum of remote runtimes for each task (PR #155).

  • aiida_workflows.cp2k.pdos_work_chain.PDOSWorkChain contains now the option to print the local PDOS, projected on subsets of atoms given through lists ldos (PR #158).

  • Newly implemented function strct.ext_analysis.calc_hydrogen_bonds to search for hydrogen bonds in a strct.Structure object (PR #167)

  • strct.ext_analysis.add_structure_coord grid search is now improved by a grid search in a sphere around the host atoms. Additionally, rotate_guest allows to rotate the guest until minimum is found (PR #168, PR #176, PR #180, PR #181).

  • plots.simple_plot added new property edge_color and line_width to set the color and thickness of the edges for bar plots for backend matplotlib (PR #169).

  • The strct.Structure class has the new from_str classmethod to initialize an object from string, using pre-defined stored structures (PR #170).

  • The read_yaml_file function now has the read_structure decorator to integrate into the io-interface of the strct.Structure class (PR #170).

  • The WorkflowBuilder and MultipleWorkflowBuilder can be imported directly via the __init__.py file of the sub-package (PR #174).

  • aim2dat/aiida_workflows/chargemol/parsers and aim2dat/io/critic2 retrieves runtime of the calculation and includes it in the result_dict (PR #174).

  • The strct.Structure.calc_coordination now allows to calculate the coordination environment for a subset of sites and has the option to omit the statistics; the strct.Structure.calc_distance method with use_supercell=True as well as the strct.ext_manipulation.add_structure_coord functions are now faster for larger structures (PR #177).

  • Newly implemented workchain aiida_workflows.cp2k.interaction_energy_work_chain to calculate interaction energies including counter poise correction (PR #184)

Fixes:

  • The strct.Structure.calculate_distance method was not always returning the smallest distance when backfold_positions=True since only the second site position was backfolded (PR #139).

  • The strct.Structure object wouldn’t update the positions if a cell is added or altered after initialization (PR #141).

  • The strct.Structure.calculate_distance method was considering periodic images also if pbc was set to False (PR #141).

  • The strct.ext_manipulation.add_structure_coord didn’t apply distance checks if distance constraints were applied (PR #147).

  • The io.read_cp2k_restart_structure function was wrongly taking the reference cell instead of the actual unitcell (PR #149).

  • The find_scf_parameters were not restarted if the mixing parameters were not found (PR #153).

  • The aiida_workflows.cp2k.core_work_chain_handlers._resubmit_calculation function takes care of restarting CP2K calculations when walltime is hit or no output for CP2K was created due to connection issues (PR #157, PR #184).

  • The strct.ext_manipulation.add_structure_coord function threw an error when the host or guest indices were larger than the number of sites of the corresponding structure (PR #165).

  • The read/write functions to hdf5-files of the strct.StructureCollection class are finetuned to be more data-efficient (PR #170).

  • The aiida_workflows.cp2k.parsers._Cp2kBaseParser.parse takes care of the exit_codes if WALLTIME is hit by Slurm or CP2K, as well fixes the error that if calculation was interrupted an SCF error arose instead (PR #171).

  • The aiida_workflows.protocols.*.yaml/chargemol.parameters->partial_charges was fixed since the values were taken as three key parameters instead of one whole key (PR #174).

  • The plots.simple_plot is fixed for bar plots including colors and alpha for the matplotlib backend (PR #175).

  • The elements.get_element_groups now returns the groups of all 118 elements of the periodic table, the missing entries for ‘Ce’, ‘Fr’ and ‘Ra’ were added (PR #179).

  • The aiida_workflows.cp2k.parameter_files.basis_sets STANDARD basis sets and potentials were overwritten by UZH. Now, both options are implemented (PR #183).

Breaking Changes:

  • All functions of the io sub-package have been renamed and are imported directly via the __init__.py file of the sub-package (PR #133)

  • The creation of supercells for the calculation of coordination environments and other features has been sped up substantially (PR #136).

  • The utils.element_properties.get_atomic_radius function now relies entirely internal values taken from doi:10.1039/B801115J ('covalent'), doi:10.1039/C3DT50599E ('vdw'), doi:10.1039/C9RA07327B ('chen_manz'), and doi:10.26434/chemrxiv-2024-m3rtp-v2 ('vdw_charry_tkatchenko') instead of ase (PR #138).

  • Support for the MP legacy interface via pymatgen is removed from the strct.StructureImporter class since it is no longer supported by pymatgen (PR #142).

  • If a maximum value is given in dist_threshold of the strct.ext_manipulation.add_structure_* functions, only one atom is considered for the criteria to be fulfilled (PR #151).

  • The number of SCF iterations in the OT method for CP2K workflows were reduced from 40 to 25 and 50 to 25 (PR #153).

  • The BASIS_SET_FILE_NAME and POTENTIAL_FILE_NAME was changed from [BASIS_MOLOPT, BASIS_MOLOPT_UCL] to BASIS_MOLOPT_UZH and from GTH_POTENTIALS to POTENTIAL_UZH for CP2K workflows. Additionally, the PBE functional includes GGA in its BASIS_SET and POTENTIAL for each KIND. SCAN thus includes MGGA instead of SCAN. Shortrange SR for most metals become redundant by introducing BASIS_MOLOPT_UZH (PR #153).

  • The bond distance from the hydrogen molecule was reduced from 0.909862 to 0.74 (PR #153).

  • The Materials Project openAPI interface does not support ICSD IDs anymore, instead the new key theoretical is added (PR #154).

  • aiida_workflows.cp2k.pdos_work_chain.PDOSWorkChain.resolve_atoms resolves the atoms now via local PDOS instead of changing each atom in a separate kind (PR #158).

  • The chem_formula, units and element_properties modules from the aim2dat.utils sup-package are moved to the new sub-packages: chem_f, units and elements to reduce the import paths; all element properties are now stored internally, instead of relying on the ase implementation (PR #159).

  • strct.Structure.attributes are now completely mutable for more straight-forward use (PR #170 and PR #173).

  • The strct.StructureCollection io-function are now aligned with the strct.Structure class, replacing the StructureCollection.import_* and StructureCollection.store_* with StructureCollection.from_* and StructureCollection.to_* functions, respectively (PR #170).

  • The interface of the strct.StructureCollection towards pandas data frames now adds a column to the data frame containing the strct.Structure objects, thus, the interface is now circular and the new StructureCollection.from_pandas_df method can be used initiate a strct.StructureCollection object from a data frame (PR #170).

Version 0.3.0

Enhancements:

  • A parser for xml output files of Quantum ESPRESSO is added (PR #102).

  • Added interface to MOFXDB (https://mof.tech.northwestern.edu/) to the strct.StructureImporter class (PR #94).

  • The strct.Structure class checks now for duplicate positions upon initialization (PR #107).

  • strct.ext_analysis.determine_molecular_fragments offers additional parameters, allowing to exclude sites and restricting the size of the fragments (PR #111).

  • Slight speed-up in distance based methods to calculate the coordination environment by sorting the pair-wise distances first.

  • Added utils.element_properties.get_val_electrons function to return the number of valence electrons of the element (PR #113).

  • Support CP2K versions 2025.1 (PR #114).

  • Implemented BSSE parsing to io.cp2k.read_stdout function (PR #115 and PR #116).

  • Added more units and fundamental constants to utils.units (PR #122).

  • The strct.Structure.calculate_angle and strct.Structure.calculate_dihedral_angle now supports lists and None as input (PR #126).

  • Several new functions have been added to the strct.ext_manipulation module, including add_structure_position, translate_structure or rotate_structure, each of the functions in this module now implement a common dist_threshold parameter to control the inter-atomic distances of the altered structures (PR #105, PR #123, PR #129).

  • The strct.Structure class has now the property numbers to get the atomic number related to the element (PR #130).

Fixes:

  • The internal backend of strct.Structure was not properly identifying the correct function to parse the file in all cases. Additionally, the io.cif.read_file function now uses the io.utils.custom_open function, allowing to pass on a string instead of the file path (PR #99).

  • io.cp2k.read_restart_structure function now supports parsing files with “” delimiters for string values (PR #100).

  • Improve the interface of strct.Structure to the ase Atoms class by transferring attributes to info and site_attributes to arrays (PR #103).

  • Expose strct.Structure.attributes, strct.Structure.site_attributes and strct.Structure.extras to strct.StructureCollection.append, strct.Structure.from_ase_atoms and strct.Structure.from_pymatgen_structure functions (PR #103).

  • Some str values were sometimes wrongly transformed into float numbers in the output parsers and cif parser checks more rigorously whether two atoms are occupying the same site (PR #104).

  • Fix positions returned from strct.Structure.calculate_distance function (PR #106).

  • io.cif.read_file was not properly parsing string values in loops with delimiters (”” or ‘’) and without spaces (PR #118).

  • Setting strct.Structure.site_attributes was not resetting the dictionary but instead adding the new key/value pairs (PR #125).

  • The strct.StructureOperations.compare_sites_via_coordination, strct.StructureOperations.find_eq_sites_via_coordination, strct.ext_analysis.decorator.external_analysis_method decorator now properly handles unset keyword arguments (PR #128).

Deprecations:

  • The strct.Structure.import_methods, strct.Structure.export_methods, strct.Structure.analysis_methods, strct.Structure.manipulation_methods, strct.StructureOperations.analysis_methods and strct.StructureOperations.manipulation_methods functions are now deprecated since Python dropped the support for class properties. The methods are replaced by the list_*_methods class methods, making this Package compatible with Python 3.13 (PR #132).

Breaking Changes:

  • strct.ext_analysis.determine_molecular_fragments now considers the same site multiple times if it is connected, returns a list of strct.Structure objects and does not shift the position of the first atom to zero (PR #111).

  • strct.ext_analysis.create_graph now only outputs the graphviz graph if the get_graphviz_graph parameter is set to True and networkx is added to the core dependencies (PR #112).

  • All units and constants now rely on an internal implementation which is based on CODATA 2022 instead of 2014 (PR #122).

  • The strct.Structure.calculate_distance, strct.Structure.calculate_angle and strct.Structure.calculate_dihedral_angle now return all possible combinations from the given indices instead of pairwise tuples (PR #126).

  • The strct.ext_analysis.determine_molecular_fragments, strct.ext_analysis.create_graph and strct.ext_manipulation.add_structure_coord functions now implement **cn_kwargs as container for the arguments forwarded to the strct.Structure.calculate_coordination function (PR #128).

  • The default value for the method parameter of the strct.Structure.calculate_coordination is now set to atomic_radius as this method seems more reliable and equally fast as minimum_distance (PR #128).

  • The aim2dat.strct.ext_manipulation.add_structure_random function now uses the numpy random number generator and now offers more keyword arguments to control the used random numbers (PR #134).

Version 0.2.0

Enhancements:

  • All larger parser functions moved from aiida_workflows to io such that they can used outside of the AiiDA framework (PR #20).

  • io.qe.read_total_density_of_states parses now the Fermi energy as well (PR #20).

  • plots.base_plot added new property subplot_align_ylabels to adjust y labels in subplots for backend matplotlib (PR #23).

  • strct.Structure added new file formats .cssr, .v1 and .cuc to to_file for postprocessing in Zeo++ (PR #26).

  • strct.StructureOperations now supports, in addition to a strct.StructureCollection object, a list of Structure objects upon initialization (PR #29).

  • fct.smearing functions have a new parameter sampling_width to control the distance between x-values (PR #32).

  • strct.Structure.to_dict returns a dictionary of a Structure object (PR #34).

  • Structure manipulation methods maintain kinds information and strct.Structure.substitute_elements has now the additional remove_kind parameter (PR #34).

  • utils.element_properties.get_atomic_radius supports now the set of radii determined in doi:10.1039/C9RA07327B (PR #35).

  • strct.Structure.calculate_coordination supports the calculation of the coordination environment based on the sum of the corresponding atomic radii (PR #35).

  • strct.ext_manipulation.add_structure_coord replaces the strct.ext_manipulation.add_functional_group function allowing Structure objects as input and adding methods to define the orientation and position of the guest structure in more detail (PR #37, PR #65, PR #85).

  • strct.Structure has now site attributes which store site specific information (PR #39).

  • utils.element_properties.get_atomic_radius supports now Van der Waals radii determined in doi:10.26434/chemrxiv-2024-m3rtp-v2 (PR #44).

  • An internal cif-parser is added to parse additional information (PR #47).

  • Support CP2K versions 2022.1-2024.1 (PR #51).

  • The newly implemented strct.ext_manipulation.add_structure_random function adds a guest structure at a random position and orientation (PR #53).

  • strct.Structure.from_file interfaces functions from the io sub-package via the internal 'backend' and adds more parameters to control the 'ase' backend (PR #56).

  • The methods to find duplicate structures of strct.StructureOperations are sped up by comparing the chemical formulas prior to more expensive checks (PR #61).

  • H2 is added to the pre-defined structures (PR #65).

  • io.cp2k.read_atom_proj_density_of_states now also supports LDOS files (PR #76).

  • strct.StructureOperations.compare_* functions can now be run in parallel (PR #78).

  • Added custom_hatch to all plots classes to allow plotting hatched bars using the matplotlib backend (PR #89).

Fixes:

  • utils.chem_formula.transform_str_to_dict supports now recurring elements and nested brackets (PR #13).

  • strct.Structure.calculate_voronoi_tessellation now sorts the the neighbouring sites (PR #31).

  • io.fhi_aims.read_atom_proj_density_of_states supports now higher azimuth quantum numbers up to i (PR #33).

  • External structure manipulation methods now share the same interface as their internal counterparts (PR #34).

  • A few smaller bug fixes in CP2K output parser (PR #36).

  • Fix interface to spglib to support version 2.5 and above (PR #54).

  • Small fixes to the Materials Project open-api interface (PR #58).

  • The optimade interface was not working as soon as one supplier could not be reached (PR #62).

  • strct.Structure.calculate_distance now correctly backfolds positions into the unit cell (PR #63).

  • strct.ext_manipulation.add_structure_coord or strct.ext_manipulation.add_functional_group were not in all cases dealing correctly with planar coordination geometry (PR #64).

  • Fixed error in strct.StructureOperations when index slices were used (PR #71).

  • Fixed bug in plots.PartialChargesPlot occurring when a data labels was part of another data label (PR #77).

Deprecations:

  • strct.ext_manipulation.add_functional_group is replaced by strct.ext_manipulation.add_structure_coord (PR #37).

  • aim2dat.io.cp2k.read_optimized_structure is replaced by aim2dat.io.cp2k.read_restart_structure (PR #56).

Breaking Changes:

  • Moved dict_* functions from aiida_workflows.utils to utils.dict_tools (PR #36).

  • Space group and symmetry related keys now conform to the attributes returned by spglib (PR #54). As such, the keys 'sg_number', 'int_symbol', 'point_group_symbol', 'schoenflies_symbol' are replaced by 'number', 'international', 'pointgroup', 'schoenflies', respectively.

  • utils.chem_formula.reduce_formula tries now to find a formula only having natural numbers as quantities; this way utils.chem_formula.compare_formulas`` works for all use-cases (PR #60).

  • Structure manipulation methods now in general maintain kinds, attributes and site_attributes if not otherwise noted (PR #63).

  • The interface of``strct.StructureOperations`` was changed in order to be more consistent with strct.Structure (PR #72).

  • strct.Structure.kinds now always returns a tuple instead of None (PR #73).

  • io.critic2.read_stdout now returns the value of ‘version’ as string (PR #74).

  • strct.Structure.calculate_distance treats r_max as a cut-off value for the distance (PR #83, PR #90).

Version 0.1.0

  • First published version.