IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 32680


Ignore:
Timestamp:
Nov 16, 2011, 3:04:31 PM (14 years ago)
Author:
bills
Message:

In the survey tasks for the background restore stages and distribution make
magic optional controlled with a parameter to the survey.add macros

Location:
trunk
Files:
5 edited

Legend:

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

    r30489 r32680  
    8888    push @stages, $stage;
    8989} else {
    90     @stages = qw( raw chip chip_bg camera fake warp warp_bg diff stack SSdiff sky);
     90    @stages = qw(chip chip_bg camera fake warp warp_bg diff stack SSdiff sky);
    9191}
    9292
  • trunk/ippTasks/survey.pro

    r32290 r32680  
    302302# user functions to manipulate dist labels
    303303macro survey.add.dist
    304   if ($0 != 3)
    305     echo "USAGE: survey.add.dist (label) (workdir)"
     304  if ($0 != 4)
     305    echo "USAGE: survey.add.dist (label) (workdir) (muggle)"
    306306    break
    307307  end
    308308  book newpage SURVEY_DIST $1
    309309  book setword SURVEY_DIST $1 WORKDIR $2
     310  book setword SURVEY_DIST $1 MUGGLE $3
    310311  book setword SURVEY_DIST $1 STATE PENDING
    311312end
     
    329330# user functions to manipulate chip_bg labels
    330331macro survey.add.chip.bg
    331   if ($0 != 3)
    332     echo "USAGE: survey.add.chip.bg (label) (dist_group)"
     332  if ($0 != 4)
     333    echo "USAGE: survey.add.chip.bg (label) (dist_group) (muggle)"
    333334    break
    334335  end
    335336  book newpage SURVEY_CHIP_BG $1
    336337  book setword SURVEY_CHIP_BG $1 DIST_GROUP $2
     338  book setword SURVEY_CHIP_BG $1 MUGGLE $3
    337339  book setword SURVEY_CHIP_BG $1 STATE PENDING
    338340end
     
    356358# user functions to manipulate warp_bg labels
    357359macro survey.add.warp.bg
    358   if ($0 != 3)
    359     echo "USAGE: survey.add.warp.bg (label) (dist_group)"
     360  if ($0 != 4)
     361    echo "USAGE: survey.add.warp.bg (label) (dist_group) (muggle)"
    360362    break
    361363  end
    362364  book newpage SURVEY_WARP_BG $1
    363365  book setword SURVEY_WARP_BG $1 DIST_GROUP $2
     366  book setword SURVEY_WARP_BG $1 MUGGLE $3
    364367  book setword SURVEY_WARP_BG $1 STATE PENDING
    365368end
     
    984987    $workdir = $workdir_base/$label/$year/$month/$day
    985988
     989    book getword SURVEY_DIST $label MUGGLE -var muggle
     990
    986991    book setword SURVEY_DIST $label STATE DONE
    987992 
    988993    # note workdir is set by the script based on site.config
    989994    $run = dist_defineruns.pl --label $label --workdir $workdir
     995    if ($muggle != 0)
     996        $run = $run --no_magic
     997    end
    990998
    991999    if ($DB:n == 0)
     
    10581066    book setword SURVEY_CHIP_BG $label STATE DONE
    10591067    book getword SURVEY_CHIP_BG $label DIST_GROUP -var dist_group
     1068    book getword SURVEY_CHIP_BG $label MUGGLE -var muggle
    10601069 
    10611070    $run = bgtool -definechip -label $label -set_dist_group $dist_group
     1071    if ($muggle == 0)
     1072        $run = $run -destreaked
     1073    end
    10621074
    10631075    if ($DB:n == 0)
     
    10681080    end
    10691081   
    1070     # echo $run
     1082    if ($VERBOSE > 1)
     1083        echo $run
     1084    end
    10711085    command $run
    10721086  end
     
    11281142    book setword SURVEY_WARP_BG $label STATE DONE
    11291143    book getword SURVEY_WARP_BG $label DIST_GROUP -var dist_group
     1144    book getword SURVEY_WARP_BG $label MUGGLE -var muggle
    11301145 
    11311146    $run = bgtool -definewarp -warp_label $label -set_dist_group $dist_group
     1147    if ($muggle == 0)
     1148        $run = $run -destreaked
     1149    end
     1150
    11321151
    11331152    if ($DB:n == 0)
     
    11381157    end
    11391158   
    1140     # echo $run
     1159    if ($VERBOSE > 1)
     1160        echo $run
     1161    end
    11411162    command $run
    11421163  end
     
    12581279    book npages SURVEY_STATICSKYSINGLE -var N
    12591280    if ($N == 0)
    1260       echo "No STATICSKYSINGLE labels for processing"
     1281       # echo "No STATICSKYSINGLE labels for processing"
    12611282       break
    12621283    endif
  • trunk/ippTools/share/bgtool_definechip.sql

    r28568 r32680  
    55LEFT JOIN chipBackgroundRun USING(chip_id)
    66WHERE chipRun.state = 'full'
    7     AND chipRun.magicked > 0 -- require destreaked to stop race condition in destreaking
  • trunk/ippTools/src/disttool.c

    r32197 r32680  
    141141    PXOPT_LOOKUP_BOOL(use_alternate, config->args, "-use_alternate", false);
    142142    PXOPT_LOOKUP_BOOL(no_magic, config->args, "-no_magic", false);
    143     PXOPT_LOOKUP_BOOL(i_am_sure, config->args, "-i_am_sure", false);
    144143    PXOPT_LOOKUP_STR(set_label, config->args, "-set_label", false, false);
    145144    PXOPT_LOOKUP_STR(set_data_group, config->args, "-set_data_group", false, false);
     
    165164    PXOPT_LOOKUP_STR(dist_group, config->args, "-dist_group", false, false);
    166165
    167     // queuing no_magic runs can be quite dangerous. Require confirmation
    168     if (no_magic && !pretend && !i_am_sure) {
    169         psError(PXTOOLS_ERR_SYS, true, "-i_am_sure required to queue no_magic distribution runs");
    170         return false;
    171     }
    172    
    173166    if (use_alternate) {
    174167        if (strcmp(stage, "raw")) {
  • trunk/ippTools/src/disttoolConfig.c

    r32197 r32680  
    4949
    5050    psMetadataAddBool(definebyqueryArgs, PS_LIST_TAIL, "-no_magic", 0, "magic is not needed", false);
    51     psMetadataAddBool(definebyqueryArgs, PS_LIST_TAIL, "-i_am_sure", 0, "confirmation needed when -no_magic is supplied", false);
    5251    psMetadataAddBool(definebyqueryArgs, PS_LIST_TAIL, "-use_alternate", 0, "use alternate inputs", false);
    5352    psMetadataAddStr(definebyqueryArgs, PS_LIST_TAIL, "-set_label",    0, "define label for run", NULL);
Note: See TracChangeset for help on using the changeset viewer.