|
LSSTApplications
8.0.0.0+107,8.0.0.1+13,9.1+18,9.2,master-g084aeec0a4,master-g0aced2eed8+6,master-g15627eb03c,master-g28afc54ef9,master-g3391ba5ea0,master-g3d0fb8ae5f,master-g4432ae2e89+36,master-g5c3c32f3ec+17,master-g60f1e072bb+1,master-g6a3ac32d1b,master-g76a88a4307+1,master-g7bce1f4e06+57,master-g8ff4092549+31,master-g98e65bf68e,master-ga6b77976b1+53,master-gae20e2b580+3,master-gb584cd3397+53,master-gc5448b162b+1,master-gc54cf9771d,master-gc69578ece6+1,master-gcbf758c456+22,master-gcec1da163f+63,master-gcf15f11bcc,master-gd167108223,master-gf44c96c709
LSSTDataManagementBasePackage
|
Public Member Functions | |
| def | __init__ |
| def | reset |
| def | append |
| def | makeMosaic |
| def | setGutter |
| def | setBackground |
| def | setMode |
| def | getBBox |
| def | drawLabels |
Public Attributes | |
| gutter | |
| background | |
| xsize | |
| ysize | |
| images | |
| labels | |
| nImage | |
| ny | |
| mode | |
A class to handle mosaics of one or more identically-sized images (or Masks or MaskedImages)
E.g.
m = Mosaic()
m.setGutter(5)
m.setBackground(10)
m.setMode("square") # the default; other options are "x" or "y"
mosaic = m.makeMosaic(im1, im2, im3) # build the mosaic
ds9.mtv(mosaic) # display it
m.drawLabels(["Label 1", "Label 2", "Label 3"]) # label the panels
# alternative way to build a mosaic
images = [im1, im2, im3]
labels = ["Label 1", "Label 2", "Label 3"]
mosaic = m.makeMosaic(images)
ds9.mtv(mosaic)
m.drawLabels(labels)
# Yet another way to build a mosaic (no need to build the images/labels lists)
for i in range(len(images)):
m.append(images[i], labels[i])
# You may optionally include a colour, e.g. ds9.YELLOW, as a third argument
mosaic = m.makeMosaic()
ds9.mtv(mosaic)
m.drawLabels()
You can return the (ix, iy)th (or nth) bounding box (in pixels) with getBBox()
| def lsst.afw.display.utils.Mosaic.append | ( | self, | |
| image, | |||
label = None, |
|||
ctype = None |
|||
| ) |
| def lsst.afw.display.utils.Mosaic.drawLabels | ( | self, | |
labels = None, |
|||
frame = None |
|||
| ) |
Draw the list labels at the corners of each panel. If labels is None, use the ones specified by Mosaic.append()
Definition at line 210 of file utils.py.
| def lsst.afw.display.utils.Mosaic.getBBox | ( | self, | |
| ix, | |||
iy = None |
|||
| ) |
Get the BBox for the nth or (ix, iy)the panel
Definition at line 201 of file utils.py.
| def lsst.afw.display.utils.Mosaic.makeMosaic | ( | self, | |
images = None, |
|||
frame = None, |
|||
mode = None, |
|||
background = None, |
|||
title = "" |
|||
| ) |
Return a mosaic of all the images provided; if none are specified, use the list accumulated with Mosaic.append(). Note that this mosaic is a patchwork of the input images; if you want to make a mosaic of a set images of the sky, you probably want to use the coadd code If frame is specified, display it
Definition at line 94 of file utils.py.
| def lsst.afw.display.utils.Mosaic.reset | ( | self | ) |
| def lsst.afw.display.utils.Mosaic.setBackground | ( | self, | |
| background | |||
| ) |
| def lsst.afw.display.utils.Mosaic.setGutter | ( | self, | |
| gutter | |||
| ) |
| def lsst.afw.display.utils.Mosaic.setMode | ( | self, | |
| mode | |||
| ) |
1.8.5