Create initial generalized raster fit function
(2) A fitting routine that applies the fit structure to a 3D cube consisting of a spectrum at every point
(2) Gridmodel_test – this demos the raster fitting. It creates an array of the astropy models and fits them to a data cube.
See FitDialog/GridModel_test_TAKannotationv3.py for starter code. Also FitDialog_schmidt/multi_gridmodel.py
I want a stand alone function or procedure based on this
Inputs:
Array of wavelengths
Cube of intensities as a function of wavelength, and other dimensions (generally x and y).
Cube of uncertainties on the intensities – same size as the intensity cube
Model – the astropy model as a template for the fits – created by the user or with the GUI in the last step
Optional Inputs:
Starter values for the parameters for each of the intensities. This can be from the previous fit. Maybe an earlier grid of astropy models? Would be best if it was consistent with the output of the routine
Outputs: the results of the fit, including uncertainties and the goodness of fit parameter. This might include a grid of astropy models.
-
Modify/reuse Ed's GridModel code as needed to create this stand alone function - with mandatory starter values passed
Edited by Ayris Narock