Skip to content
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

Use NetworkX to identify bonds, angles, dihedral, impropers #140

Closed
wants to merge 427 commits into from

Conversation

ahy3nz
Copy link
Collaborator

@ahy3nz ahy3nz commented May 5, 2019

While messing around with using networkx to identify angles/dihedrals/impropers, some comparison functions are needed. This PR includes definitions of those comparison functions - I don't think these comparison funcs need to be super sophisticated, we just need to have some sort of way to compare and sort sites so the nx.graph can do something
I've attached an example jupyternotebook that does this. I think the idea of using some graph-matching techniques could be a robust way to identify angles/dihedrals/impropers, with some clear patterns that we can extend to other types of connections. As @volgy said, we may want to implement these graphs and matching algorithms in our own way #138
example.gz

@volgy
Copy link
Collaborator

volgy commented May 13, 2019

Yes, this makes sense (need for any canonical ordering of sites to weed out duplicates found by the subgraph isomorphism). I still do not see crystal clear how the edge induced subgraphs will be found with the line_graph trick.

@ahy3nz ahy3nz changed the title Include some site comparison functions for networkx operations Use NetworkX to identify bonds, angles, dihedral, impropers Aug 6, 2019
@ahy3nz ahy3nz marked this pull request as ready for review August 7, 2019 16:50
@ahy3nz
Copy link
Collaborator Author

ahy3nz commented Aug 7, 2019

I think most of the actual code is here - I tucked away all the functions in another module called connectivity.py, whose functions are just called by topology.enumerate_connectivity().

Angles: I think this is fairly robust - unit tests are on ethane, methane, a square, and a square with a diagonal. Do we need more unit tests for this?
Dihedrals: Code is written to identify dihedrals, waiting on #146, will need to modify existing unit tests or add some new omes
Impropers: Code is written to identify impropers, will need to modify existing unit tests or add some new ones

mattwthompson and others added 26 commits February 18, 2020 10:49
Ensure correct subtop/site behavior when converting from mBuild
Merging, the PRs this depended on have been merged.
Correct energy unit conversion for epsilon
Add XML unit parsing function for units and physical constants
rmatsum836 and others added 27 commits March 6, 2020 12:41
Add more tests for GROMACS topology writer
Read the docs build for gmso (Closes #319)
Update setup.py to fix packages, requirements, urls
Previously, the command provided for the pip installation of the
dependencies from requirements.txt used --file, which is an option in
conda but not in pip, which uses -r instead, so --file was replaced with
-r.
Fix some issues in installation docs
Write out bonds, angles, and dihedrals to LAMMPS data file
@uppittu11
Copy link
Member

I done messed this up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet