IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 37709


Ignore:
Timestamp:
Dec 2, 2014, 3:27:44 PM (11 years ago)
Author:
heather
Message:

changes to addtool to do addstar diffs

Location:
trunk
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippScripts/scripts/addstar_run.pl

    r37551 r37709  
    9494# Recipes to use based on reduction class
    9595$reduction = 'DEFAULT' unless defined $reduction;
    96 if ($stage =~/diff/) {
    97     $reduction = 'ADDSTAR';
    98 }
     96#if ($stage =~/diff/) {
     97#    $reduction = 'ADDSTAR';
     98#}
    9999if ($stage =~/forcedwarp/) {
    100100    $reduction = 'ADDSTAR';
  • trunk/ippTools/share/addtool_find_diff_id_dvo.sql

    r37551 r37709  
    44JOIN diffSkyfile using (diff_id, skycell_id)
    55JOIN diffRun using (diff_id)
    6 
    7 
    8 diffRun JOIN diffSkyfile using (diff_id)
    96
    107WHERE diffRun.state = 'full' and diffSkyfile.quality = 0
  • trunk/ippTools/share/addtool_find_pendingexp_diff.sql

    r37551 r37709  
    22    addRun.*,
    33    diffSkyfile.path_base as stageroot,
    4     "NULL",
    5     "NULL"
     4    'GPC1' as camera,
     5    'PS1' as telescope
    66FROM addRun
    77JOIN diffInputSkyfile
  • trunk/ippTools/share/addtool_find_pendingexp_ff.sql

    r37551 r37709  
    11   SELECT
    22    addRun.*,
    3     fullForceResult.path_base as stageroot,
    4     "NULL",
    5     "NULL"
     3    fullForceResult.path_base as stageroot
    64FROM addRun
    75JOIN fullForceResult
  • trunk/ippTools/share/addtool_queue_diff_id.sql

    r37551 r37709  
    44        'diff',         -- stage
    55        diff_id,        -- stage_id
    6         diff_skyfile_id, -- stage_extra1
     6        %d, -- stage_extra1
    77        '%s',           -- state
    88        '%s',           -- workdir
     
    1717        '%s',           -- minidvodb_group
    1818        '%s'            -- minidvodb_name
    19     FROM diffInputSkyfile
    20     JOIN diffSkyfile using (diff_id, skycell_id)
    21     JOIN diffRun using (diff_id)
     19    FROM diffRun
    2220    WHERE
    23         diffRun.state = 'full' AND
     21        diffRun.state = 'full'
    2422        AND diffRun.diff_id = %lld
     23       
  • trunk/ippTools/share/addtool_queue_ff_id.sql

    r37551 r37709  
    44        'fullforce',            -- stage
    55        ff_id,         -- stage_id
    6         warp_id,        -- stage_extra1
     6        %d,            -- stage_extra1
    77        '%s',           -- state
    88        '%s',           -- workdir
     
    1717        '%s',           -- minidvodb_group
    1818        '%s'            -- minidvodb_name
    19     FROM fullForceResult
    20     JOIN fullForceRun using (ff_id)
     19    FROM fullForceRun
    2120    WHERE
    2221        fullForceRun.state = 'full'
  • trunk/ippTools/src/addtool.c

    r37551 r37709  
    373373      //needs to be checked HAF xxx
    374374      if (strcmp(stage,"diff") == 0) {
    375         psStringAppend(&query, " GROUP BY diff_id ");  //this needs checking, but I think it shoul be fine? it groups by lots of stuff (including stack - we only want one of each stack in there
     375        psStringAppend(&query, " GROUP BY diff_id, diff_skyfile_id ");  //this needs checking, but I think it shoul be fine? it groups by lots of stuff (including stack - we only want one of each stack in there
    376376      }
    377377      //needs to be checked HAF xxx
    378378      if (strcmp(stage,"fullforce") == 0) {
    379         psStringAppend(&query, " GROUP BY ff_id, skycal_id ");  //this needs checking, but I think it shoul be fine? it groups by lots of stuff (including stack - we only want one of each stack in there
     379        psStringAppend(&query, " GROUP BY ff_id, warp_id ");  //this needs checking, but I think it shoul be fine? it groups by lots of stuff (including stack - we only want one of each stack in there
    380380      }
    381381
     
    535535
    536536    if (strcmp(stage,"diff") == 0) {
     537     
    537538      for (long i = 0; i < psArrayLength(output); i++) {
    538539        psMetadata *md = output->data[i];
    539540
    540541        diffRunRow *row = diffRunObjectFromMetadata(md);
    541 
     542       
    542543        if (!row) {
    543           psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into skycalRun");
     544          psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into diffRun");
    544545          psFree(output);
    545546          return false;
     
    568569
    569570        if (!row) {
    570           psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into skycalRun");
     571          psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into fullforceRun");
    571572          psFree(output);
    572573          return false;
     
    784785   
    785786    if (strcmp(stage,"diff") == 0) {
     787     
    786788    for (long i = 0; i < psArrayLength(output); i++) {
    787789        psMetadata *md = output->data[i];
    788790        psS64 stage_id =0;
    789        
    790                   diffRunRow *row = diffRunObjectFromMetadata(md);
    791           stage_id = row->diff_id;
     791        //      psS64 stage_extra1 = 0;
     792        diffRunRow *row = diffRunObjectFromMetadata(md);
     793        stage_id = row->diff_id;
     794        bool status = false;
     795        psS32 stage_extra1 = psMetadataLookupS32(&status, md, "diff_skyfile_id");
     796        if (!status) {
     797          psError(PS_ERR_UNKNOWN, true, "failed to lookup value for item diff_skyfile_id");
     798          return false;
     799        }
     800
    792801       
    793802        if (!row) {
     
    796805            return false;
    797806        }
    798 
     807       
    799808        // queue the exp
    800809        if (!pxaddQueueByCamID(config,
    801810                               stage,
    802811                               stage_id,
    803                                0,
     812                               stage_extra1,
    804813                               workdir     ? workdir   : row->workdir,
    805814                               reduction   ? reduction : row->reduction,
     
    831840        psS64 stage_id =0;
    832841       
    833                   fullForceRunRow *row = fullForceRunObjectFromMetadata(md);
    834           stage_id = row->ff_id;
    835        
     842        fullForceRunRow *row = fullForceRunObjectFromMetadata(md);
     843        stage_id = row->ff_id;
     844        bool status = false;
     845        psS32 stage_extra1 = psMetadataLookupS32(&status, md, "warp_id");
     846        if (!status) {
     847          psError(PS_ERR_UNKNOWN, true, "failed to lookup value for item warp_id");
     848          return false;
     849        }
     850
    836851        if (!row) {
    837852            psError(PS_ERR_UNKNOWN, false, "failed to convert metadata into skycalRun");
     
    844859                               stage,
    845860                               stage_id,
    846                                0,
     861                               stage_extra1,
    847862                               workdir     ? workdir   : row->workdir,
    848863                               reduction   ? reduction : row->reduction,
  • trunk/tools/heather/queuesliceslap2.pl

    r37461 r37709  
    1616
    1717@slices = ("00","02","04","06","08","10","12","14","16","18","20","22");
    18 @slices = ("00","02","04");
     18#@slices = ("00","02","04");
    1919
    2020foreach $label (@labels) {
Note: See TracChangeset for help on using the changeset viewer.