From a61e0b2526719459dd861c45d24deb057ddd59c6 Mon Sep 17 00:00:00 2001 From: "Oleg E. Peil" Date: Wed, 11 Nov 2015 20:30:49 +0100 Subject: [PATCH] Fixed a problem with missing nc_flag property The ProjectorShell class must inheret 'nc_flag' from somewhere. This is now done by passing it to the class constructor in 'generate_plo()'. --- python/vasp/plotools.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/python/vasp/plotools.py b/python/vasp/plotools.py index 5e38c6c0..321173ab 100644 --- a/python/vasp/plotools.py +++ b/python/vasp/plotools.py @@ -305,10 +305,11 @@ class ProjectorShell: - proj_raw (numpy.array) : array of raw projectors """ - def __init__(self, sh_pars, proj_raw, proj_params): + def __init__(self, sh_pars, proj_raw, proj_params, nc_flag): self.lorb = sh_pars['lshell'] self.ion_list = sh_pars['ion_list'] self.user_index = sh_pars['user_index'] + self.nc_flag = nc_flag # try: # self.tmatrix = sh_pars['tmatrix'] # except KeyError: @@ -613,7 +614,7 @@ def generate_plo(conf_pars, el_struct): print " Generating %i shell%s..."%(nshell, '' if nshell == 1 else 's') pshells = [] for sh_par in conf_pars.shells: - pshell = ProjectorShell(sh_par, proj_raw, el_struct.proj_params) + pshell = ProjectorShell(sh_par, proj_raw, el_struct.proj_params, el_struct.nc_flag) print print " Shell : %s"%(pshell.user_index) print " Orbital l : %i"%(pshell.lorb)