Skip to content

Commit

Permalink
Merge pull request #9 from anbenali/kgasperich/nexus-rmg-pptype
Browse files Browse the repository at this point in the history
Fix strange bug
  • Loading branch information
anbenali authored Sep 28, 2023
2 parents b9ff973 + 612cdef commit 208188e
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 3 deletions.
2 changes: 1 addition & 1 deletion nexus/lib/rmg.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def __init__(self,**sim_args):
Simulation.__init__(self,**sim_args)
self.sync_from_scf = False
#calc = self.input.ontrol.get('calculation_mode',None)
if self.input.calculation_mode=='NSCF':
if self.get('calculation_mode')=='NSCF':
self.sync_from_scf = sync_from_scf
#end if
#end def __init__
Expand Down
15 changes: 13 additions & 2 deletions nexus/lib/rmg_input.py
Original file line number Diff line number Diff line change
Expand Up @@ -2583,6 +2583,17 @@ class RmgInputSettings(DevBase):
Key type: double
Expert: No
Experimental: No
Key name: charge_pulay_scale
Required: no
Key type: double
Expert: No
Experimental: No
Min value: 0.000000e+00
Max value: 1.000000
Default: 0.500000
Description:
'''
raw_input_spec += undocumented_options
raw_input_spec += deprecated_options
Expand Down Expand Up @@ -3469,7 +3480,7 @@ def write_text(self,filepath=None):
return text.lstrip()
#end def write_text


def check_valid(self,exit=True):
msg = ''
allowed = set(input_spec.keywords.keys())
Expand Down Expand Up @@ -3636,7 +3647,7 @@ def generate_any_rmg_input(**kwargs):
ri.assign(**kw)

# Special case for nscf calculation to force the read from already computed charge density.
if ri.calculation_mode=='NSCF' and 'input_wave_function_file' not in ri:
if kw.get('calculation_mode')=='NSCF' and 'input_wave_function_file' not in ri:
ri.input_wave_function_file='Waves/wave.out'

# incorporate pseudopotentials details provided via "pseudos"
Expand Down

0 comments on commit 208188e

Please sign in to comment.