Forum Navigation
You need to log in to create posts and topics.

Possible issue with loading XYZ

The attached XYZ file doesn't load up in OVITO for me for some reason.

I get 10 frames on the bottom bar showing up (its only a single frame) and no visuals.

Strangely, if I open this file in some editor (using Simplyfortran) and make no changes but just save, OVITO then loads it up correctly.

Maybe some hidden character that OVITO is sensitive to.   The file is an output from LAMMPS and loads up in VMD fine.

I think removing this sensitivity (whatever it is) would be beneficial.


Update: If I click on the attached file from this message, OVITO loads it up fine.  However, on my pc, that file doesn't load up correctly.  Strange.




Uploaded files:

Thanks for letting us know, I will look into this.
Are you using the latest developer version or OVITO 2.9?



If you have the feeling that the file contents get changed during uploading / downloading in this forum, please put the file into a  .zip or a .gz archive first and upload the archive. This should preserve the file contents exactly.

Our web server might perform some automatic conversion of character encodings or line breaks for text files.

Looking at the file you had attached above in a text editor, I don't get any idea yet why Ovito should have any problems with it. It looks all normal.


I'm using the latest version 3.0.0-dev592.

Attached is the load up screens I get.

Strangely when I zip up the file and unzip, it works.

Even when I copy and paste the file in the same directory, it then allows me to load it up fine (ctrl C and ctrl V to produce a copy).

I'm having trouble moving the file to you to reproduce this little issue.


Uploaded files:
  • fig1.jpg
  • fig2.jpg

I'm not sure, but could the changing behavior be related to the naming of the file? Copying/pasting probably changes the name of the new file, right? You seem to have several files in the same directory, and their names form a series:,, ....

Ovito automatically detects such uniform series of filenames and loads them as a sequence. This is why the time slider at the bottom of the main windows shows 11 animation frames. Because you have 11 files named rate5_*.xyz in that directory. Your screenshot shows the contents of file (see the selection box "Current frame" in the panel on the right). This file seems to contain no atoms at all.

What happens when you jump to the animation frame that corresponds to the file, the one you found to be problematic? Does Ovito load and show the 1763 atoms that should be in there?

Ahhh...that answers it!

So moving to another frame doesn't work but your explanation tells me what is going on.  See attached zip file.

So there are 10 xyz files but the first one has the wrong format (two extra lines at the top which I remove later).

When I tried to view a correct formatted file after that first file in the sequence, its looks through the sequence as you say but fails to load up anyone of them correctly due to that first file.




Uploaded files:

Ok, good. I will try to repeat what you did when I am back from vacation and back to my computer in two weeks. Maybe there is something we can do to improve the behavior of Ovito to prevent this kind of confusion in the future.

Here, by the way, is the page of the user manual that explains the current behavior of Ovito:

It could be that in your case Ovito even assumes that the trajectory frames are distributed over multiple files, with each file containing multiple frames. This is indicated by the fact that a file search pattern such as "rate5_*.xyz" was automatically generated and the "file contains multiple frames" option is checked as well.