gauss_2d
- erwans3.utils.gauss_2d(amp: Union[float, Quantity], x0: Union[float, Quantity], x: Union[float, ndarray, Quantity], y0: Union[float, Quantity], y: Union[float, ndarray, Quantity], sigx: Union[float, Quantity], sigy: Union[float, Quantity], bkg: Optional[Union[float, Quantity]] = None, norm: bool = False) Union[float, Quantity]
Compute the value of a 2D Gaussian function at given positions.
- Parameters:
x0 (
floatorQuantity) – X-coordinate of the center of the Gaussian along the x-axis.x (
float, array-like, orQuantity) – X-coordinate(s) where to evaluate the Gaussian.y0 (
floatorQuantity) – Y-coordinate of the center of the Gaussian along the y-axis.y (
float, array-like, orQuantity) – Y-coordinate(s) where to evaluate the Gaussian.sigx (
floatorQuantity) – Standard deviation of the Gaussian along the x-axis.sigy (
floatorQuantity) – Standard deviation of the Gaussian along the y-axis.bkg (
floatorQuantity, optional) – Background value to add to the Gaussian. Default is None.norm (
bool, optional) – If True, normalize the Gaussian. Default is False.
- Returns:
Value of the 2D Gaussian function at the specified positions.
- Return type: