diff --git a/CHANGELOG.md b/CHANGELOG.md index f40080b..67be037 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/). ## [develop] - 2024-11-13 ### Added +- ASIMMODULE: vasp/vasp - ASIMMODULE: benchmarking/distribution - ASIMMODULE: data/collect_images asimmodule - CALCULATOR: OMAT24 calculator diff --git a/asimtools/asimmodules/benchmarking/distribution.py b/asimtools/asimmodules/benchmarking/distribution.py index c02ea97..34f5a1d 100644 --- a/asimtools/asimmodules/benchmarking/distribution.py +++ b/asimtools/asimmodules/benchmarking/distribution.py @@ -27,6 +27,8 @@ def distribution( remap_keys = {} unit_factors = {'meV': 1000, 'eV': 1, 'kcal/mol': 23.0621} unit_factor = unit_factors[unit] + if remap_keys is None: + remap_keys = {} unit_dict = { 'energy': f'{unit}/atom', diff --git a/asimtools/asimmodules/vasp/vasp.py b/asimtools/asimmodules/vasp/vasp.py index 919ff58..3bf1346 100755 --- a/asimtools/asimmodules/vasp/vasp.py +++ b/asimtools/asimmodules/vasp/vasp.py @@ -28,19 +28,19 @@ def vasp( vaspinput_args: Optional[Dict] = None, command: str = 'vasp_std', mpset: Optional[str] = None, - write_image_output: bool = False, + write_image_output: bool = True, ) -> Dict: """Run VASP with given input files and specified image :param image: Initial image for VASP calculation. Image specification, see :func:`asimtools.utils.get_atoms` :type image: Dict - :param vaspinput_args: Dictionary of VASP input arguments. + :param vaspinput_args: Dictionary of pymatgen's VASPInput arguments. See :class:`pymatgen.io.vasp.inputs.VaspInput` :type vaspinput_args: Dict :param command: Command with which to run VASP, defaults to 'vasp_std' :type command: str, optional - :param mpset: Material Project VASP set to use, defaults to None + :param mpset: Materials Project VASP set to use, defaults to None :type mpset: str, optional :param write_image_output: Whether to write output image in standard asimtools format to file, defaults to False diff --git a/asimtools/job.py b/asimtools/job.py index 8bf258e..dddc52a 100644 --- a/asimtools/job.py +++ b/asimtools/job.py @@ -63,7 +63,7 @@ def __init__( self.sim_input['src_dir'] = self.launchdir self.env_id = self.sim_input.get('env_id', None) - if self.env_id is not None: + if self.env_id is not None and self.env_input is not None: self.env = self.env_input[self.env_id] else: self.env = { @@ -1062,7 +1062,11 @@ def load_job_from_directory(workdir: os.PathLike) -> Job: else: calc_input = None - job = Job(sim_input, env_input, calc_input) + job = Job( + sim_input=sim_input, + env_input=env_input, + calc_input=calc_input, + ) # This makes sure that wherever we may be loading the job from, we refer # to the correct input/output files. As of now, it does not seem necessary