diff --git a/python/converters/vasp/python/inpconf.py b/python/converters/vasp/python/inpconf.py index b0680048..685f9b65 100644 --- a/python/converters/vasp/python/inpconf.py +++ b/python/converters/vasp/python/inpconf.py @@ -366,6 +366,8 @@ class ConfigParameters: value = self.shells[0].pop(key) self.groups[0][key] = value except KeyError: + if len(self.gr_optional[par]) > 2: + self.groups[0][key] = self.gr_optional[par][2] continue # Add the index of the single shell into the group self.groups[0].update({'shells': [1]}) diff --git a/python/converters/vasp/test/inpconf/test_input.py b/python/converters/vasp/test/inpconf/test_input.py index 59de1523..365b96f2 100644 --- a/python/converters/vasp/test/inpconf/test_input.py +++ b/python/converters/vasp/test/inpconf/test_input.py @@ -95,13 +95,12 @@ Groups: res += conf_pars.shells.__repr__() + '\n\n' res += "Groups:\n" res += conf_pars.groups.__repr__() - print res expected = r"""Shells: [{'ion_list': array([4, 5, 6, 7]), 'user_index': 1, 'lshell': 2}] Groups: -[{'index': '1', 'emin': -7.6, 'shells': [0], 'emax': 3.0}]""" +[{'normalize': True, 'index': '1', 'emin': -7.6, 'emax': 3.0, 'normion': False, 'shells': [0]}]""" self.assertEqual(res, expected)