from abc import ABC, abstractmethod
from .SpectralQty import SpectralQty
from typing import Tuple
[docs]class IRadiant(ABC):
"""
Interface for getting the signal and the background radiation of a emitting, reflecting or transmitting component
in the beam.
"""
[docs] @abstractmethod
def calcSignal(self) -> Tuple[SpectralQty, float]:
"""
Calculate the signal coming from the component
Returns
-------
signal : SpectralQty
The emitted, reflected or transmitted signal
obstruction : float
The obstruction factor as A_ob / A_ap.
"""
pass
[docs] @abstractmethod
def calcBackground(self) -> SpectralQty:
"""
Calculate the background radiation coming from the component
Returns
-------
signal : SpectralQty
The emitted, reflected or transmitted background radiation
"""
pass