SkyFitter
- class ctapointing.imagesolver.SkyFitter(**kwargs: Any)
Bases:
ComponentSky fitting class
Fits a list of spots to matched stars using the full transformation tree or an astropy WCS transformation
Attributes Summary
fit distance goal
fit camera distortion parameters
list of parameters fixed during fitting
maximum number of fit iterations
name of SkyFitter
cut value for spot outlier removal
UUID of SkyFitter
Methods Summary
from_config(**kwargs)Read a SkyFitter configuration from either configuration file or database.
process(spot_star_match_list, exposure[, ...])Fit a list of spots to pre-matched stars to find the transformation parameters for coordinate transformations from pixel coordinates to sky coordinates.
Attributes Documentation
- distance_goal
fit distance goal
- fit_camera_distortion
fit camera distortion parameters
- fixed_parameters
list of parameters fixed during fitting
- max_num_fit_iterations
maximum number of fit iterations
- name
name of SkyFitter
- residual_cut
cut value for spot outlier removal
- uuid
UUID of SkyFitter
Methods Documentation
- classmethod from_config(**kwargs)
Read a SkyFitter configuration from either configuration file or database. Either the path of a configuration file (‘input_url’) or a database collection (‘collection’) must be provided.
- Parameters:
input_url (str or Path) – path of the configuration file.
name (str) – name of the SpotExtractor (as in SkyFitter.name). When loading the configuration from file, can be set to check that the configuration with the correct name is loaded. When loading from database, is used to identify the correct database record.
uuid (str) – UUID of the camera (as in PointingCamera.uuid). When loading the configuration from file, can be set to check that the configuration with the correct UUID is loaded. When loading from database, is used to identify the correct database record.
collection (str) – name of the database collection from which configuration is read
database (str) – name of the database in which the collection is stored
- Returns:
fitter
- Return type:
SkyFitter object or None
- process(spot_star_match_list, exposure, estimated_pointing=None, distortion_correction=None, image_solution=None)
Fit a list of spots to pre-matched stars to find the transformation parameters for coordinate transformations from pixel coordinates to sky coordinates.
The fit uses the full (non-idealised) set of coordinate transformations, taking into account refraction effects in the atmosphere and lens distortion.
- Parameters:
spot_star_match_list (list) – list of StarSpotMatch objects that contain information about the pre-matched spot-star pairs
exposure (Exposure) – exposure object, holding information about the actual exposure (camera properties etc.)
estimated_pointing (astropy.SkyCoord) – estimated telescope pointing position (in the ICRS frame)
image_solution (ctapointing.imagesolver.ImageSolution) – image solution object that is updated with fit results. If None, a new object is created.
- Returns:
solution (ImageSolution) – ImageSolution object containing summary information on the result
m (iminuit.minuit) – minuit object for the sky -> pixels fit
m_inv (iminuit.minuit) – minuit object for the pixel -> intermediate pixel coordinates fit
- distance_goal
fit distance goal
- fit_camera_distortion
fit camera distortion parameters
- fixed_parameters
list of parameters fixed during fitting
- classmethod from_config(**kwargs)
Read a SkyFitter configuration from either configuration file or database. Either the path of a configuration file (‘input_url’) or a database collection (‘collection’) must be provided.
- Parameters:
input_url (str or Path) – path of the configuration file.
name (str) – name of the SpotExtractor (as in SkyFitter.name). When loading the configuration from file, can be set to check that the configuration with the correct name is loaded. When loading from database, is used to identify the correct database record.
uuid (str) – UUID of the camera (as in PointingCamera.uuid). When loading the configuration from file, can be set to check that the configuration with the correct UUID is loaded. When loading from database, is used to identify the correct database record.
collection (str) – name of the database collection from which configuration is read
database (str) – name of the database in which the collection is stored
- Returns:
fitter
- Return type:
SkyFitter object or None
- max_num_fit_iterations
maximum number of fit iterations
- name
name of SkyFitter
- process(spot_star_match_list, exposure, estimated_pointing=None, distortion_correction=None, image_solution=None)
Fit a list of spots to pre-matched stars to find the transformation parameters for coordinate transformations from pixel coordinates to sky coordinates.
The fit uses the full (non-idealised) set of coordinate transformations, taking into account refraction effects in the atmosphere and lens distortion.
- Parameters:
spot_star_match_list (list) – list of StarSpotMatch objects that contain information about the pre-matched spot-star pairs
exposure (Exposure) – exposure object, holding information about the actual exposure (camera properties etc.)
estimated_pointing (astropy.SkyCoord) – estimated telescope pointing position (in the ICRS frame)
image_solution (ctapointing.imagesolver.ImageSolution) – image solution object that is updated with fit results. If None, a new object is created.
- Returns:
solution (ImageSolution) – ImageSolution object containing summary information on the result
m (iminuit.minuit) – minuit object for the sky -> pixels fit
m_inv (iminuit.minuit) – minuit object for the pixel -> intermediate pixel coordinates fit
- residual_cut
cut value for spot outlier removal
- uuid
UUID of SkyFitter