32#include "iiinstrument_utils.h"
33#include "iiinstrument_dfs.h"
56 const char *iiinstrument_license = cpl_get_license(
"IIINSTRUMENT",
"2002,2018");
58 return iiinstrument_license ;
71 cpl_frameset *frameset)
74 cpl_size nframes = cpl_frameset_get_size(frameset);
76 for (i = 0; i < nframes; i++) {
78 cpl_frame *frame = cpl_frameset_get_position(frameset, i);
79 const char *filename = cpl_frame_get_filename(frame);
83 if (cpl_fits_count_extensions(filename) < 0){
85 return cpl_error_set_message(cpl_func, cpl_error_get_code(),
86 "Problem with the file '%s' (%s --> Code %d)",
87 filename, cpl_error_get_message(), cpl_error_get_code());
95 return cpl_error_set_message(cpl_func, CPL_ERROR_DATA_NOT_FOUND,
96 "Cannot classify RAW and/or CALIB frames");
100 for (i = 0; i < nframes; i++) {
102 cpl_frame *frame = cpl_frameset_get_position(frameset, i);
103 const char *tag = cpl_frame_get_tag(frame);
104 cpl_frame_group group = cpl_frame_get_group(frame);
107 if (group == CPL_FRAME_GROUP_NONE) {
108 return cpl_error_set_message(cpl_func, CPL_ERROR_INCOMPATIBLE_INPUT,
109 "Frame:%lld with tag:%s is invalid", i, tag);
114 return CPL_ERROR_NONE;
cpl_error_code iiinstrument_dfs_set_groups(cpl_frameset *set)
Set the group as RAW or CALIB in a frameset.
const char * iiinstrument_get_license(void)
Get the pipeline copyright and license.
cpl_error_code iiinstrument_check_and_set_groups(cpl_frameset *frameset)
check the entries in the recipe and classify the frameset with the tags