-
Notifications
You must be signed in to change notification settings - Fork 7
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
mdacli doesn't loop over single frames #98
Comments
Good idea of changing these. Would you be able to do it? The lines are here: Lines 182 to 204 in cd90206
We ran through a test to check the units and maybe the function Line 25 in cd90206
will breaks. An additional test for None would be sufficient I guess. |
Closed by #99 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
If one is using an AnalysisClass on a trajectory with only one frame, the AnalysisBaseClass from MDA will happily do exactly that. This is because at initialization (
https://github.com/MDAnalysis/mdanalysis/blob/3769ee29e5907221527ff0ec88a8c5acf9f86dee/package/MDAnalysis/analysis/base.py#L247
), if
start
,stop
andstep
areNone
, and the trajectory is ONE frame long, it sets them to 0, 1 and 1 respectively.mdacli however sets the default values to
start = 0
,stop = -1
andstep = 1
. This does not result in the same behaviour, since for array of length 1:This difference in behaviour finally matters at this point: https://github.com/MDAnalysis/mdanalysis/blob/3769ee29e5907221527ff0ec88a8c5acf9f86dee/package/MDAnalysis/analysis/base.py#L296
Maybe setting the defaults to
None
would be an option?The text was updated successfully, but these errors were encountered: