Skip to content

Commit d51c4bd

Browse files
committed
bugfix + added verification test
1 parent 2e057ec commit d51c4bd

11 files changed

+179404
-5
lines changed

spack/packages/sirius/package.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,6 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage):
9494
variant("magma", default=False, description="Enable MAGMA support")
9595
variant("nlcglib", default=False, description="Enable robust wave function optimization")
9696
variant("wannier90", default=False, description="Enable Wannier90 library")
97-
variant("pugixml", default=False, description="Enable direct reading of UPF v2 pseudopotentials")
9897
variant(
9998
"build_type",
10099
default="Release",
@@ -109,6 +108,10 @@ class Sirius(CMakePackage, CudaPackage, ROCmPackage):
109108
)
110109
variant("nvtx", default=False, description="Use NVTX profiler")
111110

111+
with when("@7.6:"):
112+
variant("pugixml", default=False, description="Enable direct reading of UPF v2 pseudopotentials")
113+
conflicts("+tests~pugixml")
114+
112115
depends_on("[email protected]:", type="build")
113116
depends_on("mpi")
114117
depends_on("gsl")

src/unit_cell/atom_type.cpp

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -732,10 +732,6 @@ Atom_type::read_input(nlohmann::json const& parser)
732732
free_atom_radial_grid_ = Radial_grid_ext<double>(static_cast<int>(fa_r.size()), fa_r.data());
733733
/* read density */
734734
free_atom_density_ = parser["free_atom"]["density"].get<std::vector<double>>();
735-
736-
if (!parser) {
737-
return;
738-
}
739735
}
740736
}
741737

verification/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,3 +45,4 @@ salloc -N4 -C gpu --time=60:00 -A csstaff
4545
| test29 | NiO | \[2, 2, 2\] | - Ni: USPP <br> - O: PAW <br> Hubbard correction | GGA (PBE-sol) | AFM collinear | - Hubbard U+V correction |
4646
| test30 | NiO | \[2, 2, 2\] | USPP <br> Hubbard correction | GGA (PBE) | non-magnetic | - Constrained Hubbard potential <br> - full orthogonalization of atomic orbitals |
4747
| test31 | H | \[2, 2, 2\] | full-potential | LDA (PZ) | non-magnetic | - test of Koelling-Harmon radial solver |
48+
| test32 | SrVO3 | \[2, 2, 2\] | USPP, PAW & NC | GGA (PBE)| non-magnetic | testing the parsing of UPF v2 files with pugixml |

verification/test32/O_pd_nc_sr_pbe_standard_0.4.1.upf

Lines changed: 2755 additions & 0 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)