IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 29, 2010, 3:08:03 PM (16 years ago)
Author:
watersc1
Message:
  • Update configuration to queue from OBS_MODE/OBJECT instead of Comment (except for microtest)
  • Expand microtest to queue on OBJECT to select which tesselation id to use (this is a hack, but microtest still uses comments, too)
  • Add REDUCTION config entry so that specific targets can be processed with a specific reduction class (or, a given target can be processed in multiple ways)
  • Correctly set state to DROP when there are no exposures to process
  • Migrate burntool logfiles to /data/$host.0/burntool_logs/.
File:
1 edited

Legend:

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

    r27512 r27513  
    5555
    5656# Grab options
    57 my ( $date, $camera, $dbname, $logfile, $verbose);
     57my ( $date, $camera, $dbname, $logfile, $verbose, $manual);
    5858my ( $help, $isburning, $force_stack_count, $test_mode, $this_target_only, $this_filter_only);
    5959my ( $check_registration, $define_burntool, $queue_burntool, $check_chips, $queue_chips);
     
    125125my %comment_list= ();
    126126my %stackable_list = ();
     127my %reduction_class = ();
    127128my $retention_time = 9000;
    128129
     
    168169                $stackable_list{$this_target} = ${ $tentry }{value};
    169170            }
     171            elsif (${ $tentry }{name} eq 'REDUCTION') {
     172                $reduction_class{$this_target} = ${ $tentry }{value};
     173            }
    170174        }
    171175    }
     
    307311        $Nsummit_exps++;
    308312        if ($summit_fault) {
    309             print STDERR "check_summit_copy: $date $exp_name has summit_fault $summit_fault";
     313            print STDERR "check_summit_copy: $date $exp_name has summit_fault $summit_fault";
    310314            if ($exp_type ne 'OBJECT') {
    311315                print STDERR " (but I don't care).\n";
     
    450454    my $target = shift;
    451455
    452     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($date,$target);
     456    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($date,$target);
    453457
    454458    my $select =  "-dateobs_begin ${date}T00:00:00 -dateobs_end ${date}T23:59:59 ";
     
    469473        $cmd .= " -comment '$comment' ";
    470474    }
     475    if (defined($reduction)) {
     476        $cmd .= " -set_reduction $reduction ";
     477    }
    471478    $cmd .= " $select ";
    472479    if ($debug == 1) {
     
    484491    my $db = init_gpc_db();
    485492    $date =~ s/-//g;
    486     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($date,$target);
     493    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($date,$target);
    487494
    488495    my $sth = "SELECT exp_id from chipRun where data_group = '$data_group' AND exp_id = $exp_id";
     
    543550        my ($Nexposures,$Nimfiles,$Nburntooled,$Nalready) = pre_chip_queue($date,$target);
    544551        if ($Nexposures == 0) {
    545             print STDERR "execute_chips: Target $target on $date had no exposures.\n";
     552            print STDERR "execute_chips: Target $target on $date had no exposures.\n";
     553            next;
     554        }
     555        if ($Nalready != 0) {
     556            print STDERR "execute_chips: Not queueing $target on $date due to already existing exposures.\n";
    546557            next;
    547558        }
    548         if ($Nalready != 0) {
    549             print STDERR "execute_chips: Not queueing $target on $date due to already existing exposures.\n";
    550             next;
    551         }
    552559        if ($Nimfiles != $Nburntooled) {
    553             print STDERR "execute_chips: Target $target on $date is not fully burntooled.\n";
     560            print STDERR "execute_chips: Target $target on $date is not fully burntooled.\n";
    554561            $metadata_out{nsState} = 'NEEDSBURNING';
    555562            next;
     
    574581    my $filter = shift;
    575582
    576     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($date,$target);
     583    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($date,$target);
    577584
    578585    my $select =  "-select_dateobs_begin ${date}T00:00:00 -select_dateobs_end ${date}T23:59:59 ";
     
    603610    my $db = init_gpc_db();
    604611    $date =~ s/-//g;
    605     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($date,$target);
     612    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($date,$target);
    606613
    607614    my $sth = "SELECT skycell_id from stackRun where data_group = '$data_group' AND skycell_id = '$skycell' AND filter = '$filter'";
     
    616623    my $filter = shift;
    617624
    618     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($date,$target);
     625    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($date,$target);
    619626    # check warp stage == chip stage
    620627    my $db = init_gpc_db();
     
    716723    my $cleaning_date = $dt->ymd;
    717724
    718     my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group) = get_tool_parameters($cleaning_date,$target);
     725    my ($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction) = get_tool_parameters($cleaning_date,$target);
    719726
    720727    my $args .= " -dbname gpc1 -updaterun -set_state goto_cleaned -state full -data_group $data_group ";
     
    779786    my $data_group = "${target}.${trunc_date}";
    780787    my $tess_id = $tessID_list{$target};
    781 
    782     return($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group);
     788    my $reduction = $reduction_class{$target};
     789    return($label,$workdir,$obs_mode,$object,$comment,$tess_id,$dist_group,$data_group,$reduction);
    783790}
    784791
Note: See TracChangeset for help on using the changeset viewer.