-
Notifications
You must be signed in to change notification settings - Fork 68
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
add axis labels to display() #1682
Conversation
Do we need to upgrade the napari version pin? |
@ttung, yeah we would need to bump to napari 0.2.6. I changed the constant in |
Codecov Report
@@ Coverage Diff @@
## master #1682 +/- ##
=========================================
- Coverage 90.24% 90.15% -0.1%
=========================================
Files 230 230
Lines 8745 8755 +10
=========================================
+ Hits 7892 7893 +1
- Misses 853 862 +9
Continue to review full report at Codecov.
|
@ttung, if I read |
starfish/core/_display.py
Outdated
Axes.ROUND.value, | ||
Axes.CH.value, | ||
Axes.ZPLANE.value, |
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 would grab these three from starfish/core/imagestack/dataorder.py
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.
Will do!
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.
@ttung , it looks like AXES_DATA
contains names and orders for round, channel, and z, but not x and y. Should I just assume (y, 3) and (x, 4)? Or is the axis ordering for y and x stored elsewhere?
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.
(you can rotate views in napari
, so the y and x axis names may get displayed)
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.
Unfortunately, Y and X are not stored anywhere. It has always been assumed Y then X.
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.
Sounds good!
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.
@ttung, I changed it such that the axis order comes from starfish.core.imagestack.dataorder
.
Description
This PR adds axis labels to
starfish.display()
using the recently-added labeled axis support innapari
(thanks, @HagaiHargil !).Approach
I added the
axis_labels
keyword argument to theViewer
constructor in_display.py
.Question
Currently, I just create a list of the
Axes
Enum
values. Is there a better way to do this? Maybe get the axes from the stack?Testing:
I downloaded and viewed the test data from the ISS example notebook.