4.1.1.1.1.1.1.1. recipe_system.adcc.client.qap_specviewer package

4.1.1.1.1.1.1.1.1. Submodules

4.1.1.1.1.1.1.1.2. recipe_system.adcc.client.qap_specviewer.mock_json module

This script is used to develop SpecViewer only. It should not be used for production.

It creates a JSON file from a dictionary to be used in the QAP SpecViewer development.

recipe_system.adcc.client.qap_specviewer.mock_json.create_1d_spectrum(width, n_lines, max_weight)[source]

Generates a 1D NDArray with the sky spectrum.

Parameters:
  • width (int) – Number of array elements.
  • n_lines (int) – Number of artificial lines.
  • max_weight (float) – Maximum weight (or flux, or intensity) of the lines.
Returns:

sky_1d_spectrum

Return type:

numpy.ndarray

recipe_system.adcc.client.qap_specviewer.mock_json.main()[source]

4.1.1.1.1.1.1.1.3. recipe_system.adcc.client.qap_specviewer.mock_primitive module

Mock plotSpectraForQA primitive.

This module emulates a pipeline that reproduces how the plotSpectraForQA would behave in real time.

In practice, it creates JSON data and send it to the ADCC Server in a timed loop.

class recipe_system.adcc.client.qap_specviewer.mock_primitive.ApertureModel(center, lower, upper, wavelength_units, dispersion, wavelength, intensity, error)[source]

Bases: object

class recipe_system.adcc.client.qap_specviewer.mock_primitive.SpecPackModel(data_label, group_id, filename, is_stack, pixel_scale, program_id, stack_size, apertures)[source]

Bases: object

recipe_system.adcc.client.qap_specviewer.mock_primitive.create_1d_spectrum(width, n_lines, max_weight)[source]

Generates a 1D NDArray that simulates a random spectrum.

Parameters:
  • width (int) – Number of array elements.
  • n_lines (int) – Number of artificial lines.
  • max_weight (float) – Maximum weight (or flux, or intensity) of the lines.
Returns:

sky_1d_spectrum

Return type:

numpy.ndarray

recipe_system.adcc.client.qap_specviewer.mock_primitive.main()[source]

Main function.

4.1.1.1.1.1.1.1.4. recipe_system.adcc.client.qap_specviewer.mock_qlook module