skimage.viewer.utils.figimage (image[, …]) | Return figure and axes with figure tightly surrounding image. |
skimage.viewer.utils.init_qtapp () | Initialize QAppliction. |
skimage.viewer.utils.new_plot ([parent, …]) | Return new figure and axes. |
skimage.viewer.utils.start_qtapp ([app]) | Start Qt mainloop |
skimage.viewer.utils.update_axes_image (…) | Update the image displayed by an image plot. |
skimage.viewer.utils.ClearColormap (rgb[, …]) | Color map that varies linearly from alpha = 0 to 1 |
skimage.viewer.utils.FigureCanvas (figure, …) | Canvas for displaying images. |
skimage.viewer.utils.LinearColormap (name, …) | LinearSegmentedColormap in which color varies smoothly. |
skimage.viewer.utils.RequiredAttr ([init_val]) | A class attribute that must be set before use. |
skimage.viewer.utils.canvas | |
skimage.viewer.utils.core | |
skimage.viewer.utils.dialogs |
skimage.viewer.utils.figimage(image, scale=1, dpi=None, **kwargs)
[source]
Return figure and axes with figure tightly surrounding image.
Unlike pyplot.figimage, this actually plots onto an axes object, which fills the figure. Plotting the image onto an axes allows for subsequent overlays of axes artists.
Parameters: |
|
---|
skimage.viewer.utils.init_qtapp()
[source]
Initialize QAppliction.
The QApplication needs to be initialized before creating any QWidgets
skimage.viewer.utils.new_plot(parent=None, subplot_kw=None, **fig_kw)
[source]
Return new figure and axes.
Parameters: |
|
---|
skimage.viewer.utils.start_qtapp(app=None)
[source]
Start Qt mainloop
skimage.viewer.utils.update_axes_image(image_axes, image)
[source]
Update the image displayed by an image plot.
This sets the image plot’s array and updates its shape appropriately
Parameters: |
|
---|
class skimage.viewer.utils.ClearColormap(rgb, max_alpha=1, name='clear_color')
[source]
Bases: skimage.viewer.utils.core.LinearColormap
Color map that varies linearly from alpha = 0 to 1
__init__(rgb, max_alpha=1, name='clear_color')
[source]
Create color map from linear mapping segments
segmentdata argument is a dictionary with a red, green and blue entries. Each entry should be a list of x, y0, y1 tuples, forming rows in a table. Entries for alpha are optional.
Example: suppose you want red to increase from 0 to 1 over the bottom half, green to do the same over the middle half, and blue over the top half. Then you would use:
cdict = {'red': [(0.0, 0.0, 0.0), (0.5, 1.0, 1.0), (1.0, 1.0, 1.0)], 'green': [(0.0, 0.0, 0.0), (0.25, 0.0, 0.0), (0.75, 1.0, 1.0), (1.0, 1.0, 1.0)], 'blue': [(0.0, 0.0, 0.0), (0.5, 0.0, 0.0), (1.0, 1.0, 1.0)]}
Each row in the table for a given color is a sequence of x, y0, y1 tuples. In each sequence, x must increase monotonically from 0 to 1. For any input value z falling between x[i] and x[i+1], the output value of a given color will be linearly interpolated between y1[i] and y0[i+1]:
row i: x y0 y1 / / row i+1: x y0 y1
Hence y0 in the first row and y1 in the last row are never used.
See also
LinearSegmentedColormap.from_list()
Static method; factory function for generating a smoothly-varying LinearSegmentedColormap.
makeMappingArray()
For information about making a mapping array.
class skimage.viewer.utils.FigureCanvas(figure, **kwargs)
[source]
Bases: matplotlib.backends.backend_qt5agg.FigureCanvasQTAgg
Canvas for displaying images.
__init__(figure, **kwargs)
[source]
Initialize self. See help(type(self)) for accurate signature.
resizeEvent(self, QResizeEvent)
[source]
class skimage.viewer.utils.LinearColormap(name, segmented_data, **kwargs)
[source]
Bases: matplotlib.colors.LinearSegmentedColormap
LinearSegmentedColormap in which color varies smoothly.
This class is a simplification of LinearSegmentedColormap, which doesn’t support jumps in color intensities.
Parameters: |
|
---|
__init__(name, segmented_data, **kwargs)
[source]
Create color map from linear mapping segments
segmentdata argument is a dictionary with a red, green and blue entries. Each entry should be a list of x, y0, y1 tuples, forming rows in a table. Entries for alpha are optional.
Example: suppose you want red to increase from 0 to 1 over the bottom half, green to do the same over the middle half, and blue over the top half. Then you would use:
cdict = {'red': [(0.0, 0.0, 0.0), (0.5, 1.0, 1.0), (1.0, 1.0, 1.0)], 'green': [(0.0, 0.0, 0.0), (0.25, 0.0, 0.0), (0.75, 1.0, 1.0), (1.0, 1.0, 1.0)], 'blue': [(0.0, 0.0, 0.0), (0.5, 0.0, 0.0), (1.0, 1.0, 1.0)]}
Each row in the table for a given color is a sequence of x, y0, y1 tuples. In each sequence, x must increase monotonically from 0 to 1. For any input value z falling between x[i] and x[i+1], the output value of a given color will be linearly interpolated between y1[i] and y0[i+1]:
row i: x y0 y1 / / row i+1: x y0 y1
Hence y0 in the first row and y1 in the last row are never used.
See also
LinearSegmentedColormap.from_list()
Static method; factory function for generating a smoothly-varying LinearSegmentedColormap.
makeMappingArray()
For information about making a mapping array.
class skimage.viewer.utils.RequiredAttr(init_val=None)
[source]
Bases: object
A class attribute that must be set before use.
__init__(init_val=None)
[source]
Initialize self. See help(type(self)) for accurate signature.
instances = {(<skimage.viewer.utils.core.RequiredAttr object>, None): 'Widget is not attached to a Plugin.', (<skimage.viewer.utils.core.RequiredAttr object>, None): 'Plugin is not attached to ImageViewer'}
© 2011 the scikit-image team
Licensed under the BSD 3-clause License.
http://scikit-image.org/docs/0.14.x/api/skimage.viewer.utils.html