__init__(self,
imageData,
imageWCS,
axe=[0.1,0.1,0.8,0.8],
cutLevels=["smart",99.5],
colorMapName="gray",
title=None,
axesLabels="sexagesimal",
axesFontFamily="serif",
axesFontSize=12.0,
RATickSteps="auto",
decTickSteps="auto",
colorBar=False,
interpolation="bilinear")
(Constructor)
| source code
|
Makes an ImagePlot from the given image array and astWCS. For
coordinate axes to work, the image and WCS should have been rotated such
that East is at the left, North is at the top (see e.g. astImages.clipRotatedImageSectionWCS, or astImages.resampleToTanProjection).
If imageData is given as a list in the format [r, g, b], a color RGB
plot will be made. However, in this case the cutLevels must be specified
manually for each component as a list - i.e. cutLevels = [[r min, r max],
[g min, g max], [b min, b max]]. In this case of course, the colorMap
will be ignored. All r, g, b image arrays must have the same
dimensions.
Set axesLabels = None to make a plot without coordinate axes
plotted.
The axes can be marked in either sexagesimal or decimal celestial
coordinates. If RATickSteps or decTickSteps are set to "auto",
the appropriate axis scales will be determined automatically from the
size of the image array and associated WCS. The tick step sizes can be
overidden. If the coordinate axes are in sexagesimal format a dictionary
in the format {'deg', 'unit'} is needed (see RA_TICK_STEPS and DEC_TICK_STEPS for examples). If the coordinate axes are
in decimal format, the tick step size is specified simply in RA, dec
decimal degrees.
- Parameters:
imageData (numpy array or list) - image data array or list of numpy arrays [r, g, b]
imageWCS (astWCS.WCS) - astWCS.WCS object
axes (list) - specifies where in the current figure to draw the finder chart
(see pylab.axes)
cutLevels (list) - sets the image scaling - available options:
-
pixel values: cutLevels=[low value, high value].
-
histogram equalisation: cutLevels=["histEq", number
of bins ( e.g. 1024)]
-
relative: cutLevels=["relative", cut per cent level
(e.g. 99.5)]
-
smart: cutLevels=["smart", cut per cent level (e.g.
99.5)]
["smart", 99.5] seems to provide good scaling over a
range of different images. Note that for RGB images, cut levels
must be specified manually i.e. as a list: [[r min, rmax], [g
min, g max], [b min, b max]]
colorMapName (string) - name of a standard matplotlib colormap, e.g. "hot",
"cool", "gray" etc. (do
"help(pylab.colormaps)" in the Python interpreter to
see available options)
title (string) - optional title for the plot
axesLabels (string) - either "sexagesimal" (for H:M:S, D:M:S),
"decimal" (for decimal degrees) or None (for no
coordinate axes labels)
axesFontFamily (string) - matplotlib fontfamily, e.g. 'serif', 'sans-serif' etc.
axesFontSize (float) - font size of axes labels and titles (in points)
colorBar (bool) - if True, plot a vertical color bar at the side of the image
indicating the intensity scale.
interpolation (string) - interpolation to apply to the image plot (see the documentation
for the matplotlib.pylab.imshow command)
|