-
Notifications
You must be signed in to change notification settings - Fork 78
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
Incorrect atom typing? #170
Comments
I think the issue is with the ring-finding, specifically with the use of NetworkX's |
I think However, if we set a break after >8 particles were added to a cycle, then perhaps this wouldn't be too terrible |
I can take a look at implementing that, but in the mean time do you have any ideas for how I can type the system as a work around? Regarding performance: |
That's the expected behavior if the residue map is used. The only caveat is that it looks are residue names only. So if your molecules are separate residues with identical names, it should be taking advantage of the residue map. |
How do I set the residue name? I didn't see that as a compound attribute. |
RTFM mike. |
Residues aren't explicitly accounted for in |
Oh so can I not do a |
If your hierarchy is relatively simple, that should work. |
These doc strings in that example code you linked to @summeraz I think hint at the problem, we need a deterministic way to walk through the cycle. I haven't really done any work with networkx, but could we use the atom index? |
That could work. I don't actually think it should matter what node the cycle-finding starts with. If our goal is to find all of the cycles containing ≤ 8 particles that a given particle is within, then the atomtyping can be deterministic even if networkx isn't. |
That PR fixes all the ring stuff, but I do have another question, how can I get the carbon that is connected to the tail of carbons, the top ring, and the fullerene cage, typed as CT? I'm not sure how it is getting typed as a CA since it isn't in a 5 or 6 ring. |
In your force field file you'll need to change the SMARTS for CA to |
Sweet! Thanks so much, that fixed it. So does that string mean carbon in a ring of 5 elements or in a ring of 6 elements? Did |
Yes, I'm pretty sure that's what was happening. By including the |
Just to add in case it's useful, https://github.com/mosdef-hub/foyer/blob/master/foyer/smarts.py#L29 |
You will need to remove the extra .txt on these files.
pc71bm.hoomdxml.txt
opv_ff.xml.txt
The C atoms in the rings should be CA, and the other C atoms should be typed CT.
The text was updated successfully, but these errors were encountered: