Changeset 35681 for trunk/ippScripts/scripts/background_chip.pl
- Timestamp:
- Jun 18, 2013, 1:57:04 PM (13 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/background_chip.pl (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/background_chip.pl
r35154 r35681 159 159 } 160 160 161 # XXX: M31 TEST turn off restoring pattern correction162 $apply_pattern = 0;163 164 161 # Set up files 165 162 &my_die("Couldn't find input file: $in_image\n", $chip_bg_id, $class_id, $PS_EXIT_SYS_ERROR) unless $ipprc->file_exists($in_image); … … 170 167 171 168 $ipprc->outroot_prepare($outroot); 172 #my $out_image = $ipprc->filename("PPBACKGROUND.OUTPUT", $outroot, $class_id);173 #my $out_mask = $ipprc->filename("PPBACKGROUND.OUTPUT.MASK", $outroot, $class_id);174 #my $out_stats = $ipprc->filename("PPBACKGROUND.STATS", $outroot, $class_id);175 #my $out_config = $ipprc->filename("PPBACKGROUND.CONFIG", $outroot, $class_id);176 #my $traceDest = $ipprc->filename("TRACE.IMFILE", $outroot, $class_id);177 169 178 170 my $out_image = prepare_output("PPBACKGROUND.OUTPUT", $outroot, $class_id, 1); … … 183 175 my $traceDest = prepare_output("TRACE.IMFILE", $outroot, $class_id, 1); 184 176 185 my $auxmask; 186 187 my $apply_auxiliary_mask = 1; 188 # XXX Temporary lookup of auxiliary mask file from static location. 189 # At some point I'll convert this to register the masks in the database and use detselect 190 if ($apply_auxiliary_mask) { 191 my @auxmask_start_date = qw( 192 0000 193 5178 194 5218 195 5403 196 5424 197 5455 198 5485 199 5512 200 5545 201 5770 202 5797 203 5825 204 5854 205 5881 206 6138 207 6153 208 6197 209 6214 210 ); 211 my @auxmask_end_date = qw( 212 5177 213 5217 214 5402 215 5423 216 5454 217 5484 218 5511 219 5544 220 5769 221 5796 222 5824 223 5853 224 5880 225 6137 226 6152 227 6196 228 6213 229 9999 230 ); 231 232 my $outroot_base = basename($outroot); 233 234 # Assume that outroot base begins with exp_name: fix by passing in exp_name 235 my $mjd = substr($outroot_base, 1, 4); 236 if ($mjd =~ /\D/) { 237 my $error_code = 1; 238 &my_die("unexpected outroot base: $outroot_base: $error_code", $chip_bg_id, $class_id, $error_code); 239 } 240 241 my $i = 0; 242 while ($auxmask_end_date[$i] < $mjd) { 243 $i++; 244 } 245 246 my $auxmask_base = "/data/ipp064.0/bills/m31-masks/www.usm.uni-muenchen.de/people/arri/PAndromeda/masks_fits/mask"; 247 248 $auxmask = sprintf "%s_%04d-%04d_%s.fits", $auxmask_base, $auxmask_start_date[$i], $auxmask_end_date[$i], $class_id; 249 print "Auxililary mask file is $auxmask\n"; 250 } 251 252 253 254 # Run ppImage 177 178 # Run ppBackground 255 179 unless ($no_op) { 256 180 my $command = "$ppBackground $outroot"; … … 258 182 $command .= " -mask $in_mask"; 259 183 $command .= " -variance $in_wt"; 260 $command .= " -auxmask $auxmask" if $auxmask;261 184 $command .= " -stats $out_stats" if $do_stats; 262 185 $command .= " -background $in_bg" if $apply_bg;
Note:
See TracChangeset
for help on using the changeset viewer.
