get_amplitude_at_r

petrofit.segmentation.get_amplitude_at_r(r, image, x0, y0, ellip, theta)[source]

Finds the amplitude at an isophotal radius r.

Parameters:
rfloat or int

Isophotal radius in pixels.

imageCCDData or array

Image to of the source.

x0, y0float

The center pixel coordinate of the ellipse.

ellipellipticity

The ellipticity of the ellipse.

thetafloat

The position angle (in radians) of the semimajor axis in relation to the positive x axis of the image array (rotating towards the positive y axis). Position angles are defined in the range \(0 < PA <= \pi\). Avoid using as starting position angle of 0., since the fit algorithm may not work properly. When the ellipses are such that position angles are near either extreme of the range, noise can make the solution jump back and forth between successive isophotes, by amounts close to 180 degrees.

Returns:
amplitude_at_rfloat or np.nan