Changeset 9892 for trunk/ippScripts/scripts/detrend_process_exp.pl
- Timestamp:
- Nov 7, 2006, 10:38:05 AM (20 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/detrend_process_exp.pl (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/detrend_process_exp.pl
r9524 r9892 19 19 use Pod::Usage qw( pod2usage ); 20 20 21 my ($det_id, $exp_tag, $ no_update);21 my ($det_id, $exp_tag, $camera, $no_update); 22 22 GetOptions( 23 23 'det_id|d=s' => \$det_id, 24 24 'exp_tag|e=s' => \$exp_tag, 25 'camera|c=s' => \$camera, 25 26 'no-update' => \$no_update 26 27 ) or pod2usage( 2 ); … … 28 29 pod2usage( -msg => "Unknown option: @ARGV", -exitval => 2 ) if @ARGV; 29 30 pod2usage( 30 -msg => "Required options: --det_id --exp_tag ",31 -msg => "Required options: --det_id --exp_tag --camera", 31 32 -exitval => 3, 32 33 ) unless defined $det_id 33 and defined $exp_tag; 34 and defined $exp_tag, 35 and defined $camera; 36 37 $ipprc->define_camera($camera); 34 38 35 39 use constant RECIPE1 => 'PPIMAGE_J1'; # Recipe to use for ppImage to make JPEGs … … 105 109 close $list2File; 106 110 107 # Output products --- need to synch with the camera configuration!108 my $jpeg1 Name = $outputRoot . ".b1.jpg"; # Binned JPEG #1109 my $jpeg2 Name = $outputRoot . ".b2.jpg"; # Binned JPEG #2111 # Output products 112 my $jpeg1 = $ipprc->filename("PPIMAGE.JPEG1", $outputRoot); # Binned JPEG #1 113 my $jpeg2 = $ipprc->filename("PPIMAGE.JPEG2", $outputRoot); # Binned JPEG #2 110 114 111 115 # Make the jpeg for binning 1 … … 114 118 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = 115 119 run(command => $command, verbose => 1); 116 die "Unable to find expected output file: $jpeg1 Name\n" if not -f $jpeg1Name;120 die "Unable to find expected output file: $jpeg1\n" if not -f $jpeg1; 117 121 } 118 122 … … 122 126 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = 123 127 run(command => $command, verbose => 1); 124 die "Unable to find expected output file: $jpeg2 Name\n" if not -f $jpeg2Name;128 die "Unable to find expected output file: $jpeg2\n" if not -f $jpeg2; 125 129 } 126 130 … … 128 132 # Add the result into the database 129 133 $outputRoot = File::Spec->abs2rel( $outputRoot, $ipprc->workdir() ); 130 $jpeg1 Name = File::Spec->abs2rel( $jpeg1Name, $ipprc->workdir() );131 $jpeg2 Name = File::Spec->abs2rel( $jpeg2Name, $ipprc->workdir() );134 $jpeg1 = File::Spec->abs2rel( $jpeg1, $ipprc->workdir() ); 135 $jpeg2 = File::Spec->abs2rel( $jpeg2, $ipprc->workdir() ); 132 136 unless ($no_update) { 133 137 my $command = "$dettool -addprocessedexp -det_id $det_id -exp_tag $exp_tag " . 134 "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1 Name -b2_uri $jpeg2Name" .138 "-recip " . RECIPE1() . "," . RECIPE2() . " -b1_uri $jpeg1 -b2_uri $jpeg2 " . 135 139 "-bg $bg -bg_stdev $bg_stdev -bg_mean_stdev $bg_mean_stdev"; # Command to run 136 140 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
Note:
See TracChangeset
for help on using the changeset viewer.
