-
Notifications
You must be signed in to change notification settings - Fork 3
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
problem with the exemple? #35
Comments
Hello @Teusia! I confirm that the example is not fully up-to-date with respect to the code. I will try to solve the issue with the next official release of pyZELDA. Solving the issue by removing the |
Hello @avigan , Thank you for your answer, then I'll keep learning without the Should I close the issue or let it open as a reminder? |
Leave it open, I will close it when the example works again ;-) |
Hello @astromam and @avigan ,
I am trying to learn how to use your library using the code in the example repertory (simple_zelda_analysis.py).
however something is not working, I get this error message:
This is happening in function
zernike_expand
in theztools.py
.I have been at it all morning I actually do not see how this can work:
reconstructed_opd[i]
is afloat
coeffs_tmp[z]
is a floatbasis[z, :, :]
is a 2 dimensional arraySo multiplying a float by an array is fine but trying to add an array into a single numpy array element will not work.
After investigation I think the culprit is line 39 of simple_zelda_analysis.py :
The the script works for me if i remove that
.mean
. Can you confirm that this is the way to go please?I suspect that this was made this way in cases where
opd_map
actually has three dimension ? (why would it though?)I put there after the entire script that works for me with both datasets you provide.
I left #FIXME comment where I changed something, the original lines are commented and the following line is the one that fixes the problem for me.
Cheers,
Anne-Laure
The text was updated successfully, but these errors were encountered: