tsadar.utils.process.prepare#

Functions

prepare_data(config, shotNum)

Prepares and processes experimental data for Thomson scattering analysis.

tsadar.utils.process.prepare.prepare_data(config: Dict, shotNum: int) DictSource#

Prepares and processes experimental data for Thomson scattering analysis. This function loads electron and ion spectral data, applies calibrations, background corrections, and optionally downsamples the data for angular-resolved measurements. It also updates the configuration dictionary with relevant calibration and processing parameters. :param config: Configuration dictionary containing data specifications, processing options, and experiment settings. :type config: Dict :param shotNum: Shot number identifying the experimental dataset to load. :type shotNum: int

Returns:

Tuple[Dict, Dict, Dict] – - all_data (Dict): Dictionary containing processed electron and ion data, amplitudes, and noise estimates. - sa (Dict): Dictionary of scattering angles and relative weights. - all_axes (Dict): Dictionary of calibrated axes for electron and ion spectra.