Changeset 9180 for trunk/ippScripts/scripts/detrend_stack.pl
- Timestamp:
- Oct 3, 2006, 5:47:25 PM (20 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/detrend_stack.pl (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/detrend_stack.pl
r9145 r9180 11 11 use PS::IPP::Metadata::List qw( parse_md_list ); 12 12 use PS::IPP::Metadata::Stats; 13 14 use PS::IPP::Config; 15 my $ipprc = PS::IPP::Config->new(); # IPP configuration 16 use File::Spec; 13 17 14 18 use Getopt::Long qw( GetOptions :config auto_help auto_version gnu_getopt ); … … 73 77 } 74 78 79 my $example = ${$files}[0]->{uri}; # Example file 80 my ($vol, $dir, $file) = File::Spec->splitpath( $example ); 81 75 82 # Stack the files 76 83 my $outputRoot = $camera . '.' . $det_type . '.' . $det_id . '.' . $iter . '.' . $class_id; # Root name 84 $outputRoot = File::Spec->rel2abs( File::Spec->catpath( $vol, $dir, $outputRoot ), $ipprc->workdir() ); 77 85 my $outputStack = $outputRoot . '.fits'; # Output name 78 86 my $outputStats = $outputRoot . '.stats'; # Statistics name … … 81 89 foreach my $file (@$files) { 82 90 my $uri = $file->{uri}; # URI for input file 91 $uri = File::Spec->rel2abs( $uri, $ipprc->workdir() ); 83 92 $command .= ' ' . $uri; 84 93 } … … 93 102 die "Unable to find expected output file: $outputStats\n" if not -f $outputStats; 94 103 } 95 96 ### Could do some sort of JPEG generation here.97 104 98 105 # Get the statistics on the stacked image … … 112 119 113 120 # Add the resultant into the database 121 $outputStack = File::Spec->abs2rel( $outputStack, $ipprc->workdir() ); 114 122 unless ($no_update) { 115 123 my $command = "$dettool -addstacked -det_id $det_id -iteration $iter -class_id $class_id" .
Note:
See TracChangeset
for help on using the changeset viewer.
