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

set up a very simple way for visualizing the benchmark trajectories #1102

Merged
merged 1 commit into from
Sep 3, 2024

Conversation

Iximiel
Copy link
Member

@Iximiel Iximiel commented Jul 25, 2024

Description

I am writing a small piece for the school explaining how the benchmark can be used, and I needed to visualize the trajectories, these modifications were the simplest thing to obtain the trajectories.

plumed benchmark --dump-trajectory trj.xyz +other options dumps the trajectory that would be used in the benchmark to the "trj.xyz" file.
By default write an XYZ compatible with plumed driver, but with an environment variable set (PLUMED_BENCH_EXTENDED_XYZ) it can output an extended xyz file;

Target release

I would like my code to appear in release v2.10

Type of contribution
  • changes to code or doc authored by PLUMED developers, or additions of code in the core or within the default modules
  • changes to a module not authored by you
  • new module contribution or edit of a module authored by you
Copyright
  • I agree to transfer the copyright of the code I have written to the PLUMED developers or to the author of the code I am modifying.
  • the module I added or modified contains a COPYRIGHT file with the correct license information. Code should be released under an open source license. I also used the command cd src && ./header.sh mymodulename in order to make sure the headers of the module are correct.
Tests
  • I added a new regtest or modified an existing regtest to validate my changes.
  • I verified that all regtests are passed successfully on GitHub Actions.

@GiovanniBussi
Copy link
Member

I don't like very much the getenv(PLUMED_BENCH_EXTENDED_XYZ) ...

Can you make a list of software that can read this format?

If it's not super standard, I would remove this option. You can easily use awk to add those lines afterwards.

If it's super standard we can think about it also in other parts of the code. But for the purpose of visualizing the output of benchmark, I would just add the line a posteriori. Otherwise it's very confusing (driver will only write our "custom" xyz instead)

@Iximiel
Copy link
Member Author

Iximiel commented Jul 25, 2024

The extended xyz is identical to the "standard" xyz but instead of ignoring the comment line, it uses it to define the box and/or to store extra information, like indicating what the columns are.
It is compatible with all readers like vmd that ignore the comment as per standard
If I remember well, it was originally proposed by quip, and the reader I use most, ovito, uses the extra data to render the box or to take information from eventual extra columns

By default, the XYZ files are in the format compatible with plumed driver

@GiovanniBussi
Copy link
Member

Yes I remember you mentioning ovito. I was wandering if there is other software supporting it, and if we should make the transition (keeping the possibility to read "old style" xyz with just cell on second line).

But this is a more general question. For this specific PR, I would remove this format from the plumed benchmark tool since we do not support it anywhere else. And you can easily adjust the file with awk if it's just for opening it with ovito

@Iximiel Iximiel force-pushed the benchmark-plot-traj branch from ffb5511 to 83fb33b Compare July 25, 2024 14:45
@Iximiel
Copy link
Member Author

Iximiel commented Jul 25, 2024

Yes I remember you mentioning ovito. I was wandering if there is other software supporting it, and if we should make the transition (keeping the possibility to read "old style" xyz with just cell on second line).

But this is a more general question. For this specific PR, I would remove this format from the plumed benchmark tool since we do not support it anywhere else. And you can easily adjust the file with awk if it's just for opening it with ovito

I rebased to the driver-xyz only

@GiovanniBussi GiovanniBussi merged commit 194537b into plumed:master Sep 3, 2024
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants