astra.contrib.thecannon.tasks.test¶
Module Contents¶
Classes¶
TestTheCannon |
A mixin class all tasks related to The Cannon. |
EstimateStellarLabelsGivenApStarFileBase |
A task to train The Cannon, given some file that contains high-quality labels, |
-
class
astra.contrib.thecannon.tasks.test.TestTheCannon¶ A mixin class all tasks related to The Cannon.
Parameters: - label_names – A list of label names.
- order – (optional) The polynomial order to use for this model (default: 2).
-
N_initialisations¶
-
use_derivatives¶
-
task_namespace= TheCannon¶
-
label_names¶
-
order¶
-
requires(self)¶
-
output(self)¶
-
read_observation(self)¶ Read the input observation, and if continuum is a requirement, normalize it.
-
prepare_observation(self, dispersion, spectrum=None, continuum=None)¶
-
read_model(self)¶
-
run(self)¶
-
class
astra.contrib.thecannon.tasks.test.EstimateStellarLabelsGivenApStarFileBase¶ A task to train The Cannon, given some file that contains high-quality labels, and pseudo-continuum-normalised fluxes and inverse variances.
Parameters: - training_set_path –
The path to a
picklefile that contains a dictionary with the following keys:wavelength: an array of shape(P, )wherePis the number of pixelsflux: an array of flux values with shape(N, P)whereNis the number of observed spectra andPis the number of pixelsivar: an array of inverse variance values with shape(N, P)whereNis the number of observed spectra andPis the number of pixelslabels: an array of shape(L, N)whereLis the number of labels andNis the number observed spectralabel_names: a tuple of lengthLthat describes the names of the labels
- regularization – (optional) The L1 regularization strength to use during training (default: 0.0).
- threads – (optional) The number of threads to use during training (default: 1).
- plot – (optional) Produce quality assurance figures after training (default: True).
-
training_set_path¶
-
regularization¶
-
threads¶
-
plot¶
-
task_namespace= TheCannon¶
-
label_names¶
-
order¶
-
N_initialisations¶
-
use_derivatives¶
-
requires(self)¶ Requirements of this task.
-
run(self)¶ Execute this task.
-
output(self)¶ The output of this task.
-
read_observation(self)¶ Read the input observation, and if continuum is a requirement, normalize it.
-
prepare_observation(self, dispersion, spectrum=None, continuum=None)¶
-
read_model(self)¶
- training_set_path –