-
Notifications
You must be signed in to change notification settings - Fork 31
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
Miscellaneous changes #78
Conversation
pyat/at/physics/orbit.py
Outdated
@@ -76,7 +76,7 @@ def find_orbit4(ring, dp=0.0, refpts=None, guess=None, **kwargs): | |||
delta_matrix = numpy.zeros((6, 5), order='F') | |||
for i in range(4): | |||
delta_matrix[i, i] = step_size | |||
id4 = numpy.asfortranarray(numpy.identity(4)) | |||
id4 = numpy.asfortranarray(numpy.eye(4)) |
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'm not sure why you've changed identity
to eye
here.
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.
Because it was causing a problem with our threading in atip and identity just imports and calls eye anyway. So I figured there was no downside to changing it.
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.
Except it was renamed to identity
because it is a clearer name. I vote to reinstate it because it is easier to understand.
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 have no problem with eye
since it's the name for the similar Matlab function, but I let you, python experts, decide.
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.
in atmexall.m
% Add AT directories to the Matlab path
atpath
This results in a double definition of all the Matlab path ! It is harmful if AT is correctly installed, and it is is not, I do not see how you call atmexall
. More generally, I do not like modifications of the Matlab path without the user's intervention: it can result in unexpected files being called instead of the desired ones…
I think you mentioned that Matlab path problem before. The misunderstanding comes because running Your point about modifying the path is sensible. |
Yes Will, you can run
|
New changes:
Are there any other changes that people would like added? |
The Corrector bug caused all correctors to have a length of 0, this caused some discrepancies in twiss data if a lattice had elements of class Correcor with a non-zero length. |
@lfarv @willrogers |
A number of miscellaneous changes that I have compiled whilst using AT, plus the commits from @willrogers' pull request #47.