-
Notifications
You must be signed in to change notification settings - Fork 8
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
norm() cannot be run on the output of tran() #9
Comments
If any of the package was in python it would have been easier to have a The reason |
It's fine that tran() doesn't default to that: no disagreement there. But it is very awkward to actually normalize the output of tran. Having some method that can be directly applied to the tran() output is the idea here. |
I suppose we could provided an overloaded implementation of the norm method within pyast that check the type of its arguments to see if it is provided with a single array of floating point values, or an array of arrays and does the appropriate thing. But in addition you can also use the existing NormMap class to normalise the output from tran: (a,b) = wcsinfo.tran( [[100.0,150.0],[200.0,250.0]] ) The reason for not performing normalisation by default within tran is partly, as Tim says, to avoid unnecessary work. But it is also because there are some occasions when you do not want to perform the normalisation - e.g. when dealing with cylindrical projections such as CAR when you need to know if a transformed point has gone out of the domain of the projection. |
It would be very good to be able to run
norm()
(or equivalent) on the output oftran()
. For example, either:or
The text was updated successfully, but these errors were encountered: