pymatgen
pymatgen copied to clipboard
Add a save parameter for chargemol calculation to select whether save the output files, use "link" rather than "copy" for the input file of chargemol calc, add mpi function to run chargemol.
Revised Content
- Add
saveparameter to control whether save the output files fromchargemolcalculation - Use
linkrather thancopyforCHGCAR, POTCAR, ARCCAR0 and ARCCAR2during the calculation - Support
mpirunforchargemolcalculation
from pymatgen.command_line.chargemol_caller import *
chargemol = ChargemolAnalysis(mpi=True,ncores=32, save=True)
Job script to run chargemol program.
Hi Dr. @Andrew-S-Rosen,
Are you available to have look the remaining problem in this commit?
I have tried several methods to handle this problem but it still remains. Do you have some experiences to solve this kind of problem?
Thanks a lot! Gsliu
pymatgen/command_line/chargemol_caller.py:67: error: Incompatible types in assignment (expression has type "Optional[str]", variable has type "Union[str, list[str]]") [assignment]
pymatgen/command_line/chargemol_caller.py:78: error: Incompatible types in assignment (expression has type "Optional[str]", variable has type "Union[str, list[str]]") [assignment]
pymatgen/command_line/chargemol_caller.py:[20](https://github.com/materialsproject/pymatgen/actions/runs/6779786547/job/18427398503?pr=3456#step:6:21)6: error: Incompatible types in assignment (expression has type "Union[str, list[str]]", variable has type "list[Union[str, list[str]]]") [assignment]
pymatgen/command_line/chargemol_caller.py:239: error: Argument 1 to "Popen" has incompatible type "list[Union[str, list[str]]]"; expected "Union[Union[str, bytes, PathLike[str], PathLike[bytes]], Sequence[Union[str, bytes, PathLike[str], PathLike[bytes]]]]" [arg-type]
pymatgen/command_line/chargemol_caller.py:273: error: Argument 1 to "Popen" has incompatible type "list[Union[str, list[str]]]"; expected "Union[Union[str, bytes, PathLike[str], PathLike[bytes]], Sequence[Union[str, bytes, PathLike[str], PathLike[bytes]]]]" [arg-type]
Found 5 errors in 1 file (checked 267 source files)
Error: Process completed with exit code 1.
@RedStar-Iron: Apologies, but I unfortunately don't have time to look at this PR. @chiang-yuan and/or @janosh might be interested, however.