3
0
mirror of https://github.com/triqs/dft_tools synced 2024-07-11 05:43:48 +02:00

[fix] extract_G_loc for default call when no Sigma is set

This commit is contained in:
Alexander Hampel 2023-05-12 12:47:17 -04:00
parent bfaa84ca08
commit 6b4ebc022a

View File

@ -756,11 +756,14 @@ class SumkDFT(object):
if mu is None:
mu = self.chemical_potential
if with_Sigma:
if with_Sigma and hasattr(self, "Sigma_imp"):
mesh = self.Sigma_imp[0].mesh
if mesh != self.mesh:
warn('self.mesh and self.Sigma_imp[0].mesh are differen! Using mesh from Sigma')
elif with_Sigma and not hasattr(self, "Sigma_imp"):
mpi.report('Warning: No Sigma set but parameter with_Sigma=True, calculating Gloc without Sigma.')
with_Sigma = False
mesh = self.mesh
else:
mesh = self.mesh