We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0778644 commit 81e81ccCopy full SHA for 81e81cc
src/aiida_wannier90_workflows/workflows/split.py
@@ -396,7 +396,12 @@ def inspect_valcond(self): # pylint: disable=inconsistent-return-statements
396
fermi_energy = get_workchain_fermi_energy(workchain)
397
self.ctx.fermi_energy = fermi_energy
398
399
- bands: orm.BandsData = workchain.outputs.band_structure
+ # Prioritize reference bands, since Wannier-interpolated bands might have
400
+ # interpolation error
401
+ if self.ctx.ref_bands is None:
402
+ bands: orm.BandsData = workchain.outputs.band_structure
403
+ else:
404
+ bands: orm.BandsData = self.ctx.ref_bands
405
bands_arr = bands.get_bands()
406
try:
407
homo, lumo = get_homo_lumo(bands_arr, fermi_energy)
0 commit comments