-
Notifications
You must be signed in to change notification settings - Fork 32
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
Fix return statement in _parse_coulombic
#744
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for more information, see https://pre-commit.ci
Codecov ReportPatch coverage:
Additional details and impacted files@@ Coverage Diff @@
## main #744 +/- ##
==========================================
+ Coverage 91.92% 91.95% +0.02%
==========================================
Files 67 67
Lines 6815 6815
==========================================
+ Hits 6265 6267 +2
+ Misses 550 548 -2
☔ View full report in Codecov by Sentry. |
daico007
approved these changes
Jul 10, 2023
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.
LGTM! Thanks for the fix!
emarinri
pushed a commit
to emarinri/gmso
that referenced
this pull request
Aug 11, 2023
* Add fixed angle support * Fix charge sign error (gmso-wide) * Update ring identification to handle fused systems (mbuild mosdef-hub#744) * Increase floating point accuracy * Increase element type length and atom type length * Correctly write atom indices for bonds/angles/dihedrals/impropers
daico007
added a commit
that referenced
this pull request
Sep 22, 2023
* Add fixed length bonds and angles to potential templates library. * Working to make MCF writer feature complete. Tests in progress. * Add fixed angle support * Fix charge sign error (gmso-wide) * Update ring identification to handle fused systems (mbuild #744) * Increase floating point accuracy * Increase element type length and atom type length * Correctly write atom indices for bonds/angles/dihedrals/impropers * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Add dimensions to Fixed Bond and Angle templates * Update keys in OPLS dihedral parameters dict * Modify dihedral constant indexing from k0 to k3 to k1 to k4 in the OPLSTorsionPotential template. * Fix typed OPLS ethane test for MCF format * Updated from old Mie Xenon test to OPLS ethane. * Remove assertions related to n and m parameters of the Mie potential. * Fix floating point format issues in MCF writer. * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Add typed ethane test. This test is not complete yet. The 1/2 factor in the angles and OPLS dihedral is not accounted for. * Fix code style * Add fixture to parse mcf into sections * Support Pydantic v1 and v2 (#752) Co-authored-by: Co Quach <43968221+daico007@users.noreply.github.com> * Update MCF with GMSO builtin top site sorting * Use PotentialFilters to check for unique atomtypes * Add test to check charge neutrality * Add test for incompatible expressions * Test full MCF for Mie-Xe and LJ-Ar * Check charge neutrality in each molecule test * Add exception for not neutral system in MCF writer * Move parsing and neutrality check as utils * minor docstring/comment fixes, swap out simplify with symengine expand * [pre-commit.ci] pre-commit autoupdate (#763) updates: - [github.com/psf/black: 23.7.0 → 23.9.1](psf/black@23.7.0...23.9.1) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Test for 0.5 factor of OPLS dihedral potential * Test to account for 0.5 factor in harmonic angles * Test for rigid angles using the TIP3P model * MCF writer test with topology with 10 argon mols * Tentative output of multiple MCF from one Topology * Change psi to phi and consts for ethylene xml test * Test for 0.5 factor in OPLS dihedrals * Add cassandra test for gmso * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Add test for two atom fragment * Test for molecule with one ring * Change nitrogen test to ethane ua * Add ethane rigid reference xml * Use Fourier dihedrals as MCF standard dihedrals. * Fix dihedral type output fourier to opls * Match MCF GMSO Angle header to mb Angle header * Add a test comparing gmso and mbuild mcf writers * Use the Fourier converter for ethylene dihedrals * Write atom type masses instead of atom masses to account for UA beads * Output correct case for dihedral styles in MCFs * Run an energy calculation to compare GMSO and mBuild MCF writers * Update gmso/tests/test_mcf.py * Update gmso/tests/test_mcf.py --------- Co-authored-by: Ryan S. DeFever <r.s.defever@gmail.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Matt Thompson <mattwthompson@protonmail.com> Co-authored-by: Co Quach <43968221+daico007@users.noreply.github.com> Co-authored-by: Co Quach <daico007@gmail.com> Co-authored-by: CalCraven <nicholas.c.craven@vanderbilt.edu>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a quick fix I noticed when using
convert_hoomd.py
on a topology with no charges._parse_coulombic()
returnsNone
if none of the sites have a charge value. This causes an error since the function is called inside of anextend
method:With lists, passing
None
toextend()
givesTypeError: 'NoneType' object is not iterable
Returning an empty list instead of
None
seems like the simplest fix. I added a unit test that should have caught this as well.