-
Notifications
You must be signed in to change notification settings - Fork 28
Conversation
Also this has the effect of removing triple nested for loop to one loop
It wasn't giving them -1
Water pull
Merge the SaveStructures.py script from master
Conflicts: src/python/metrics/parsers.py
Merged in latest master from simtk
#!/usr/bin/env python | ||
# This file is part of MSMBuilder. | ||
# | ||
# Copyright 2011 Stanford University |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe 2014?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch
@@ -97,6 +96,19 @@ def add_metric_parsers(parser): | |||
help='which distance metric', choices=AtomPairs.allowable_scipy_metrics) | |||
metric_parser_list.append(atompairs) | |||
|
|||
solventfp = metric_subparser.add_parser('solventfp', description='''SOLVENTFP: Get | |||
the solvent fingerprint.''') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we put a little bit more description here. Maybe a citation to the Gu paper would be sufficient.
# Get a traj_length x n_water_indices vector of distances | ||
distances = md.compute_distances(trajectory, | ||
atom_pairs, | ||
periodic=True) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
md.compute_distances will ignore periodic=True if the trajectory file doesn't contain PBC information. Do we want to check for that explicitly and issue a warning or something?
This is very nice. I made some small comments in the diff, but they're pretty minor. |
Also, we need to add a couple tests. These can be simple; one of the main reasons for having them is that ensures that if we break something somewhere else in the library (e.g. remove a method or refactor something) that is called by one of the SolventFP functions/classes, it gets registered immediately as a test failure. The fact that no such tests exist for LPRMSD is the reason that I broke it on accident w/ msmb2.8. e.g. #356 |
Subsumed by #405 |
Added metric
solventfp
to cluster based on weighted solute-solvent distancesAlso added a new script
AssignOuter.py
that takes a conformation that is in state i under one clustering, and state j in another clustering and assigns it to a combined state (ij)