-
Notifications
You must be signed in to change notification settings - Fork 8
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
Adjust SMIRFF format spec to address generalization of format #180
Conversation
… parent_id and id from most examples
The SMIRFF format provides XML `ffxml` files that are parseable by the `ForceField` class of the `smarty.forcefield` module. These encode parameters for a force field based on a SMIRKS-based specification of the chemical environment the parameters are to be applied to. The file has tags corresponding to OpenMM force terms (`HarmonicBondForce`, `HarmonicAngleForce`, `PeriodicTorsionForce`, etc., as discussed in more detail below); these specify units used for the different constants provided for individual force terms, for example (see the [AlkEthOH example ffxml](https://github.com/open-forcefield-group/smarty/blob/master/smarty/data/forcefield/Frosst_AlkEtOH.ffxml)): | ||
The SMIRFF format provides XML `ffxml` files that are parseable by the `ForceField` class of the `smarty.forcefield` module. | ||
These encode parameters for a force field based on a SMIRKS-based specification of the chemical environment the parameters are to be applied to. | ||
The file has tags corresponding to OpenMM force terms (`HarmonicBondForce`, `HarmonicAngleForce`, `PeriodicTorsionForce`, etc., as discussed in more detail below); these specify units used for the different constants provided for individual force terms, for example (see the [AlkEthOH example ffxml](https://github.com/open-forcefield-group/smarty/blob/master/smarty/data/forcefield/Frosst_AlkEtOH.ffxml)): | ||
```XML | ||
<HarmonicAngleForce angle_unit="degrees" k_unit="kilocalories_per_mole/radian**2"> | ||
``` | ||
which introduces following `Angle` terms which will use units of degrees for the angle and kilocalories per mole per square radian for the force constant. | ||
|
||
Under each of these force terms, there are tags for individual parameter lines such as these: | ||
```XML |
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.
I'd add the <AngleForce>...</AngleForce>
tags here to make it very clear that the <Angle.../>
tags have to go inside this block.
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.
Wait, hold on -- that's different from what I thought we were saying. I thought we were saying we'd just be replacing the HarmonicAngleForce
tag with an AngleForce
tag and whether it is harmonic or not would be specified by an attribute of the SMIRFF
tag, as per what I wrote in the new docs:
... Selection of the type of angle force applied would be handled in a similar manner, via an
AngleForce="harmonic"
tag or similar. This feature is being planned.
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.
@jchodera - any further comments on this?
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.
Wait, hold on -- that's different from what I thought we were saying. I thought we were saying we'd just be replacing the HarmonicAngleForce tag with an AngleForce tag and whether it is harmonic or not would be specified by an attribute of the SMIRFF tag, as per what I wrote in the new docs:
We're in agreement here! But it still says HarmonicAngleForce
and not AngleForce
. Same thing with HarmonicBondForce
.
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.
Yes, totally agree. Just need to make the associated change in the code and then we can do that. I'll rebase/merge.
... | ||
</HarmonicAngleForce> | ||
``` | ||
|
||
**AMBER functional forms drop the factor of 2 in the angle energy term, which we elect not to do here.** Thus, comparing a SMIRFF file to a corresponding AMBER parameter file or .frcmod will make it appear that force constants here are twice as large as they ought to be. | ||
**AMBER functional forms drop the factor of 2 in the angle energy term, which we elect not to do here.** | ||
Thus, comparing a SMIRFF file to a corresponding AMBER parameter file or .frcmod will make it appear that force constants here are twice as large as they ought to be. | ||
|
||
### PROPER TORSIONS | ||
|
||
Torsions are implemented as a [`PeriodicTorsionForce`](http://docs.openmm.org/7.0.0/userguide/theory.html#periodictorsionforce) tag with child tags for `Proper` (discussed here) and `Improper` (discussed below) parameters, for example: | ||
``` |
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.
Forgot XML
after '```'
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.
Thanks.
Are you planning to change the |
I was going to wait til we change the code to do that. Right now it's listed here under things we are GOING to do. When we do it, then I'll drop the |
How about this plan:
|
Actually, we may want to split off the SMIRFF forcefield stuff to a new repo before doing that. |
@jchodera - regarding splitting into separate repo, yes, that was what we discussed by phone the other day. I made an issue and assigned it to you, but let me know if you want me to do it instead. (Whoever does it needs to get travis going, etc., on the new repo, as well as connect it up to omnia). |
Yep, I've got it slated for the weekend. Do we need it earlier than that? |
No, weekend is fine. But I'd be happy to do it myself if it would free up time for you to do the property calculator for densities or GB solvation. |
I've fallen behind again here, but I realized I needed to finish the GBSA PR before peeling of the SMIRFF code to another repo. |
You should be good to rebase or merge from master and then we can merge this in. |
AngleForce
rather thanHarmonicAngleForce
, as per Replace HarmonicAngleForce with AngleForce (and likewise for bonds?) in SMIRFF #179id
in a usage example@jchodera , anything else I'm missing?