IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 11394


Ignore:
Timestamp:
Jan 29, 2007, 1:11:35 PM (19 years ago)
Author:
Paul Price
Message:

b1_uri now contains the output root name; b2 is unused. The idea here is that we have the file names defined in the camera configuration, and this means we can now add other files without the overhead of hacking the database schema.

Location:
trunk/ippScripts/scripts
Files:
8 edited

Legend:

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

    r11360 r11394  
    104104    }
    105105    &my_die("Can't find expected output file: $output", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $output;
    106     &my_die("Can't find expected output file: $b1name", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $b2name;
    107     &my_die("Can't find expected output file: $b2name", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $b1name;
     106    &my_die("Can't find expected output file: $b1name", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $b1name;
     107    &my_die("Can't find expected output file: $b2name", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $b2name;
    108108    &my_die("Can't find expected output file: $statsName", $det_id, $iter, $class_id, $PS_EXIT_SYS_ERROR) unless -e $statsName;
    109109}
     
    129129unless ($no_update) {
    130130    my $command = "$dettool -addnormalizedimfile -det_id $det_id -iteration $iter -class_id $class_id ".
    131         "-uri $output -b1_uri $b1name -b2_uri $b2name"; # Command to run
     131        "-uri $output -b1_uri $outputRoot"; # Command to run
    132132    # Add the statistics triplet
    133133    $command .= " -bg " . $stats->bg_mean();
  • trunk/ippScripts/scripts/detrend_norm_exp.pl

    r11360 r11394  
    128128open my $list2File, '>' . $list2Name;
    129129foreach my $file (@$files) {
    130     print $list1File ($ipprc->convert_filename_absolute( $file->{b1_uri} ) . "\n");
    131     print $list2File ($ipprc->convert_filename_absolute( $file->{b2_uri} ) . "\n");
     130    my $origRoot = $ipprc->convert_filename_absolute( $file->{b1_uri} ); # Original root name
     131    print $list1File ( $ipprc->filename( "PPIMAGE.BIN1", $origRoot, $file->{class_id} ) . "\n");
     132    print $list2File ( $ipprc->filename( "PPIMAGE.BIN2", $origRoot, $file->{class_id} ) . "\n");
    132133    push @means, $file->{bg};
    133134    push @stdevs, $file->{bg_stdev};
     
    161162unless ($no_update) {
    162163    my $command = "$dettool -addnormalizedexp -det_id $det_id -iteration $iter " .
    163         "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1Name -b2_uri $jpeg2Name " .
     164        "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $outputRoot " .
    164165        "-bg $bg -bg_stdev $bg_stdev -bg_mean_stdev $bg_mean_stdev"; # Command to run
    165166    $command .= " -dbname $dbname" if defined $dbname;
  • trunk/ippScripts/scripts/detrend_process_exp.pl

    r11360 r11394  
    109109    $workdir = $ipprc->convert_filename_absolute( $workdir );
    110110} else {
    111     my $example = ${$files}[0]->{b1_uri}; # Example filename
     111    my $example = ${$files}[0]->{b1_uri}; # Example original root name
    112112    my ($vol, $dir, $file) = File::Spec->splitpath( $example );
    113113    $workdir = $dir;
     
    124124open my $list2File, '>' . $list2Name;
    125125foreach my $file (@$files) {
    126     print $list1File ($ipprc->convert_filename_absolute( $file->{b1_uri} ) . "\n");
    127     print $list2File ($ipprc->convert_filename_absolute( $file->{b2_uri} ) . "\n");
     126    my $origRoot = $ipprc->convert_filename_absolute( $file->{b1_uri} ); # Original root name
     127    print $list1File ($ipprc->filename( "PPIMAGE.BIN1", $origRoot, $file->{class_id} ) . "\n");
     128    print $list2File ($ipprc->filename( "PPIMAGE.BIN2", $origRoot, $file->{class_id} ) . "\n");
    128129    push @means, $file->{bg};
    129130    push @stdevs, $file->{bg_stdev};
     
    167168unless ($no_update) {
    168169    my $command = "$dettool -addprocessedexp -det_id $det_id -exp_tag $exp_tag " .
    169         "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1 -b2_uri $jpeg2 " .
     170        "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $outputRoot " .
    170171        "-bg $bg -bg_stdev $bg_stdev -bg_mean_stdev $bg_mean_stdev"; # Command to run
    171172    $command .= " -dbname $dbname" if defined $dbname;
  • trunk/ippScripts/scripts/detrend_process_imfile.pl

    r11360 r11394  
    135135unless ($no_update) {
    136136    my $command = "$dettool -addprocessedimfile -det_id $det_id -exp_tag $exp_tag " .
    137         "-class_id $class_id -recip $recipe -uri $outputImage -b1_uri $outputBin1 " .
    138         "-b2_uri $outputBin2"; # Command to run dettool
     137        "-class_id $class_id -recip $recipe -uri $outputImage -b1_uri $outputRoot";  # Command to run dettool
    139138    $command .= " -bg " . $stats->bg_mean();
    140139    if (defined($stats->bg_stdev())) {
  • trunk/ippScripts/scripts/detrend_reject_imfile.pl

    r11360 r11394  
    8989    $workdir = $ipprc->convert_filename_absolute( $workdir );
    9090} else {
    91     my $example = ${$files}[0]->{b1_uri}; # Example file
     91    my $example = ${$files}[0]->{b1_uri}; # Example original root name
    9292    my ($vol, $dir, $file) = File::Spec->splitpath( $example );
    9393    $workdir = $dir;
     
    107107open my $list2File, '>' . $list2Name;
    108108foreach my $file (@$files) {
    109     print $list1File ($ipprc->convert_filename_absolute( $file->{b1_uri} ) . "\n");
    110     print $list2File ($ipprc->convert_filename_absolute( $file->{b2_uri} ) . "\n");
     109    my $origRoot = $ipprc->convert_filename_absolute( $file->{b1_uri} ); # Original root name
     110    print $list1File ($ipprc->filename( "PPIMAGE.BIN1", $origRoot, $file->{class_id} ) . "\n");
     111    print $list2File ($ipprc->filename( "PPIMAGE.BIN2", $origRoot, $file->{class_id} ) . "\n");
    111112    push @means, $file->{bg};
    112113    push @meanStdevs, $file->{bg_mean_stdev};
     
    270271unless ($no_update) {
    271272    my $command = "$dettool -addresidexp -det_id $det_id -iteration $iter -exp_tag $exp_tag " .
    272         "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1Name -b2_uri $jpeg2Name " .
     273        "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $outputRoot " .
    273274        "-bg $mean -bg_stdev $stdev -bg_mean_stdev $meanStdev"; # Command to run
    274275    $command .= ' -reject' if $reject;
  • trunk/ippScripts/scripts/detrend_resid.pl

    r11360 r11394  
    174174unless ($no_update) {
    175175    my $command = "$dettool -addresidimfile -det_id $det_id -iteration $iter -exp_tag $exp_tag " .
    176         "-class_id $class_id -recip $recipe -uri $outputName -b1_uri $bin1Name " .
    177         "-b2_uri $bin2Name"; # Command to run dettool
     176        "-class_id $class_id -recip $recipe -uri $outputName -b1_uri $outputRoot"; # Command to run dettool
    178177    $command .= " -bg " . $stats->bg_mean();
    179178    $command .= " -dbname $dbname" if defined $dbname;
  • trunk/ippScripts/scripts/phase2.pl

    r11333 r11394  
    127127    $command .= " -recip " . RECIPE;
    128128    $command .= " -uri $outputImage";
    129     $command .= " -b1_uri $outputBin1";
    130     $command .= " -b2_uri $outputBin2";
     129    $command .= " -b1_uri $outputRoot";
    131130    $command .= " -bg " . $stats->bg_mean();
    132131    $command .= " -bg_stdev " . $stats->bg_stdev();
  • trunk/ippScripts/scripts/phase3.pl

    r11355 r11394  
    118118    $workdir = $ipprc->convert_filename_absolute( $workdir );
    119119} else {
    120     my $example = ${$files}[0]->{b1_uri}; # Example filename
     120    my $example = ${$files}[0]->{b1_uri}; # Example original root name
    121121    my ($vol, $dir, $file) = File::Spec->splitpath( $example );
    122122    $workdir = $dir;
     
    137137    # use the b1_uri as OUTPUT root and convert the filenames
    138138    # with ipprc->filename:
    139     my $classID = $file->{class_id};
    140     my $fileRoot = $file->{b1_uri};
    141     print $list1File $ipprc->filename("PPIMAGE.BIN1", $file->{b1_uri}, $classID);
    142     print $list2File $ipprc->filename("PPIMAGE.BIN2", $file->{b1_uri}, $classID);
    143     print $list1File $ipprc->filename("PSPHOT.OUTPUT", $file->{b1_uri}, $classID);
    144     print $list1File $ipprc->filename("PSASTRO.OUTPUT", $file->{b1_uri}, $classID);
     139    my $class_id = $file->{class_id};
     140    my $origRoot = $ipprc->convert_filename_absolute( $file->{b1_uri} ); # Original root name
     141    print $list1File $ipprc->filename("PPIMAGE.BIN1", $origRoot, $class_id);
     142    print $list2File $ipprc->filename("PPIMAGE.BIN2", $origRoot, $class_id);
     143    print $list1File $ipprc->filename("PSPHOT.OUTPUT", $origRoot, $class_id);
     144    print $list1File $ipprc->filename("PSASTRO.OUTPUT", $origRoot, $class_id);
    145145    # XXX PSASTRO.OUTPUT is explicitly a CHIP output file
    146146    # XXX below the PSASTRO.OUTPUT must be an FPA output file
     
    196196unless ($no_update) {
    197197    my $command = "$p3tool -addprocessedexp -exp_tag $exp_tag -uri UNKNOWN " .
    198         "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1 -b2_uri $jpeg2 " .
     198        "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $outputRoot " .
    199199        "-bg $bg -bg_stdev $bg_stdev -bg_mean_stdev $bg_mean_stdev " .
    200200        "-sigma_ra 0.0 -sigma_dec 0.0 -nastro 0 -zp_mean 0.0 -zp_stdev 0.0"; # Command to run
Note: See TracChangeset for help on using the changeset viewer.