-
Notifications
You must be signed in to change notification settings - Fork 9
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
plot recipe for wcs info. integration #16
Conversation
@giordano This PR is complete and ready to be reviewed. |
Merge only after #19 |
Codecov Report
@@ Coverage Diff @@
## master #16 +/- ##
==========================================
+ Coverage 94.91% 96.77% +1.85%
==========================================
Files 3 3
Lines 59 93 +34
==========================================
+ Hits 56 90 +34
Misses 3 3
Continue to review full report at Codecov.
|
REQUIRE
Outdated
@@ -0,0 +1,8 @@ | |||
julia 1 |
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.
We don't want this file back 🙂
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.
Fixed! It got in while merging things as this was an older branch.
What happens if a file doesn't have the required WCS information? |
Can't happen as the two keys |
I think other keys are used by |
@@ -17,3 +17,60 @@ end | |||
color := :grays | |||
img.data[1] | |||
end | |||
|
|||
@recipe function f(img::AstroImage, wcs::WCSTransform) |
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 think that this recipe applies only to a single colour image (AstroImg{T,C,1}
), what do you think?
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.
My understanding is that |
@test pix2world_xformatter(255, wcs2) == 255.0 | ||
|
||
@test pix2world_yformatter(255, wcs1) == "13.98°" | ||
@test pix2world_yformatter(255, wcs2) == 255.0 |
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.
Yeah, pix_to_world
returns the same array for any of the types it does not recognize or doesn't have.
As tested here.
@giordano Do this need some fixing or is this good to be merged now? |
Added recipe for showing
xlabel
andylabel
from WCS header. Also, pixel coordinates will be displayed as world coordinates by giving a WCS asplot(img, WCS)
.