Skip to content

S-shooting#787

Merged
dwhswenson merged 11 commits into
openpathsampling:masterfrom
singraber:s_shooting
Dec 14, 2021
Merged

S-shooting#787
dwhswenson merged 11 commits into
openpathsampling:masterfrom
singraber:s_shooting

Conversation

@singraber

Copy link
Copy Markdown
Contributor

Added S-shooting method to OPS, includes example and tests.

Developed as part of E-CAM ESDW in Leiden in August 2017 and finished on a sunny day in June 2018 in Vienna.

Link to the gitlab repository:
https://gitlab.e-cam2020.eu/singraber/S-Shooting

- Class SShootingSimulation added.
- Class SShootingAnalysis added.
- Class NonCanonicalSequentialMover added.
- Class NonCanonicalSequentialMoveChange added.
- Class DoubleWell added.
- Class OverdampedLangevinIntegrator added.
- Example IPython notebook sshooting-example.ipynb added.
- Nosetests for all classes added.
@dwhswenson

Copy link
Copy Markdown
Member

Please note that we have changed to the OPS license from LGPL (2.1 or later) to MIT. For any pull request to OPS that was started while the license was still LGPL, I need an explicit confirmation that you approve of the license change. Please add a comment with something like "The changes in this pull request are licensed under the MIT license."

@singraber

Copy link
Copy Markdown
Contributor Author

Updating with the master introduced some inconsistencies, I will fix this... also:

The changes in this pull request are licensed under the MIT license.

@dwhswenson dwhswenson added this to the 1.4 milestone Aug 12, 2020
@dwhswenson dwhswenson self-requested a review October 12, 2020 15:44
@dwhswenson dwhswenson modified the milestones: 1.4, 1.5 Dec 23, 2020
@dwhswenson

Copy link
Copy Markdown
Member

@singraber : Before I do a full review on this, could you do the following?

  1. git pull to bring in the conflict fixes I made
  2. Move the toy engine stuff you've added (PES and integrator) into the core files (intergrators.py, pes.py). The double-well PES seems frequently desired (although I use the version in OpenMMTools) and I was about to write an overdamped Langevin integrator for a tutorial I'm putting together; would rather just take yours!
  3. Please refactor to re-use as much as possible from the reactive flux PR, which is now merged. In particular, the various NonCanonical things are already in place, I think.

Thanks!

@dwhswenson

Copy link
Copy Markdown
Member

@singraber : Pinging again on this, since I think Christoph just said S-Shooting is in OPS... This needs some minor cleanup before I do the full review, but should be pretty straightforward! See #787 (comment) above for what needs to be done.

@codecov

codecov Bot commented Jan 29, 2021

Copy link
Copy Markdown

Codecov Report

Merging #787 (2094df0) into master (1279f23) will increase coverage by 1.50%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #787      +/-   ##
==========================================
+ Coverage   80.25%   81.76%   +1.50%     
==========================================
  Files         136      142       +6     
  Lines       14449    15604    +1155     
==========================================
+ Hits        11596    12758    +1162     
+ Misses       2853     2846       -7     
Impacted Files Coverage Δ
openpathsampling/movechange.py 76.12% <ø> (+1.36%) ⬆️
openpathsampling/pathmover.py 84.33% <ø> (+0.47%) ⬆️
openpathsampling/__init__.py 100.00% <100.00%> (ø)
openpathsampling/analysis/sshooting_analysis.py 100.00% <100.00%> (ø)
openpathsampling/engines/toy/__init__.py 100.00% <100.00%> (ø)
openpathsampling/engines/toy/integrators.py 93.65% <100.00%> (+2.53%) ⬆️
openpathsampling/engines/toy/pes.py 93.33% <100.00%> (+1.02%) ⬆️
openpathsampling/pathsimulators/__init__.py 100.00% <100.00%> (ø)
...pathsampling/pathsimulators/sshooting_simulator.py 100.00% <100.00%> (ø)
openpathsampling/engines/topology.py 59.01% <0.00%> (-40.99%) ⬇️
... and 90 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1279f23...2094df0. Read the comment docs.

@singraber

Copy link
Copy Markdown
Contributor Author

@dwhswenson Sorry for the delay, thanks for pinging! I integrated the toys from S-shooting into the main files and reused the NonCanonical stuff from the ReactiveFlux code. The example seems to run fine and I fixed a problem with the tests. The toy tests are now also merged into the test_toy_dynamics.py file. I think it's ready for reviewing...

@dwhswenson dwhswenson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks pretty good -- minor changes, all in the tests. The main things are:

  1. We're now using pytest, so please don't add tests based on nose. I tried to give guidance on how to change. Most are straightforward: just directly use Python assert statements. For assert_almost_equal or anything involving arrays, use tools in numpy.testing.
  2. A couple of to_dict/from_dict methods weren't covered. Suggestions show how I normally do that (by testing consistency in a to_dict-from_dict-to_dict cycle).

Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_analysis.py Outdated
Comment thread openpathsampling/tests/test_sshooting_simulator.py Outdated
Comment thread openpathsampling/tests/test_sshooting_simulator.py
Comment thread openpathsampling/tests/test_toy_dynamics.py

@dwhswenson dwhswenson left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After the changes I made in the last few commits, I approve this, but probably worth allowing some time for someone else to look over my changes. No requirement that those get reviewed before merge, but I'll give some time for @sroet or @singraber to look over the changes in 9825397, 53261df, and 2094df0 before I merge.

I will leave this open for at least 24 hours, merging no earlier than Tue 14 Dec 06:00 GMT (01:00 my local).

@sroet

sroet commented Dec 14, 2021

Copy link
Copy Markdown
Member

No requirement that those get reviewed before merge, but I'll give some time for @sroet or @singraber to look over the changes in 9825397, 53261df, and 2094df0 before I merge.

Looked over them and those commits look good to me

@dwhswenson dwhswenson merged commit 523442e into openpathsampling:master Dec 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants