fixed incorrect orbital sort for spobuilder, pwscf kpoints now in crystal format

git-svn-id: https://subversion.assembla.com/svn/qmcdev/trunk@6263 e5b18d87-469d-4833-9cc0-8cdfa06e9491
This commit is contained in:
Jaron Krogel 2014-03-13 13:02:40 +00:00
parent 2b7a55e2b3
commit 538350fd70
4 changed files with 21 additions and 4 deletions

View File

@ -958,6 +958,7 @@ class PwscfInput(SimulationInput):
self.k_points.kpoints = kpoints
self.k_points.weights = s.kweights.copy()
#end if
self.k_points.change_specifier('crystal',self) #added to make debugging easier
atoms = p.get_ions()
masses = obj()

View File

@ -111,6 +111,8 @@ def basic_qmc(identifier = '',
bconds = None,
jastrows = 'generateJ12',
meshfactor = 1.0,
det_format = 'new',
precision = 'float',
vmc_timestep = None,
nonlocalmoves = None,
perform_opt = False,
@ -258,6 +260,8 @@ def basic_qmc(identifier = '',
remove_cell = remove_cell,
jastrows = jastrows,
meshfactor = meshfactor,
det_format = det_format,
precision = precision,
estimators = estimators,
corrections = corrections,
calculations = qmc_calcs
@ -370,6 +374,8 @@ def basic_qmc(identifier = '',
remove_cell= remove_cell,
jastrows = jastrows,
meshfactor = meshfactor,
det_format = det_format,
precision = precision,
timestep = vmc_timestep,
nonlocalpp = nonlocalmoves,
corrections= [],
@ -448,6 +454,8 @@ def standard_qmc(identifier = '',
bconds = None,
jastrows = 'generateJ12',
meshfactor = 1.0,
det_format = 'new',
precision = 'float',
vmc_timestep = None,
nonlocalmoves = None,
perform_opt = False,
@ -545,6 +553,8 @@ def standard_qmc(identifier = '',
functional = functional ,
jastrows = jastrows ,
meshfactor = meshfactor ,
det_format = det_format ,
precision = precision ,
ecut = ecut ,
ecutrho = ecutrho ,
conv_thr = conv_thr ,

View File

@ -3309,7 +3309,7 @@ def generate_bspline_builder(type = 'bspline',
precision = 'float',
twistnum = None,
twist = None,
sort = False,
sort = None,
version = '0.10',
truncate = False,
buffer = None,
@ -3331,7 +3331,6 @@ def generate_bspline_builder(type = 'bspline',
precision = precision,
tilematrix = tilematrix,
href = href,
sort = sort,
version = version,
truncate = truncate,
source = ions,
@ -3344,6 +3343,9 @@ def generate_bspline_builder(type = 'bspline',
spindatasets = True
)
)
if sort!=None:
bsb.sort = sort
#end if
if truncate and buffer!=None:
bsb.buffer = buffer
#end if
@ -4292,7 +4294,7 @@ def generate_basic_input(id = 'qmc',
spobuilders = None
dset = generate_determinantset_old(
type = 'bspline',
type = 'einspline',
twistnum = twistnum,
meshfactor = meshfactor,
precision = precision,

View File

@ -1223,7 +1223,10 @@ class Structure(Sobj):
#end if
for i in range(len(kpoints)):
u = dot(kpoints[i]-c,axinv)
kpoints[i] = dot(u-floor(u+.5),axes)+c
u -= floor(u+.5)
u[abs(u-.5)<1e-12] -= 1.0
u[abs(u )<1e-12] = 0.0
kpoints[i] = dot(u,axes)+c
#end for
if remove_duplicates:
inside = self.inside(kpoints,axes,c)
@ -1548,6 +1551,7 @@ class Structure(Sobj):
if unique:
self.unique_kpoints()
#end if
self.recenter_k() #added because qmcpack cannot handle kpoints outside the box
if self.folded_structure!=None:
kp,kw = self.kfold(self.tmatrix,kpoints,kweights)
self.folded_structure.add_kpoints(kp,kw,unique=unique)