IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 26, 2025, 5:05:19 PM (13 months ago)
Author:
eugene
Message:

working on new burntool / rawfix / archive paradigm

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/tools/eam/burntool.20250520/src/burntool_night_chip.pl

    r42878 r42908  
    2222my $date = `date`;
    2323print "\n\n";
    24 print "Starting script $0 on $host at $date\n\n";
     24# print "Starting script $0 on $host at $date\n\n";
     25print "data MULTI\n\n";
    2526
    2627my ( $class_id, $dateobs, $dbname, $rerun, $verbose, $save_temps);
     
    5354my $missing_tools;
    5455my $regtool      = can_run('regtool')         or (warn "Can't find regtool"         and $missing_tools = 1);
    55 my $funpack      = can_run('funpack')         or (warn "Can't find funpack"         and $missing_tools = 1);
    56 my $ppConfigDump = can_run('ppConfigDump')    or (warn "Can't find ppConfigDump"    and $missing_tools = 1);
    5756if ($missing_tools) {
    5857    warn("Can't find required tools.");
     
    7271$command .= " -ordered_by_date";
    7372$command .= " -dbname $dbname" if defined $dbname;
     73$command .= " -limit 10";
    7474
    7575my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
     
    111111foreach my $file (@$files) {
    112112    my $exp_id     = $file->{exp_id};
    113     my $exp_name   = $file->{exp_id};
     113    my $exp_name   = $file->{exp_name};
    114114    my $state      = $file->{burntool_state};
    115115    my $data_state = $file->{data_state};
     
    126126        next;
    127127    }
     128
     129    # extract the storage host name
     130    my ($datahost) = $rawImfileReal =~ m|/data/(ipp[a-z0-9]+).[0123]|;
     131    # print STDERR "datahost: $datahost\n";
     132    # next;
    128133
    129134    # instantiate the burntable instance for use by the actual analysis script
     
    137142
    138143    my $process = 1;
    139     my $previousTableStyle = 0;
    140144
    141145    if ($state == -2) { &my_die("Aborting as $rawImfile has modified pixel data!"); }
    142     if ($state == +1 * $burntoolStateGood) {
    143         $process = 0;
    144         $previousTableStyle = 1;
    145     }
     146    if ($state == +1 * $burntoolStateGood) { &my_die("Unexpected burntool State $state"); }
     147
     148    # $state = -15, $burntoolStateGood = +15
    146149    if ($state == -1 * $burntoolStateGood) {
    147150        $process = 0;
    148         $previousTableStyle = -1;
    149151    }
    150152    if ($rerun) { $process = 1; }
     
    156158
    157159    if (($process == 1) || ($processNext == 1)) {
    158         my $status;
     160        # we now have $rawImfileReal, $previousTable, $outTableReal
     161        print STDOUT "data METADATA\n";
     162        print STDOUT "     rawImfileReal STR $rawImfileReal\n";
     163        print STDOUT "     outTableReal  STR $outTableReal\n";
     164        print STDOUT "     exposure      STR $exp_name\n";
     165        print STDOUT "     class_id      STR $class_id\n";
     166        print STDOUT "     fullname      STR $exp_name.$class_id\n";
     167        print STDOUT "     datahost      STR $datahost\n";
     168        if ($previousTable ne "") {
     169            print STDOUT "     previousTable STR $previousTable\n";
     170        }
     171        print STDOUT "END\n\n";
     172
    159173        $processNext = 1;
    160 
    161         # we now have $rawImfileReal, $previousTable, $outTableReal
    162         print STDERR "$rawImfileReal $previousTable $outTableReal\n";
    163 
    164         $previousTableStyle = -1;
    165174    }
    166175
    167176    ### XXX I think I can make the assumption that we are saving the tables as separate files since we
    168177    ### want to get to burntool state -15 (v15)
    169     $previousTable = "in=$outTableReal";
     178    $previousTable = "$outTableReal";
    170179}
    171180
Note: See TracChangeset for help on using the changeset viewer.