IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 24487


Ignore:
Timestamp:
Jun 18, 2009, 10:55:36 AM (17 years ago)
Author:
Paul Price
Message:

Adding reduction classes to warp stage.

Location:
trunk
Files:
14 edited

Legend:

Unmodified
Added
Removed
  • trunk/dbconfig/changes.txt

    r24174 r24487  
    11261126
    11271127-- Version 1.1.53
     1128
     1129ALTER TABLE warpRun ADD COLUMN reduction VARCHAR(64) AFTER tess_id;
  • trunk/dbconfig/warp.md

    r23688 r24487  
    1919    dvodb       STR         255
    2020    tess_id     STR         64
     21    reduction   STR         64
    2122    end_stage   STR         64      # Key
    2223    registered  TAI         NULL
  • trunk/ippScripts/scripts/warp_skycell.pl

    r24205 r24487  
    3636}
    3737
    38 my ($warp_id, $skycell_id, $warp_skyfile_id, $tess_dir, $camera, $dbname, $outroot, $threads, $run_state, $magicked, $verbose, $no_update, $no_op, $redirect, $save_temps);
     38my ($warp_id, $skycell_id, $warp_skyfile_id, $tess_dir, $reduction, $camera, $dbname, $outroot, $threads, $run_state, $magicked, $verbose, $no_update, $no_op, $redirect, $save_temps);
    3939GetOptions(
    4040    'warp_id|i=s'         => \$warp_id, # Warp identifier
     
    4444    'camera|c=s'          => \$camera, # Camera name
    4545    'dbname|d=s'          => \$dbname, # Database name
     46    'reduction=s'         => \$reduction, # Reduction class
    4647    'outroot=s'           => \$outroot, # Output root name
    4748    'threads=s'           => \$threads,   # Number of threads to use for pswarp
     
    7374
    7475$ipprc->redirect_output($logDest) or my_die( "Unable to redirect output", $warp_id, $skycell_id, $tess_dir, $PS_EXIT_SYS_ERROR ) if $redirect;
     76
     77# Recipes to use based on reduction class
     78$reduction = 'DEFAULT' unless defined $reduction;
     79my $recipe_pswarp = $ipprc->reduction($reduction, 'WARP_PSWARP'); # Recipe to use for ppImage
     80unless ($recipe_pswarp) {
     81    &my_die("Couldn't find selected reduction for WARP_PSWARP: $reduction\n", $warp_id, $skycell_id, $tess_dir, $PS_EXIT_CONFIG_ERROR);
     82}
    7583
    7684my $source_id = $ipprc->source_id($dbname, $PS_TABLE_ID_WARP);
     
    102110my $astromSource;               # The astrometry source
    103111{
    104     my $command = "$ppConfigDump -camera $camera -dump-recipe PSWARP -";
     112    my $command = "$ppConfigDump -camera $camera -recipe PSWARP $recipe_pswarp -dump-recipe PSWARP -";
    105113    my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
    106114        run(command => $command, verbose => $verbose);
     
    192200    $command .= " -F SOURCE.PLOT.PSFMODEL SOURCE.PLOT.SKY.PSFMODEL";
    193201    $command .= " -F SOURCE.PLOT.APRESID SOURCE.PLOT.SKY.APRESID";
     202    $command .= " -recipe PSWARP $recipe_pswarp";
    194203    $command .= " -psf";        # Turn on PSF determination
    195204    $command .= " -tracedest $traceDest -log $logDest";
  • trunk/ippTasks/warp.pro

    r24195 r24487  
    297297    # XXX change tess_id to tess_dir when schema is changed
    298298    book getword warpPendingSkyCell $pageName tess_id -var TESS_DIR
     299    book getword warpPendingSkyCell $pageName reduction -var REDUCTION
    299300    book getword warpPendingSkyCell $pageName exp_tag -var EXP_TAG
    300301    book getword warpPendingSkyCell $pageName state -var RUN_STATE
     
    317318    stderr $LOGDIR/warp.skycell.log
    318319
    319     $run = warp_skycell.pl --threads @MAX_THREADS@ --warp_id $WARP_ID --warp_skyfile_id $WARP_SKYFILE_ID --skycell_id $SKYCELL_ID --tess_dir $TESS_DIR --camera $CAMERA --outroot $outroot --redirect-output --run-state $RUN_STATE $MAGICKED_ARG
     320    $run = warp_skycell.pl --threads @MAX_THREADS@ --warp_id $WARP_ID --warp_skyfile_id $WARP_SKYFILE_ID --skycell_id $SKYCELL_ID --tess_dir $TESS_DIR --reduction $REDUCTION --camera $CAMERA --outroot $outroot --redirect-output --run-state $RUN_STATE $MAGICKED_ARG
    320321    add_standard_args run
    321322
  • trunk/ippTools/share/pxadmin_create_tables.sql

    r24177 r24487  
    794794    dvodb VARCHAR(255),
    795795    tess_id VARCHAR(64),
     796    reduction VARCHAR(64),
    796797    end_stage VARCHAR(64),
    797798    registered DATETIME,
  • trunk/ippTools/share/warptool_towarped.sql

    r23429 r24487  
    66    warpRun.fake_id,
    77    warpRun.state,
     8    warpRun.reduction,
    89    camRun.cam_id,
    910    rawExp.camera,
  • trunk/ippTools/src/faketool.c

    r24414 r24487  
    235235        bool status;
    236236        char *end_stage = psMetadataLookupStr(&status, md, "end_stage");
    237         if (end_stage && strcasecmp(end_stage, "warp")) continue;
     237        if (end_stage && strcasecmp(end_stage, "warp")) continue;
    238238
    239239        char *raw_tess_id   = psMetadataLookupStr(&status, md, "tess_id");
    240         if (raw_tess_id || tess_id) continue;
     240        if (raw_tess_id || tess_id) continue;
    241241
    242242        char *label  = psMetadataLookupStr(&status, md, "label");
     
    244244
    245245        if (!status) {
    246             psError(PS_ERR_UNKNOWN, false, "cannot queue analysis to WARP without a defined tess id: label: %s, exp_id %" PRId64, label, exp_id);
     246            psError(PS_ERR_UNKNOWN, false, "cannot queue analysis to WARP without a defined tess id: label: %s, exp_id %" PRId64, label, exp_id);
    247247            psFree(output);
    248248            return false;
     
    11571157        // pxwarpQueueByFakeID() can only be run after fakeRun.state has been set to stop
    11581158        if (!pxwarpQueueByFakeID(config,
    1159                     fakeRun->fake_id,
    1160                     fakeRun->workdir,
    1161                     fakeRun->label,
    1162                     fakeRun->dvodb,
    1163                     fakeRun->tess_id,
    1164                     fakeRun->end_stage
     1159                                 fakeRun->fake_id,
     1160                                 fakeRun->workdir,
     1161                                 fakeRun->label,
     1162                                 fakeRun->dvodb,
     1163                                 fakeRun->tess_id,
     1164                                 fakeRun->reduction,
     1165                                 fakeRun->end_stage
    11651166        )) {
    11661167            psError(PS_ERR_UNKNOWN, false, "failed to queue warpRun");
  • trunk/ippTools/src/pxwarp.c

    r23613 r24487  
    126126
    127127bool pxwarpQueueByFakeID(pxConfig *config,
    128                     psS64 fake_id,
    129                     char *workdir,
    130                     char *label,
    131                     char *dvodb,
    132                     char *tess_id,
    133                     char *end_stage)
     128                         psS64 fake_id,
     129                         const char *workdir,
     130                         const char *label,
     131                         const char *dvodb,
     132                         const char *tess_id,
     133                         const char *reduction,
     134                         const char *end_stage)
    134135{
    135136    PS_ASSERT_PTR_NON_NULL(config, false);
     
    146147        dvodb,
    147148        tess_id,
     149                       reduction,
    148150        end_stage,
    149151        NULL,      // registered
  • trunk/ippTools/src/pxwarp.h

    r23613 r24487  
    3131
    3232bool pxwarpQueueByFakeID(pxConfig *config,
    33                     psS64 fake_id,
    34                     char *workdir,
    35                     char *label,
    36                     char *dvodb,
    37                     char *tess_id,
    38                     char *end_stage);
     33                         psS64 fake_id,
     34                         const char *workdir,
     35                         const char *label,
     36                         const char *dvodb,
     37                         const char *tess_id,
     38                         const char *reduction,
     39                         const char *end_stage);
    3940
    4041#endif // PXWARP_H
  • trunk/ippTools/src/warptool.c

    r24426 r24487  
    139139    PXOPT_LOOKUP_STR(dvodb, config->args, "-dvodb", false, false);
    140140    PXOPT_LOOKUP_STR(tess_id, config->args, "-tess_id", true, false); // required (no default TESS)
     141    PXOPT_LOOKUP_STR(reduction, config->args, "-reduction", false, false); // required (no default TESS)
    141142    PXOPT_LOOKUP_STR(end_stage, config->args, "-end_stage", false, false);
    142143    PXOPT_LOOKUP_TIME(registered, config->args, "-registered", false, false);
     
    159160            dvodb,
    160161            tess_id,
     162            reduction,
    161163            end_stage,
    162164            registered,
     
    249251    PXOPT_LOOKUP_STR(dvodb, config->args, "-set_dvodb", false, false);
    250252    PXOPT_LOOKUP_STR(tess_id, config->args, "-set_tess_id", false, false);
     253    PXOPT_LOOKUP_STR(reduction, config->args, "-set_reduction", false, false);
    251254    PXOPT_LOOKUP_STR(end_stage, config->args, "-set_end_stage", false, false);
    252255
     
    332335        // queue the exp
    333336        if (!pxwarpQueueByFakeID(config,
    334                     row->fake_id,
    335                     workdir     ? workdir   : row->workdir,
    336                     label       ? label     : row->label,
    337                     dvodb       ? dvodb     : row->dvodb,
    338                     tess_id     ? tess_id   : row->tess_id,
    339                     end_stage   ? end_stage : row->end_stage))
     337                                 row->fake_id,
     338                                 workdir     ? workdir   : row->workdir,
     339                                 label       ? label     : row->label,
     340                                 dvodb       ? dvodb     : row->dvodb,
     341                                 tess_id     ? tess_id   : row->tess_id,
     342                                 reduction   ? reduction : row->reduction,
     343                                 end_stage   ? end_stage : row->end_stage))
    340344          {
    341345            psError(PS_ERR_UNKNOWN, false, "failed to trying to queue fake_id: %" PRId64, row->fake_id);
  • trunk/ippTools/src/warptoolConfig.c

    r24426 r24487  
    9898    psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_dvodb",          0, "define DVO db", NULL);
    9999    psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_tess_id",        0, "define tess ID", NULL);
     100    psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_reduction",      0, "define reduction class", NULL);
    100101    psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_end_stage",      0, "define end stage", NULL);
    101102    psMetadataAddBool(definebyqueryArgs, PS_LIST_TAIL, "-all",               0, "allow everything to be queued without search terms", false);
     
    111112    psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-label", 0,            "define label", NULL);
    112113    psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-dvodb", 0,            "define dvodb", NULL);
    113     psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-tess_id", 0,            "define tess_id", NULL);
     114    psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-tess_id", 0,            "define tess_id (required)", NULL);
     115    psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-reduction", 0,            "define reduction class", NULL);
    114116    psMetadataAddStr(definerunArgs, PS_LIST_TAIL, "-end_stage", 0,            "define end stage", NULL);
    115117    psMetadataAddTime(definerunArgs, PS_LIST_TAIL, "-registered",  0,            "time detrend run was registered", now);
  • trunk/ippconfig/recipes/filerules-split.mdc

    r24476 r24487  
    226226PPSTAMP.CHIP            OUTPUT {OUTPUT}.ch.fits                  IMAGE     NONE       CHIP       FALSE     MEF
    227227                                                                                                       
    228 PPSIM.OUTPUT            OUTPUT {OUTPUT}.{CHIP.NAME}.fits         IMAGE     NONE       CHIP       TRUE      NONE
     228PPSIM.OUTPUT            OUTPUT {OUTPUT}.{CHIP.NAME}.fits         IMAGE     NONE       CHIP       TRUE      SPLIT
    229229PPSIM.FAKE.CHIP         OUTPUT {OUTPUT}.{CHIP.NAME}.fake.fits    IMAGE     NONE       CHIP       TRUE      NONE
    230230PPSIM.FORCE.CHIP        OUTPUT {OUTPUT}.{CHIP.NAME}.force.fits   IMAGE     NONE       CHIP       TRUE      NONE
  • trunk/ippconfig/recipes/pswarp.config

    r20326 r24487  
    1010ACCEPT.FRAC             F32     0.1             # Minimum fraction of good pixels to accept result
    1111INTERPOLATION.NUM       S32     1000            # Number of interpolation kernels to pre-calculate
     12
     13# Default recipe for warping
     14WARP    METADATA
     15END
  • trunk/ippconfig/recipes/reductionClasses.mdc

    r24467 r24487  
    130130        CHIP_PPIMAGE    STR     CHIP
    131131        CHIP_PSPHOT     STR     CHIP
     132        WARP_PSWARP     STR     WARP
    132133        STACK_PPSTACK   STR     STACK
    133134        STACK_PPSUB     STR     STACK
     
    146147        CHIP_PPIMAGE    STR     PPIMAGE_P
    147148        CHIP_PSPHOT     STR     CHIP
     149        WARP_PSWARP     STR     WARP
    148150        STACK_PPSTACK   STR     STACK
    149151        STACK_PPSUB     STR     STACK
     
    162164        CHIP_PPIMAGE    STR     PPIMAGE_FLATCORR
    163165        CHIP_PSPHOT     STR     CHIP
     166        WARP_PSWARP     STR     WARP
    164167        STACK_PPSTACK   STR     STACK
    165168        STACK_PPSUB     STR     STACK
     
    178181        CHIP_PPIMAGE    STR     PPIMAGE_FLATTEST
    179182        CHIP_PSPHOT     STR     CHIP
     183        WARP_PSWARP     STR     WARP
    180184        STACK_PPSTACK   STR     STACK
    181185        STACK_PPSUB     STR     STACK
     
    194198        CHIP_PPIMAGE    STR     PPIMAGE_DET_ONLY
    195199        CHIP_PSPHOT     STR     CHIP
     200        WARP_PSWARP     STR     WARP
    196201        STACK_PPSTACK   STR     STACK
    197202        STACK_PPSUB     STR     STACK
     
    208213        CHIP_PPIMAGE    STR     PPIMAGE_OBDSF
    209214        CHIP_PSPHOT     STR     CHIP
     215        WARP_PSWARP     STR     WARP
    210216        STACK_PPSTACK   STR     STACK
    211217        STACK_PPSUB     STR     STACK
     
    223229        CHIP_PPIMAGE    STR     PPIMAGE_MASKPHOT
    224230        CHIP_PSPHOT     STR     CHIP
     231        WARP_PSWARP     STR     WARP
    225232        STACK_PPSTACK   STR     STACK
    226233        STACK_PPSUB     STR     STACK
     
    238245        CHIP_PPIMAGE    STR     CHIP_DENSE_STARS
    239246        CHIP_PSPHOT     STR     CHIP
    240         STACK_PPSTACK   STR     STACK
    241         STACK_PPSUB     STR     STACK
    242         STACK_PSPHOT    STR     STACK
    243         DIFF_PPSUB      STR     DIFF
    244         DIFF_PSPHOT     STR     DIFF
    245         JPEG_BIN1       STR     PPIMAGE_J1
    246         JPEG_BIN2       STR     PPIMAGE_J2
    247         FAKEPHOT        STR     FAKEPHOT
    248         ADDSTAR         STR     ADDSTAR
    249         PSASTRO         STR     DEFAULT_RECIPE
    250 END
    251 
    252 # Intended for areas with high stellar density
    253 WARPWARP        METADATA
    254         DIFF_PPSUB      STR     WARPWARP
    255         DIFF_PSPHOT     STR     DIFF
    256         JPEG_BIN1       STR     PPIMAGE_J1
    257         JPEG_BIN2       STR     PPIMAGE_J2
     247        WARP_PSWARP     STR     WARP
     248        STACK_PPSTACK   STR     STACK
     249        STACK_PPSUB     STR     STACK
     250        STACK_PSPHOT    STR     STACK
     251        DIFF_PPSUB      STR     DIFF
     252        DIFF_PSPHOT     STR     DIFF
     253        JPEG_BIN1       STR     PPIMAGE_J1
     254        JPEG_BIN2       STR     PPIMAGE_J2
     255        FAKEPHOT        STR     FAKEPHOT
    258256        ADDSTAR         STR     ADDSTAR
    259257        PSASTRO         STR     DEFAULT_RECIPE
     
    265263        CHIP_PPIMAGE    STR     CHIP
    266264        CHIP_PSPHOT     STR     PR
     265        WARP_PSWARP     STR     WARP
    267266        STACK_PPSTACK   STR     PR
    268267        STACK_PPSUB     STR     PR
Note: See TracChangeset for help on using the changeset viewer.