shirtsgroup / InterMol

Conversion tool for molecular simulations
MIT License
185 stars 53 forks source link

LAMMPS to Gromacs conversion errors #392

Open MM2023-1401 opened 1 year ago

MM2023-1401 commented 1 year ago

Hi, To convert LAMMPS inputs to Gromacs inputs by using Intermol, I get this error:

File "/usr/local/lib/python3.9/site-packages/intermol/lammps/lammps_parser.py", line 529, in parse_pair_style raise UnimplementedSetting(line, ENGINE) intermol.exceptions.UnimplementedSetting: ['pair_style', 'hybrid', 'lj/cut/coul/long', '12.0', 'morse', '12.0'] has not yet been implemented in InterMol for LAMMPS. I see that there are previous similar issues here, is there any progress with this error?

There is also another error for a different file, please see the last lines: File "/usr/local/lib/python3.9/site-packages/intermol/forces/forcefunctions.py", line 139, in create_kwds_from_entries kwds[p] = float(entries[offset+i]) * u[i] IndexError: list index out of range

Could you comment on these errors?

mattwthompson commented 1 year ago

It looks like you're trying to use a Morse potential for pairwise interactions - I'm almost certain GROMACS does not support this.

If you'd like more help with this please upload some files that we can use to reproduce these errors, it's difficult to guess all of the inputs from the error messages alone.

MM2023-1401 commented 1 year ago

Thank you for your reply! I thought Morse potential for pairwise interactions is implemented in Gromacs! Then no point for this conversion anymore.

mattwthompson commented 1 year ago

I'm sure you can get it working in OpenMM if you wanted to accelerate your simulations with GPUs. Otherwise you might want to stick with LAMMPS. Unless a lot of development has happened in the last couple of years, I found GROMACS left a lot to be desired in running non-LJ simulations.

http://docs.openmm.org/latest/api-python/generated/openmm.openmm.CustomNonbondedForce.html#openmm.openmm.CustomNonbondedForce

mrshirts commented 1 year ago

Not all potentials available in any pair of programs are currently supported InterMol (and may never be). It looks like the first error is stating that it is not implemented in InterMol, which is behavior as expected.

For the second error, yeah, it would be useful to know what is going on.