prsctrl.measurement.plan.divide_into_parts_from_DC#

divide_into_parts_from_DC(dc_spectrum: ndarray[tuple[Any, ...], dtype[_ScalarT]], dc_spectrum_cols: list[str], Es: ndarray[tuple[Any, ...], dtype[_ScalarT]] | None = None, wls: ndarray[tuple[Any, ...], dtype[_ScalarT]] | None = None, which_modes: list[str] | None = None, max_parts: int | None = None, dc_min_V: float = 0.01, dc_max_V: float = 10.0) → dict[str, list[ndarray[tuple[Any, ...], dtype[_ScalarT]], int]][source]#

Divide the desired spectral range into multiple parts to make the DC values do not become too high or too low.

Parameters:
  • dc_spectrum – DC spectrum data with dc_spectrum_cols.

  • dc_spectrum_cols –

    Columns into dc_spectrum. Must contain

    • wl or E

    • R if “ref” in which_modes and T if “tra” in which_modes

    • gain

  • Es – Energy (eV) points to include in the spectrum. Exactly one of Es or wls must be given.

  • wls – Wavelength (nm) points to include in the spectrum. Exactly one of Es or wls must be given.

  • which_modes – List of modes to include. Defaults to [“ref”, “tra”].

  • max_parts – Maximum number of parts into which the spectrum may be split up.

  • dc_min_V – Minimum DC value to consider acceptable.

  • dc_max_V – Maximum DC value to consider acceptable.

Returns:

Dictionary of mode - list of (Es or wls, gain)