Emitters¶
The emitters are the physical light sources of the night sky. Each one is two objects:
a builder –
Emitterand its subclasses – which holds astropy and numpy state and turns anObservationinto arrays, inprepare(obs).a runtime source –
SpectralSource– which the builder hands to the scene inmodel(). It is a JAX pytree, it is traced and differentiated, and it owns everyParameterthe optimizer can reach.
Emitter |
Path |
Scales? |
Model |
|---|---|---|---|
|
diffuse |
no |
ESO SkyCalc, with an SFU curve |
|
diffuse |
yes |
Leinert et al. (1998) |
|
point |
yes |
ROLO, after Jones et al. (2013) |
|
both |
yes |
Gaia DR3 + Pickles (1998) |
|
point |
yes |
XHIP or Gaia, points only |
|
point |
yes |
one source, one spectrum |
“Scales” is whether the emitter takes a brightness: a fittable amplitude
on everything it emits, on both the diffuse and the point path.
Airglow is the exception: its spectral model already evaluates
0.2 + 0.00614 * sfu(t) with a trainable sfu.
Writing your own emitter¶
Subclass Emitter, call super().__init__(geo,
spectral_model, ...) and implement _prepare(obs). The base records the
geometry signature that lets build() catch a
component built against a different Geometry, validates brightness,
and checks the frame count before every prepare.
_prepare returns a SourceObsData. Two flags on
it choose the render path:
directWhether diffuse radiance is extincted along the line of sight.
inscatterWhether point sources are in-scattered individually, giving each its own scattered halo.
The builder layer¶
nyx.emitter.base Module¶
Classes¶
Shared base for |
nyx.emitter.catalog Module¶
Classes¶
A star catalog. |
The runtime layer¶
nyx.emitter.sources Module¶
Classes¶
Routes the diffuse and point paths through one |
Zodiacal Light¶
nyx.emitter.zodiacal Module¶
Classes¶
Zodiacal light with the Leinert spatial model. |
Airglow¶
nyx.emitter.airglow Module¶
Classes¶
Airglow source with van Rhijn weighting. |
Moon¶
nyx.emitter.moon Module¶
Functions¶
|
Fraction of the scattering column above the observer still lit. |
Classes¶
Moon emission model. |
Stars¶
nyx.emitter.stars Module¶
Functions¶
|
Split Gaia DR3 into all-sky point sources and the background they leave. |
Classes¶
Pure point-source star catalog, with no diffuse map. |
|
Star catalog emitter with resolved bright stars and a diffuse map. |
Point Sources¶
nyx.emitter.point_source Module¶
Classes¶
One point source at a fixed ICRS position. |
Catalogs¶
nyx.emitter.catalogs.gaia Module¶
Functions¶
|
Bin catalog stars into a HEALPix linear-flux map. |
|
Reddened Pickles (1998) spectra indexed by the Gaia |
|
Download (once) and load the Gaia DR3 catalog and faint-star map. |
|
|
|
Wrap a |
nyx.emitter.catalogs.xhip Module¶
Functions¶
Positions and photometry from the XHIP compilation (Anderson & Francis 2012). |
|
|
Pickles (1998) spectra indexed by the Johnson V-B colour. |
nyx.emitter.catalogs.astrometry Module¶
Functions¶
|
AltAz pairs as a plain array. |
|
Where coord is, in each observation's AltAz frame. |
|
Great-circle separation in degrees. |
|
Move coord to time along its proper motion, position only. |
|
Rotate a HEALPix map between any two astropy coordinate frames. |
nyx.emitter.catalogs.index Module¶
Classes¶
Cone search over ra/dec, indexed by nested-ordering HEALPix pixel. |