IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 29155


Ignore:
Timestamp:
Sep 13, 2010, 2:51:50 PM (16 years ago)
Author:
bills
Message:

fix bugs in lookup byexp diff

Location:
tags/ipp-20100823/PS-IPP-PStamp
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • tags/ipp-20100823/PS-IPP-PStamp

  • tags/ipp-20100823/PS-IPP-PStamp/lib/PS/IPP/PStamp/Job.pm

    r29055 r29155  
    287287            $choose_components = 1;
    288288        }
     289        $command .= " -template" if $inverse;
    289290        $id_opt = $use_imfile_id ? "-diff_skyfile_id" : "-diff_id";
    290291        $image_name  = "PPSUB.OUTPUT";
     
    361362        # The image selectors are such that multiple runs my have be returned for the same exposure.
    362363        # Return only the latest one.
    363         $images = filterRuns($stage, $need_magic, $images, $verbose);
     364        $images = filterRuns($stage, $need_magic, $images, $inverse, $verbose);
    364365    }
    365366    if ($choose_components) {
     
    479480    my $listrun = 0;
    480481    if ($byid) {
    481         if ($skycell_id) {
     482        if ($skycell_id and ($skycell_id ne 'all')) {
    482483            $command .= " -diffskyfile -diff_id $id -skycell_id $skycell_id";
    483484        } else {
     
    12351236    my $need_magic = shift;
    12361237    my $inputs     = shift;
     1238    my $inverse     = shift;
    12371239    my $verbose    = shift;
    12381240
     
    12541256    my $printed = 0;
    12551257    foreach my $input (@$inputs) {
    1256         my $exp_id = $input->{exp_id};
     1258        my $exp_id;
     1259        if ($stage ne "diff") {
     1260            $exp_id = $input->{exp_id};
     1261        } elsif (!$inverse) {
     1262            $exp_id = $input->{exp_id_1};
     1263            $input->{exp_id} = $exp_id;
     1264        } else {
     1265            $exp_id = $input->{exp_id_2};
     1266            $input->{exp_id} = $exp_id;
     1267        }
    12571268        my $run_id = $input->{$id_name};
    12581269        my $magicked = $input->{magicked};  # this will be either stageRun.magicked or stage%file.magicked
     
    12601271
    12611272        # can't process run in these states
     1273        # XXX: also goto_purged or goto_scrubbed or drop
    12621274        if (($state eq 'new') or ($state eq 'purged') or ($state eq 'scrubbed')) {
    12631275            print "skipping ${stage}Run $run_id for exp_id $exp_id in state $state\n";
Note: See TracChangeset for help on using the changeset viewer.