-
Notifications
You must be signed in to change notification settings - Fork 16
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
Benchmarking Lumol #62
Comments
For MC, to go to non-rigid molecules or molecules with more than 3 beads, we need a way to sample intramolecular configurations. See #35. |
I noticed a few long running tests this morning on the |
I'd prefer to keep these tests as test, but we can discuss it. I usually only run the unit tests when developing ( My setup is a bit clumsy at the moment, but it will become easier when cargo gets a |
You can assign me to the Lennard-Jones cases for NVT and NPT. Before that, I will implement energy cashing for A practical question: in #58, I added an example case. Somehow, I couldn't manage to make this a I get the same error for existing tests, like
Any idea what is going wrong or what I am doing wrong here? Do I have to copy the |
Lets keep this issue on topic, I'll answer you in #58. |
We can use bencher to run the benchmarks using a stable rust compiler, instead of a nightly one. |
This is a must have if we are to do any kind of optimization on Lumol. I would really like to help on this one, but have no real idea what a reasonable configuration for molecules looks like :( . |
I'd be happy to help you with that. I can create configuration files for all systems mentioned in the OP. To compare Lumol to other codes, we have to make sure that the same force fields are used. For Lennard-Jones (Argon), we can already cover all cases but the grand-canonical ensemble. Maybe we should also include an atomic mixture (Na, Cl) as intermediate step towards water? For water and butane it's more difficult. For SPC/E water we can do NVT and NPT comparisons for MC simulations right now. For butane, we'd need #35 for MC simulations, MD should work for force fields that use non-fixed bond lengths. I'd say we start with comparison benchmarks of Argon. |
I can also perform the simulations in Gromacs, Gromos (maybe DL_Poly) and Cassandra to compare performance. |
@g-bauer thanks ! I'm OK for starting with argon. |
For argon, we already have inputs in the examples/data folder. I'd use the example configuration I think it is more convenient to just use input files instead of rust bins? We can set up an argon force field file ( We have to use the same cutoff radius for all simulations (say rc = 2.7 * sigma = 9.1935 Angstrom). Also, we should use the same frequencies to write data to files. Hopefully, I'll get #94 finished tonight, so that we can use it for the MC part. Does that make sense? If anything is unclear, feel free to ping me (here or gitter). |
This is the exact use case of this feature 😃 !
I think it is better not to write anything during the benchmark run. We are not benchmarking how the filesystem behave, and it can have a lot of latency and variations. |
File organisation is wonky for the benchmarks right now. We need a clear separation between regression benchmarks and comparison benchmarks (right now comparisons are in a The current way regression benchmarks are done using
|
I am OK with this organisation. The current code is pretty old and comes from the very first times of this repository.
What would you use ? I'm all in for Python, or even a rust "script".
This is #49. The main documentation is hosted in github pages right now, we could use it for benchmarks too. I was thinking we could write benchmark results to a JSON file, and then load them and plot them using some JS plotting library. |
@Luthaf yes I'm 100 % in favor of a Python script (I just find bash scripts unreadable). Plotting the benchmarks would super nice, but in case you guys don't know: the world of JS graph plotting is HELL. |
Sounds good to me.
Other codes may need plenty of different files (special configuration format, multiple inputs for simulation setup and force fields). Just dropping the files inside a directory will be messy. Maybe another subfolder for every engine?
You would also rerun the simulations using other engines? I imagine that is very tedious to set up. To start, could we go with a single run (maybe on different systems), store benchmarks and compare against those?
If we go with python, why not use matplotlib (or jupyter notebooks)? It is easy to use and set up. |
Can the other engines have a single file as input, and have links to other files inside this file ? (as we do with lumol), or do they need everything to be in the same directory ? In the second case, I agree with having a subdirectory for each engine. I don't mean that in the first case we do not have subdirectories, I just mean that we force on each case having the input file, and on a case per case basis we can choose the directory structure.
What do you mean by tedious ? If you mean long, yeah probably, but that's not really an issue, we expect them to be super long anyways right ? And I don't really know how consistent is performance on Travis CI across builds, so I can see a lot of issues coming from not running them each time (admittedly, Travis CI performance may not be consistent in the same build, that would be an issue).
How would you integrate them in a web page ? |
As far as I know (at least for Gromacs and Cassandra) that is not possible.
I might not understand the whole procedure for the benchmarks but we'd need installations of all codes, right? They often depend on a bunch of additional libraries and are compiled to fit the architecture. |
OK, but to benchmark we would have to install all of this on the same machine we want to benchmark Lumol on, so running it each time may not be much more painful than running it once. However installing the other engines on Travis may be a huge pain. Is there something I don't get ? |
That's something I'm not experienced in (Travis). Are there limits of what we can run using Travis? Simulation times, resources, libraries? |
Yes, there are limitations (Travis is intended as a testing service, not a benchmarking service):
I think that we should run specific benchmarks (energy computation for different system, and one complex simulation) on Travis, and run benchmarks comparing with other codes from time to time on our machines, and upload the results. There might be other providers more suitable for benchmarks too. |
I didn't know about the 1 hour limit, this can be a problem. |
Should we run the current benchmarks on Travis ? From my point of view it would be extremely valuable to be able to run them on a remote machine for each commit: when I run them on my local machine I can basically do nothing else, so my productivity is kinda ruined. |
We need two kind of benchmarks:
Benchmarks live in
benches
, and can be run using a nighlty compiler withcargo bench
.We currently have one regression benchmark for Ewald summation here; an,d one comparison benchmark against LAMMPS for the md simulation of Helium.
Here are some additional ideas:
Regression benchmarks
We already have energy computation for a molecular fluid with charges (water)
Simulation benchmarks
It would be nice to have all the combinations of MD/MC -- Lennard-Jones/butane/water -- NVE/NVT/NPT/μVT. Here is a full list:
That is already 18 different simulations, that we should compare against already existing MD and MC codes.
Maybe we can also have tests for bio-molecules, like a small peptide, DNA strand and a bigger protein.
Please comment with more ideas, and open PR to add the benchmarks!
The text was updated successfully, but these errors were encountered: