|
ERIS Pipeline Reference Manual 1.9.2
|
Functions | |
| cpl_error_code | enm_associate_std (cpl_table *objtab, cpl_table *stdtab, const float assoc, const int strict_classification, cpl_table **associated_std) |
| Associate image catalogue objects with standards. | |
| cpl_error_code | enm_correct_crpix (const char *wcs_method, const char *catalogue, cpl_table *matched_stds, located_image *limage, cpl_matrix **xy_shift) |
| Apply median offsets from matched standards table to image. | |
| cpl_error_code | enm_try_all_associations (cpl_table *objtab, cpl_table *stdtab, const double match_rad, cpl_table **matchtab) |
| Match standards with objects by trying all possibilities and selecting best. | |
| cpl_error_code | enm_try_association (const double xstd[], const double ystd[], const cpl_size nstd, const double xobj[], const double yobj[], const cpl_size nobj, const cpl_size is, const cpl_size io, cpl_matrix **distances) |
| Method to calculate 'distances' matrix given an object association. | |
| cpl_error_code enm_associate_std | ( | cpl_table * | objtab, |
| cpl_table * | stdtab, | ||
| const float | assoc, | ||
| const int | strict_classification, | ||
| cpl_table ** | associated_std | ||
| ) |
Associate image catalogue objects with standards.
| objtab | Table of objects in image |
| stdtab | Table of standards |
| assoc | Radius of association (pixels) |
| strict_classification | True to only consider stellar round objects |
| associated_std | A table containing data for the associated objects |
The routine matches catalogue objects with standards that lie within 'assoc' pixels. If either image or standard catalogue is NULL then the routine returns immediately with no error and without modifying associated_std.
Definition at line 72 of file eris_nix_match.c.
| cpl_error_code enm_correct_crpix | ( | const char * | wcs_method, |
| const char * | catalogue, | ||
| cpl_table * | matched_stds, | ||
| located_image * | limage, | ||
| cpl_matrix ** | xy_shift | ||
| ) |
Apply median offsets from matched standards table to image.
| wcs_method | String describing the correction method |
| catalogue | Name of reference catalogue |
| matched_stds | Table of matched standards |
| limage | The image to be corrected |
| xy_shift | Matrix containing corrections applied |
The routine calculates the median shifts in x and y implicit in the coordinates in the matched_stds table. These shifts are applied to the CRPIX1 and CRPIX2 keywords in the image to line up the object and standard positions.
Definition at line 278 of file eris_nix_match.c.
Referenced by enu_correct_wcs().
| cpl_error_code enm_try_all_associations | ( | cpl_table * | objtab, |
| cpl_table * | stdtab, | ||
| const double | match_rad, | ||
| cpl_table ** | matchtab | ||
| ) |
Match standards with objects by trying all possibilities and selecting best.
| objtab | Table of objects in image. |
| stdtab | Table of standards to pattern match. |
| match_rad | Max distance between matching obj and std (pixels). |
| matchtab | Pointer to table with matched standard/object pairs. |
An object table from hdrl_catalogue and a standard star table, from either casu_getstds or hdrl_catalogue, are given.
All possible associations between standards and objects are tried and a metric of the pattern match is calculated for each - that is, the number of std/obj pairs that lie within 'match_rad' pixels of each other.
The association with the highest metric is selected, and a table is constructed of the std/obj matches found for it.
Definition at line 400 of file eris_nix_match.c.
References enm_try_association().
Referenced by enu_correct_wcs().
| cpl_error_code enm_try_association | ( | const double | xstd[], |
| const double | ystd[], | ||
| const cpl_size | nstd, | ||
| const double | xobj[], | ||
| const double | yobj[], | ||
| const cpl_size | nobj, | ||
| const cpl_size | is, | ||
| const cpl_size | io, | ||
| cpl_matrix ** | distances | ||
| ) |
Method to calculate 'distances' matrix given an object association.
| xstd | Array containing x-coords of standards |
| ystd | Array containing y-coords of standards |
| nstd | Number of standards |
| xobj | Array containing x-coords of objects |
| yobj | Array containing y-coords of objects |
| nobj | Number of objects |
| is | Index of match standard |
| io | Index of match object |
| distances | out cpl_matrix containing the resulting distances between matched stds/objs |
Arrays with x,y coords of standards and objects are given, and a specification of which standard and which object are to be matched. The routine calculates the implied offset between standards and objects, and shifts the objects by this amount to now be in the 'standard' frame. A matrix is populated with the distances between each standard and each object, and returned.
Definition at line 677 of file eris_nix_match.c.
Referenced by enm_try_all_associations().