DustComponent#
- class scarlet2.DustComponent(center, spectrum, morphology)[source]#
Bases:
ComponentComponent with negative exponential model
This component is meant to describe the dust attenuation, \(\exp(-\tau)\), where \(\tau\) is the hyperspectral model defined by the base
Component.- Parameters:
center (
array,astropy.coordinates.SkyCoord) – Center position. If given as astropy sky coordinate, it will be transformed with the WCS of the model frame.spectrum (
Spectrum) – The spectrum of the component.morphology (
Morphology) – The morphology of the component.
Examples
To uniquely determine coordinates, the creation of components is restricted to a context defined by a
Scene, which define theFrameof the model.>>> with Scene(model_frame) as scene: >>> component = Component(center, spectrum, morphology)
- center: jnp.ndarray#
Center position, in pixel coordinates of the model frame
- 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
- morphology: jnp.array, Morphology#
Morphology model
- 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: