Hello everyone,
I tested the version of lammps with pytnon on Windows LAMMPS Binaries Repository: ., but I have errors.
After installing, I tested it by running examples from the python subfolder of the examples folder
attached the log file of the example in.python
lmp_serial should be in your PATH environment (the installer package should take care of that), thus you should not need to use the full path to the executable. in addition, the package installer extends PYTHONPATH to include the LAMMPS module, PYTHONHOME must not be set. The LAMMPS executable is supposed infer it from the location of the python DLL library that is bundled with the LAMMPS executable.
I will get an opportunity to test on a real windows machine tonight. At the moment, I can only check on Linux using Wine and that was working as expected.
Quick update. After testing on a real Windows machine it seems the unexpected behavior only happens with the 64-bit version and only if you run the examples in a path outside the original installation tree. In that case, it can be worked around by setting PYTHONHOME to the location of the LAMMPS installation, but that is not a generally viable solution since that will mess up other Python installations.
I have posted new binary packages to LAMMPS Binaries Repository: .
These have now some mitigation implemented to handle the lookup issues for the Python runtime on 64-bit Windows.
Hello. I’m new here. Could you please help me on how to run lammps with python on windows pc? The related official lammps documentation seems pretty confusing to me and the commands were mostly for linux.
Thanks in advance.
Please also post this as new topic with a proper subject as your question is at best loosely related to the discussion here. And it would belong to the LAMMPS Beginners sub-category as well.