ellipticity_from_shape

lsst.validate.drp.util.ellipticity_from_shape(shape)

Calculate the ellipticty of shape from its moments.

Parameters:
shape : lsst.afw.geom.Quadrupole

The LSST generic shape object returned by psf.computeShape() or source.getShape() for a specific source. Imeplementation: just needs to have .getIxx, .getIxy, .getIyy methods that each return a float describing the respective second moments.

Returns:
e, e1, e2 : complex, float, float

Complex ellipticity, real part, imaginary part