Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Unable to handle incomplete trajectories #616

Open
nbzy1995 opened this issue Mar 15, 2024 · 0 comments
Open

[BUG] Unable to handle incomplete trajectories #616

nbzy1995 opened this issue Mar 15, 2024 · 0 comments
Labels
bug Something isn't working lammps

Comments

@nbzy1995
Copy link

nbzy1995 commented Mar 15, 2024

Bug summary

Here are really two issues.

  1. If I have a lammps/dump file that has some incomplete frames or it contains some comment lines starting with "#", dpdata.System() will throw an ValueError exception:
    ValueError: invalid literal for int() with base 10: '#####'

. It might be better if it can either throw a more meaningful exception, or it can report a warning and still able to read in the frames and mark the incorrect frame as nan.

  1. It seems dpdata.System() cannot read in velocities in the lammps dump file.

  2. Another minor feature request: can we add an option to choose not to reorder the atom indices? i.e., dpdata.System( reorder = False).

dpdata Version

v0.2.17 Latest on Oct

Input Files, Running Commands, Error Log, etc.

Python code:

import dpdata

# 1. Load input data file 
# I attached a lammps dump file with the last frame incomplete. [traj.txt](https://github.com/deepmodeling/dpdata/files/14617582/traj.txt)

in_file= "traj.txt"

d_conf = dpdata.System(in_file, fmt="lammps/dump")

Steps to Reproduce

Run the above python codes.

Further Information, Files, and Links

No response

@nbzy1995 nbzy1995 added the bug Something isn't working label Mar 15, 2024
@njzjz njzjz added the lammps label Mar 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working lammps
Projects
None yet
Development

No branches or pull requests

2 participants