Changeset 33052
- Timestamp:
- Jan 9, 2012, 1:43:55 PM (14 years ago)
- File:
-
- 1 edited
-
trunk/ippScripts/scripts/chip_imfile.pl (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippScripts/scripts/chip_imfile.pl
r32562 r33052 147 147 my $outputBin2; 148 148 my $dump_config = 1; 149 my $do_stats = 1; 150 $outputStats = prepare_output("PPIMAGE.STATS", $outroot, $class_id, 1); 149 151 my $do_binned_images = 1; 150 152 if ($run_state eq 'new') { 151 153 # prepare the files that are only created for a new run 152 154 $configuration = prepare_output("PPIMAGE.CONFIG", $outroot, $class_id, 1); 153 $outputStats = prepare_output("PPIMAGE.STATS", $outroot, $class_id, 1);154 155 } else { 155 156 $configuration = $ipprc->filename('PPIMAGE.CONFIG', $outroot, $class_id) … … 196 197 unless ($no_op) { 197 198 my $command; 198 my $do_stats;199 199 200 200 ## get the ppImage recipe for this camera and CHIP reduction … … 470 470 $command .= " -Db PPIMAGE:PHOTOM FALSE"; 471 471 } 472 if ($run_state eq "new" ) {472 if ($run_state eq "new" or $do_stats) { 473 473 $command .= " -recipe PPSTATS CHIPSTATS"; 474 474 $command .= " -stats $outputStats"; … … 562 562 563 563 # Add the processed file to the database 564 unless ($no_update) { 565 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = 566 run(command => $command, verbose => $verbose); 567 unless ($success) { 568 $error_code = (($error_code >> 8) or $PS_EXIT_PROG_ERROR); 569 warn("Unable to perform chiptool -addprocessedimfile: $error_code\n"); 570 exit($error_code); 571 } 572 } else { 573 print "skipping command: $command\n"; 564 my $tries = 0; 565 while (1) { 566 $tries++; 567 unless ($no_update) { 568 my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) = 569 run(command => $command, verbose => $verbose); 570 unless ($success) { 571 $error_code = (($error_code >> 8) or $PS_EXIT_PROG_ERROR); 572 warn("Unable to perform chiptool -addprocessedimfile: $error_code\n"); 573 exit($error_code) if $tries >= 3; 574 warn("Waiting 10 seconds to try again\n"); 575 sleep 10; 576 } else { 577 last; 578 } 579 } else { 580 print "skipping command: $command\n"; 581 last; 582 } 574 583 } 575 584
Note:
See TracChangeset
for help on using the changeset viewer.
