[lammps-users] error in loading psf file generated from lammps data file.

Hello, vmd and lammps users:

I have a pdb and psf file generated from lammps data file by lammps2pdb.pl script. When I loaded vmd, vmd complained the psf file as:

Error reading optional structure information from coordinate file gel_trj.psf Will ignore structure information in this file.

Part of the psf file is:


REMARK gel_trj.psf GENERATED FROM gel.data
REMARK CREATED BY lammps2pdb v2.2.5 ON Thu Jan 17 16:10:01 CST 2008


3120 !NBOND
1 2 1 41 2 3 2 42
3 4 3 43 4 5 4 44
5 6 5 45 6 7 6 46
7 8 7 47 8 9 8 48
9 10 9 49 10 11 10 50
11 12 11 51 12 13 12 52
13 14 13 53 14 15 14 54

1596 1597 1597 1598 1598 1599 1599 1600

In the pdb file, the total number of atoms is 2080. The number of all connected atoms is 1600. The rest are free atoms around. I don’t know why NATOM is zero in the psf file. If I change it to 1600, I got the same error. If I changed it to 2080. I got another error:

Line too short in psf file:
couldn’t read atom 0

Could someone tell me what’s wrong with the psf file? Thanks!



You might try a different approach. The easiest way would probably be
to have LAMMPS dump xyz format files and read those directly into VMD.
Alternatively, you could use pizza.py to convert the standard LAMMPS
dump files into pdb format, and use VMD's psfgen to generate a psf
file. A third alternative would be to read "native" LAMMPS dump files
directly into VMD. A while back, I read that VMD has a plugin to allow
it to read LAMMPS files in directly. I haven't done this, but the VMD
people may be able to help if you choose to take that route.
Alternative four would be to figure out how to get the lammps2pdb.pl
script to work right for your problem. If you go this route, I'd
recommend working with the script's author, Pieter in't Veld.


  My guess is that the conversion script you used generated a
non-conformant PSF file that doesn't strictly follow the columns
required for proper parsing. If you can gzip up one such PSF file
and email it to me I would be happy to take a look, but it may be best
to contact the author of the conversion script and get them involved
as well, since this is almost certainly a bug in their conversion

  John Stone
  [email protected]