GaussianMorphology#

class scarlet2.GaussianMorphology(size, ellipticity=None, shape=None)[source]#

Bases: ProfileMorphology

Gaussian radial profile

__call__(delta_center=Array([0., 0.], dtype=float32))[source]#

Evaluate the model

ellipticity: None, jnp.array#

Ellipticity of the profile

f(r2)[source]#

Radial profile function

Parameters:

r2 (float or array) – Radius (distance from the center) squared

static from_image(image)[source]#

Create Gaussian radial profile from the 2nd moments of image

Parameters:

image (array) – 2D array to measure Moments from.

Return type:

GaussianMorphology

static from_moments(g, shape=None)[source]#

Create Gaussian radial profile from the moments g

Parameters:
  • g (Moments) – Moments, order >= 2

  • shape (tuple) – Shape of the bounding box

Return type:

GaussianMorphology

get(name=None)#

Get parameter(s) from this module

Parameters:

name (str, optional) – Name of parameter. If not set, returns all parameters.

Returns:

requested data arrays for parameters

Return type:

dict

property parameters#

Parameters defined for this module

Returns:

name: (node, param) mapping for all parameters

Return type:

dict

set(values)#

Set parameter(s) from this module with values

Parameters:

values (dict[str,jnp.array]) – values to replace parameters with, identified by their name

Returns:

new module with parameter(s) replaced by values

Return type:

Module

property shape#

Shape of the bounding box for the profile.

If not set during __init__, uses a square box with an odd number of pixels not smaller than 10*size.

size: float#

Size of the profile

Can be given as an astropy angle, which will be transformed with the WCS of the current Scene.