gauss_2d_func

erwans3.utils.gauss_2d_func(amp: Union[float, Quantity], x0: Union[float, Quantity], y0: Union[float, Quantity], sigx: Union[float, Quantity], sigy: Union[float, Quantity], bkg: Optional[Union[float, Quantity]] = None, norm: bool = False) Callable[[Union[float, ndarray, Quantity]], Union[float, ndarray, Quantity]]

Create a 2D Gaussian function.

Parameters:
  • amp (float or Quantity) – Amplitude of the Gaussian.

  • x0 (float or Quantity) – X-coordinate of the center of the Gaussian along the x-axis.

  • y0 (float or Quantity) – Y-coordinate of the center of the Gaussian along the y-axis.

  • sigx (float or Quantity) – Standard deviation of the Gaussian along the x-axis.

  • sigy (float or Quantity) – Standard deviation of the Gaussian along the y-axis.

  • bkg (float or Quantity or None, optional) – Background value to add to the Gaussian. Default is None.

  • norm (bool, optional) – If True, normalize the Gaussian. Default is False.

Returns:

A callable function that computes the value of the 2D Gaussian function at given positions (x, y).

Return type:

Callable