Enum OOBPolicy

Enum Documentation

enum class specsyn::OOBPolicy : std::uint8_t

Specifies how a Specsyn class handles out-of-bounds stars.

An out-of-bounds star is one whose properties (e.g. logg, Teff) place it outside the domain a given Specsyn class can compute a spectrum for – for example, a star that falls outside a SpecsynLib’s (FeH, logg, Teff) tensor grid. This is a template parameter, rather than a runtime flag, so that the choice of behavior can be compiled directly into the hot spec() path instead of requiring a runtime branch.

Values:

enumerator raise

Throw a runtime error for an out-of-bounds star

enumerator silent

Silently return a spectrum of size 0 for an out-of-bounds star

enumerator coerce

Coerce an out-of-bounds star with at least one valid neighboring grid point to the nearest point it can be interpolated from, rather than treating it as out of bounds