|
lsst.afw g7876432fea+de8826df4f
|
Public Member Functions | |
| __init__ (self, bands, image, mask, variance) | |
| setXY0 (self, xy0) | |
| shiftedTo (self, xy0) | |
| clone (self, deep=True) | |
| image (self) | |
| mask (self) | |
| variance (self) | |
| getBBox (self, origin=PARENT) | |
| y0 (self) | |
| x0 (self) | |
| bands (self) | |
| singles (self) | |
| filters (self) | |
| getXY0 (self) | |
| origin (self) | |
| width (self) | |
| height (self) | |
| __len__ (self) | |
| __getitem__ (self, args) | |
| __iter__ (self) | |
| __next__ (self) | |
| shiftedBy (self, offset) | |
| __repr__ (self) | |
| __str__ (self) | |
Public Attributes | |
| y0 | |
| x0 | |
| bands | |
| singles = Box2I(xy0, self._bbox.getDimensions()) | |
| array | |
Protected Member Functions | |
| _slice (self, bands, bandIndex, indices) | |
| _verifyUpdate (self, image=None, mask=None, variance=None) | |
| _bandNamesToIndex (self, bandIndex) | |
Protected Attributes | |
| _image = image | |
| _mask = mask | |
| _variance = variance | |
| _bands = tuple([f for f in bands]) | |
| _singles = tuple(singles) | |
| _bbox = self._singles[0].getBBox() | |
| int | _bandIndex = 0 |
MultibandTripleBase class This is a base class inherited by multiband classes with `image`, `mask`, and `variance` objects, such as `MultibandMaskedImage` and `MultibandExposure`. Parameters ---------- bands : `list` List of band names. If `singles` is an `OrderedDict` then this argument is ignored, otherwise it is required. image : `list` or `MultibandImage` List of `Image` objects that represent the image in each band or a `MultibandImage`. Ignored if `singles` is not `None`. mask : `list` or `MultibandMask` List of `Mask` objects that represent the mask in each bandor a `MultibandMask`. Ignored if `singles` is not `None`. variance : `list` or `MultibandImage` List of `Image` objects that represent the variance in each bandor a `MultibandImage`. Ignored if `singles` is not `None`.
Definition at line 554 of file _multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.__init__ | ( | self, | |
| bands, | |||
| image, | |||
| mask, | |||
| variance ) |
Definition at line 579 of file _multiband.py.
|
inherited |
Get a slice of the underlying array If only a single band is specified, return the single band object sliced appropriately.
Definition at line 159 of file multiband.py.
|
inherited |
Definition at line 184 of file multiband.py.
|
inherited |
Definition at line 156 of file multiband.py.
|
inherited |
Definition at line 188 of file multiband.py.
|
inherited |
Definition at line 322 of file multiband.py.
|
inherited |
Definition at line 327 of file multiband.py.
|
protectedinherited |
Convert a list of band names to an index or a slice
Parameters
----------
bandIndex: iterable or `object`
Index to specify a band or list of bands,
usually a string or enum.
For example `bandIndex` can be
`"R"` or `["R", "G", "B"]` or `[Band.R, Band.G, Band.B]`,
if `Band` is an enum.
Returns
-------
bandNames: `list`
Names of the bands in the slice
bandIndex: `slice` or `list` of `int`
Index of each band in `bandNames` in
`self.bands`.
Definition at line 196 of file multiband.py.
|
protected |
Slice the current object and return the result See `Multiband._slice` for a list of the parameters.
Reimplemented from lsst.afw.multiband.MultibandBase.
Reimplemented in lsst.afw.image._exposure._multiband.MultibandExposure.
Definition at line 653 of file _multiband.py.
|
protected |
Check that the new image, mask, or variance is valid This basically means checking that the update to the property matches the current bounding box and inherits from the `MultibandBase` class.
Definition at line 680 of file _multiband.py.
|
inherited |
List of band names for the single band objects
Definition at line 98 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.clone | ( | self, | |
| deep = True ) |
Make a copy of the current instance
Reimplemented from lsst.afw.multiband.MultibandBase.
Definition at line 639 of file _multiband.py.
|
inherited |
List of filter names for the single band objects (deprecated) Use `bands` instead.
Definition at line 90 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.getBBox | ( | self, | |
| origin = PARENT ) |
Bounding box
Reimplemented from lsst.afw.multiband.MultibandBase.
Definition at line 710 of file _multiband.py.
|
inherited |
Minimum coordinate in the bounding box
Definition at line 114 of file multiband.py.
|
inherited |
Height of the images
Definition at line 151 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.image | ( | self | ) |
The image of the MultibandMaskedImage
Definition at line 696 of file _multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.mask | ( | self | ) |
The mask of the MultibandMaskedImage
Definition at line 701 of file _multiband.py.
|
inherited |
Minimum (y,x) position This is the position of `self.getBBox().getMin()`, but available as a tuple for numpy array indexing.
Definition at line 136 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.setXY0 | ( | self, | |
| xy0 ) |
Shift the bounding box but keep the same Extent This is different than `MultibandBase.setXY0` because the multiband `image`, `mask`, and `variance` objects must all have their bounding boxes updated. Parameters ---------- xy0 : `Point2I` New minimum bounds of the bounding box
Reimplemented from lsst.afw.multiband.MultibandBase.
Definition at line 595 of file _multiband.py.
|
inherited |
Shift a bounding box by an offset, but keep the same Extent
This method is broken until DM-10781 is completed.
Parameters
----------
offset: `Extent2I`
Amount to shift the bounding box in x and y.
Returns
-------
result: `MultibandBase`
A copy of the object, shifted by `offset`
Definition at line 274 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.shiftedTo | ( | self, | |
| xy0 ) |
Shift the bounding box but keep the same Extent This is different than `MultibandBase.shiftedTo` because the multiband `image`, `mask`, and `variance` objects must all have their bounding boxes updated. Parameters ---------- xy0 : `Point2I` New minimum bounds of the bounding box Returns ------- result : `MultibandBase` A copy of the object, shifted to `xy0`.
Reimplemented from lsst.afw.multiband.MultibandBase.
Definition at line 612 of file _multiband.py.
|
inherited |
List of single band objects
Definition at line 104 of file multiband.py.
| lsst.afw.image._image._multiband.MultibandTripleBase.variance | ( | self | ) |
The variance of the MultibandMaskedImage
Definition at line 706 of file _multiband.py.
|
inherited |
Width of the images
Definition at line 145 of file multiband.py.
|
inherited |
X0 X component of XY0 `Point2I.getX()`
Definition at line 120 of file multiband.py.
|
inherited |
Y0 Y component of XY0 `Point2I.getY()`
Definition at line 128 of file multiband.py.
|
protectedinherited |
Definition at line 185 of file multiband.py.
|
protectedinherited |
Definition at line 57 of file multiband.py.
|
protectedinherited |
Definition at line 61 of file multiband.py.
|
protected |
Definition at line 588 of file _multiband.py.
|
protected |
Definition at line 589 of file _multiband.py.
|
protectedinherited |
Definition at line 58 of file multiband.py.
|
protected |
Definition at line 590 of file _multiband.py.
|
inherited |
Definition at line 329 of file multiband.py.
|
inherited |
Definition at line 157 of file multiband.py.
|
inherited |
Definition at line 249 of file multiband.py.
|
inherited |
Definition at line 142 of file multiband.py.
|
inherited |
Definition at line 142 of file multiband.py.