Open haesleinhuepf opened 1 month ago
Do you want to set zoom_factor=1 like the other functions or do you have a specific behavior in mind?
Hi @Olusesan , yes, it should be as similar as possible to the other functions.
Hi @haesleinhuepf, I forked the repo and added zoom_factor. Because plt.imshow doest have a zoom parameter, I used viewer.camera.zoom to pass the zoom_factor like below. Pls let me know your thoughts:
def imshow(..zoom_factor: float = 1):
if zoom_factor != 1.0: viewer = napari.Viewer() image = viewer.camera.zoom(image, zoom=zoom_factor)
Hi @Olusesan ,
thanks for spending time on this! Do you think this is possible without napari? Stackview was developed to run in online environments, where napari does not work.
Also try out stackview.slice(image, zoom_factor=2) to see how zooming works in stackview.
Thanks again!
Best, Robert
Thanks for the guidance on this @haesleinhuepf , how about sample code below:
if zoom_factor != 1.0: image = stackview.slice(image, zoom_factor=zoom_factor)
All the best!
Most stackview functions have a
zoom_factor
parameter.imshow
does not. It might be practical to have that.