-
Notifications
You must be signed in to change notification settings - Fork 95
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
Interpolation light profile and inverted coordinates #176
Comments
The design in the light profile 'INTERPOL' is slightly different but it should accept coordinate arrays. They just need to be one-dimensional. The light profile features a rotation component, so you can rotate your 2d map in different directions. The chosen coordinate system (inverse or not) should not affect the calculation of this class. In that sense it is 'just' that the input only supports rotations along coordinate and not transposes. |
Thanks for the answer. I can indeed find a way to initialise the interpol profile with the right orientation, but it would require to have access to the @property
def ra_inversed(self):
return True if (self._Mpix2a[0, 0] < 0) else False |
Your proposal does not generally work if the coordinate system is rotated. I think the eigenvalues and eigenvectors of the mapping matrix can help you here. |
Right. Let's stick with an implementation of the interpol light profile, similarly with to the equivalent mass profile. I can propose a PR. Another possibility: I don't use the current implementation of the interpolation profile in the |
The grid_interp_x and grid_interp_y in the lens model module is also not optimal as it requires rectangular orientation. I'd prefer not having a mix of interpolation schemes defining a coordinate system with schemes defining an axis. The coordinate scheme is much more general and I hopefully can replace the lens model part with such a scheme too. So if you implement an new profile, I would prefer it to be one with inputs consistent with the PixelGrid(). It's a bit more work but can ensure consistency. Then the difference to what I coded up would be:
|
I agree this would make sense to support same arguments that coordinates-related classes. I'm not sure to come to a full implementation very soon, but I put it on my TODO list 👍 |
The
'INTERPOL'
light profile does not accept coordinates arrays, like it is the case of the'INTERPOL'
mass profile. I think it instead considers that coordinates are positive going right for x and up for y.This leads to the interpolated surface brightness map being incorrectly oriented when the coordinates were obtained through
inverse=True
(in utility functions), i.e. East is on the left instead of right.The text was updated successfully, but these errors were encountered: