sep.kron_radius(data, x, y, a, b, theta, r, mask=None, maskthresh=0.0, seg_id=None, segmap=None)
$\sum_i r_i I(r_i) / \sum_i I(r_i)$
where the sum is over all pixels in the aperture and the radius is given in units of a and b: r_i is the distance to the pixel relative to the distance to the ellipse specified by a, b, theta. Equivalently, after converting the ellipse parameters to their coefficient representation, r_i is given by
$r_i^2 = cxx(x_i - x)^2 + cyy(y_i - y)^2 + cxx(x_i - x)(y_i - y)$
Parameters: data : ndarray Data array. x, y : array_like Ellipse center(s). a, b, theta : array_like Ellipse parameters. r : array_like “Radius” of ellipse over which to integrate. If the ellipse extent correponds to second moments of an object, this is the number of “isophotal radii” in Source Extractor parlance. A Fixed value of 6 is used in Source Extractor. mask : numpy.ndarray, optional An optional mask. maskthresh : float, optional Pixels with mask > maskthresh will be ignored. segmap : ndarray, optional Segmentation image with dimensions of data and dtype np.int32. This is an optional input and corresponds to the segmentation map output by extract. seg_id : array_like, optional Array of segmentation ids used to mask additional pixels in the image. Dimensions correspond to the dimensions of x and y. The behavior differs depending on whether seg_id is negative or positive. If seg_id is positive, all pixels belonging to other objects are masked. (Pixel j, i is masked if seg[j, i] != seg_id and seg[j, i] != 0). If seg_id is negative, all pixels other than those belonging to the object of interest are masked. (Pixel j, i is masked if seg[j, i] != -seg_id). NB: must be included if segmap` is provided. kronrad : array_like The Kron radius. flag : array_like Integer value indicating conditions about the aperture or how many masked pixels it contains.