-
Notifications
You must be signed in to change notification settings - Fork 22
Better volumetric test #149
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
base: master
Are you sure you want to change the base?
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #149 +/- ##
==========================================
+ Coverage 87.70% 87.76% +0.06%
==========================================
Files 5 5
Lines 748 752 +4
Branches 97 98 +1
==========================================
+ Hits 656 660 +4
Misses 56 56
Partials 36 36 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
@PlethoraChutney thank you for your contribution and the insights. Could you please raise an issue that describes the issue — basically your justification for the fix? Separating solution from issues is good practice when we're discussing changes that may go against specs. Issues are our permanent record for decisions. We can then link the PR to the issue. Once you have the issue up, we can look closer at your proposed solution. Thank you! |
orbeckst
left a comment
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.
Blocked until we have discussed the approach.
|
It's related to this issue (BradyAJohnston/MolecularNodes#993) raised in MN. Downloading directly from the EMDB it would load fine, but if we round-trip through ChimeraX then it would fail to load with Worth some proper discussion though! |
|
Thanks for the context — ideally we collect all of this in an issue and then we have one place that documents the decision and the reasoning, as opposed to potentially mixing it with implementation details etc. |
|
Apologies! I'm relatively new to actually contributing to others' repos. Created #150 for discussion |
|
Many thanks @PlethoraChutney , #150 is perfect. Different projects have different "cultures" on how they do development and when coming in you just don't know. |
|
Tried to capture the discussion in #150
|
| def __init__(self, grid=None, edges=None, origin=None, delta=None, | ||
| metadata=None, interpolation_spline_order=3, | ||
| file_format=None): | ||
| file_format=None, **kwargs): |
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 think I would prefer an actual argument rather than **kwargs as the latter can easily (and silently) absorb spelling mistakes fiel_format='MRC would be silently no longer passed on instead of raising an error otherwise. I defer to @orbeckst on this but I think just mentioning in the docs that it is only used for mrc files (and maybe a warning when used for non-compatible format?).
Hello! Thank you for MDAnalysis! This PR changes how MRC files are checked before being loaded as a 3D grid. Rather than use the
is_volume()method frommrcfilewe instead use a simpler shape check.The reason for this is that
mrcfilereturnsFalseif the ISPG header field of a 3D MRC file is zero. While this is correct according to the spec, most cryoEM software packages save a 0 in this field for a variety of reasons. Because of this unwritten deviation from spec, most packages also read in files with a 0 space group as 3D Volumes anyway, but GridDataFormats does not.Despite the fact that this is formally correct, I'm proposing that MDAnalysis should follow the behavior that users likely expect from their experience with other packages.
This PR fails three tests, but on my machine at least the current master branch also fails these same tests.