IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 21, 2007, 2:10:11 PM (19 years ago)
Author:
Paul Price
Message:

Changes to multiple packages in order to use "reduction classes" to
specify recipe names. The idea is to give a group of recipes a
symbolic name, which distinguish how the reduction is to be performed,
without going to all the trouble of changing the recipes themselves.

For example, we might want to turn off the usual
overscan/bias/dark/shutter/flat processing and only do photometry if
we have pre-processed data. Gene also wants a similar ability for
building the flat-field correction.

Added a REDUCTION metadata to the camera configuration that contains
multiple METADATA entries that have recipes for different processing
steps. PS::IPP::Config has a 'reduction' function to return the
appropriate recipe, and this is now used in the scripts. Updated
ippTasks to use these where appropriate.

This necessitated changing the database, so that the desired reduction
class can be specified in the right places. Instructions on converting
an extant database are in dbconfig/changes.txt.

Tested with the SIMTEST, and it works.

There is currently no way of specifying the reduction class when an
exposure proceeds from 'register' to 'chip' (it has to be hacked in
the database directly: "update chipPendingExp set reduction =
'SOME_CLASS' where ..."), but it can be specified when adding a
detrend run or queuing chips with 'chiptool -queue' (the '-reduction'
option). Also, the 'recipe' columns remain throughout the detrend
tables, and they continue to be populated with the actual recipe used
(rather than the reduction class; but that is contained in the
detRun).

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippdb/tests/objectfrommetadata.c

    r13739 r13937  
    10731073            exit(EXIT_FAILURE);
    10741074        }
    1075         if (!psMetadataAddStr(md, PS_LIST_TAIL, "recipe", 0, NULL, "a string")) {
     1075        if (!psMetadataAddStr(md, PS_LIST_TAIL, "reduction", 0, NULL, "a string")) {
    10761076            psFree(md);
    10771077            exit(EXIT_FAILURE);
     
    11121112            exit(EXIT_FAILURE);
    11131113        }
    1114         if (strncmp(object->recipe, "a string", MAX_STRING_LENGTH)) {
     1114        if (strncmp(object->reduction, "a string", MAX_STRING_LENGTH)) {
    11151115            psFree(object);
    11161116            exit(EXIT_FAILURE);
     
    11911191            exit(EXIT_FAILURE);
    11921192        }
    1193         if (!psMetadataAddStr(md, PS_LIST_TAIL, "recipe", 0, NULL, "a string")) {
     1193        if (!psMetadataAddStr(md, PS_LIST_TAIL, "reduction", 0, NULL, "a string")) {
    11941194            psFree(md);
    11951195            exit(EXIT_FAILURE);
     
    12301230            exit(EXIT_FAILURE);
    12311231        }
    1232         if (strncmp(object->recipe, "a string", MAX_STRING_LENGTH)) {
     1232        if (strncmp(object->reduction, "a string", MAX_STRING_LENGTH)) {
    12331233            psFree(object);
    12341234            exit(EXIT_FAILURE);
     
    14891489            exit(EXIT_FAILURE);
    14901490        }
    1491         if (!psMetadataAddStr(md, PS_LIST_TAIL, "recipe", 0, NULL, "a string")) {
     1491        if (!psMetadataAddStr(md, PS_LIST_TAIL, "reduction", 0, NULL, "a string")) {
    14921492            psFree(md);
    14931493            exit(EXIT_FAILURE);
     
    15241524            exit(EXIT_FAILURE);
    15251525        }
    1526         if (strncmp(object->recipe, "a string", MAX_STRING_LENGTH)) {
     1526        if (strncmp(object->reduction, "a string", MAX_STRING_LENGTH)) {
    15271527            psFree(object);
    15281528            exit(EXIT_FAILURE);
     
    15591559            exit(EXIT_FAILURE);
    15601560        }
    1561         if (!psMetadataAddStr(md, PS_LIST_TAIL, "recipe", 0, NULL, "a string")) {
     1561        if (!psMetadataAddStr(md, PS_LIST_TAIL, "reduction", 0, NULL, "a string")) {
    15621562            psFree(md);
    15631563            exit(EXIT_FAILURE);
     
    16571657            exit(EXIT_FAILURE);
    16581658        }
    1659         if (strncmp(object->recipe, "a string", MAX_STRING_LENGTH)) {
     1659        if (strncmp(object->reduction, "a string", MAX_STRING_LENGTH)) {
    16601660            psFree(object);
    16611661            exit(EXIT_FAILURE);
     
    23822382            exit(EXIT_FAILURE);
    23832383        }
     2384        if (!psMetadataAddStr(md, PS_LIST_TAIL, "reduction", 0, NULL, "a string")) {
     2385            psFree(md);
     2386            exit(EXIT_FAILURE);
     2387        }
    23842388        if (!psMetadataAddStr(md, PS_LIST_TAIL, "filter", 0, NULL, "a string")) {
    23852389            psFree(md);
     
    24942498        }
    24952499        if (strncmp(object->exp_type, "a string", MAX_STRING_LENGTH)) {
     2500            psFree(object);
     2501            exit(EXIT_FAILURE);
     2502        }
     2503        if (strncmp(object->reduction, "a string", MAX_STRING_LENGTH)) {
    24962504            psFree(object);
    24972505            exit(EXIT_FAILURE);
Note: See TracChangeset for help on using the changeset viewer.