Changeset 34771 for trunk/ippScripts/scripts/chip_imfile.pl
- Timestamp:
- Dec 6, 2012, 2:11:32 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/chip_imfile.pl (modified) (6 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/chip_imfile.pl
r33052 r34771 150 150 $outputStats = prepare_output("PPIMAGE.STATS", $outroot, $class_id, 1); 151 151 my $do_binned_images = 1; 152 152 153 if ($run_state eq 'new') { 153 154 # prepare the files that are only created for a new run … … 586 587 587 588 # check whether psphot outputs should be regenerated. 588 # Whether we need to or not is a somewhat complicated question. 589 # Whether we need to or not was a somewhat complicated question. Since we clean cmfs now we only rerun 590 # photometry if the psf file has gone missing since it is needed to run warps 591 589 592 sub rerun_photometry 590 593 { … … 594 597 or &my_die("Missing entry from camera config: PSPHOT.OUTPUT", $exp_id, $chip_id, $class_id, $PS_EXIT_CONFIG_ERROR); 595 598 599 my $update_sources_if_gone = 0; # set this to regenerate sources if gone. 600 # We no longer do this as of 2012-12 596 601 my $make_sources = 0; 597 602 my $sources_available = 0; … … 599 604 $sources_available = 1; 600 605 } else { 601 carp "WARNING: photometry sources file $outputSources is not available"; 602 my $gone; 603 if (storage_object_exists($outputSources, \$gone)) { 604 # check whether the file is permanantely or temporarily gone 605 if ($gone) { 606 carp "WARNING: photometry sources storage object exists but all instances are permanently gone"; 606 if ($update_sources_if_gone) { 607 carp "WARNING: photometry sources file $outputSources is not available"; 608 my $gone; 609 if (storage_object_exists($outputSources, \$gone)) { 610 # check whether the file is permanantely or temporarily gone 611 if ($gone) { 612 carp "WARNING: photometry sources storage object exists but all instances are permanently gone"; 613 $make_sources = 1; 614 } 615 } else { 616 # storage object must have been deleted 607 617 $make_sources = 1; 608 618 } 609 } else {610 # storage object must have been deleted611 $make_sources = 1;612 619 } 613 620 } … … 616 623 my $psf_available = 0; 617 624 my $outputPsf = $ipprc->filename("PSPHOT.PSF.SAVE", $outroot, $class_id) 618 or &my_die("Missing entry from camera config: PSPHOT.PSF.SAVE", $exp_id, $chip_id, $class_id, $PS_EXIT_CONFIG_ERROR); 625 or &my_die("Missing entry from camera config: PSPHOT.PSF.SAVE", 626 $exp_id, $chip_id, $class_id, $PS_EXIT_CONFIG_ERROR); 627 619 628 if ($ipprc->file_exists($outputPsf)) { 620 629 $psf_available = 1; … … 638 647 } 639 648 640 # if either of the files are gone rerun photometry unless the other file is temporarily not available 641 642 if (!$sources_available && !$make_sources) { 643 # destreak will die if the sources is not available 644 &my_die("PSPHOT.SOURCES is missing but we cannot regenerate it", $exp_id, $chip_id, $class_id, $PS_EXIT_SYS_ERROR); 645 } 649 if ($update_sources_if_gone) { 650 if (!$sources_available && !$make_sources) { 651 # destreak will die if the sources is not available 652 # but magic is dead.... 653 &my_die("PSPHOT.SOURCES is missing but we cannot regenerate it", $exp_id, $chip_id, $class_id, $PS_EXIT_SYS_ERROR); 654 } 655 } 656 646 657 if (!$psf_available && !$make_psf) { 647 658 # warp updates need the psf file
Note:
See TracChangeset
for help on using the changeset viewer.
