-
-
Notifications
You must be signed in to change notification settings - Fork 14
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
rename offset_to to offset_byand have it use units #139
Comments
Oh, and @pllim saw this idea already in spacetelescope/jdaviz#705, but @mwcraig do you have any thoughts pro- or anti- this? |
I'm fine with this -- can it wait until we make some progress on the refactoring that @pllim started or does this need an implementation ASAP? |
I don't foresee being able to refactor anything over here in the near future. Also see #131 (comment) |
I see two different things proposed here. I think it is more practical to keep
(Maybe this was what you already proposed above... 🤷 ) |
This idea was triggered by looking at the implementation of another astrowidgets-conforming API in spacetelescope/jdaviz#705 :
offset_to
method is better namedoffset_by
. This aligns better with astropy.coordinates and I think it makes it just a bit clearer that you are giving the delta coordinates instead of actual coordinatesskycoord_offset
keyword by instead using the units ofdx
/dy
- if they are eitherpixel
or dimensionless that can be interpreted as pixel offsets, and any other unit can assumeSkyCoord
/other WCS ("other wcs" can be implemented in the future, but I'm just trying not to accidentally specify ourselves out of it)My proposal would be to keep in
offset_to
with its current API but have it start raising a deprecation warning (and internally it would call the newoffset_by
)And yes,
offset_to
was my original suggestion. But I think it was wrong after seeing it in action!The text was updated successfully, but these errors were encountered: