Skip to content

Add multi-kpt support to SinglePointDFTCalculator, fix read_vasp_xml kpoint parsing

username-removed-249965 requested to merge spdftcalc_kpts into master

This is a combination bug fix and feature addition MR, necessary to make the Vasp calculator compatible ase.dft.band_structure. First, I have fixed the read_vasp_xml kpoint parsing to correctly assign the ibz_kpoints and bz_kpoints. Previously, this routine passed the Cartesian k-point coordinates to ibz_kpoints and did not set bz_kpoints. Now, the code passes the Cartesian k-point coordinates to bz_kpoints, and determines the ibz_kpoints from the unit cell and the `bz_kpoints.

Second, I have added the ability to support multiple k-points to the SinglePointDFTCalculator. Previously, the code assumed that all attached k-points were at the gamma point, and used assertions to disallow requesting information at other k-points. Now, the code is capable of supporting an arbitrary number of k-points, though not in any sophisticated manner. I invite others to look at my implementation and suggest alternative implementations of multiple k-point support that might be more useful.

Merge request reports