IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jul 15, 2008, 10:33:17 AM (18 years ago)
Author:
eugene
Message:

implement redirect-output everywhere; cleanup logfile names; rename detrend_resid.pl to detrend_resid_imfile.pl; rename detrend_reject_imfile.pl to detrend_resid_exp.pl

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippScripts/scripts/fake_imfile.pl

    r18020 r18562  
    4242# Parse the command-line arguments
    4343my ( $exp_id, $fake_id, $class_id, $chiproot, $camroot, $camera, $outroot,
    44      $dbname, $reduction, $verbose, $no_update, $no_op );
     44     $dbname, $reduction, $verbose, $no_update, $no_op, $redirect );
    4545GetOptions(
    46            'exp_id=s'      => \$exp_id,    # Exposure identifier
    47            'fake_id=s'     => \$fake_id,   # Chiptool identifier
    48            'class_id=s'    => \$class_id,  # Class identifier
    49            'chiproot=s'    => \$chiproot,  # Input Chip files (root)
    50            'camroot=s'     => \$camroot,   # Input Camera files (root)
    51            'camera|c=s'    => \$camera,    # Camera
    52            'outroot|w=s'   => \$outroot,   # output file base name
    53            'dbname|d=s'    => \$dbname,    # Database name
    54            'reduction=s'   => \$reduction, # Reduction class
    55            'verbose'       => \$verbose,   # Print to stdout
    56            'no-update'     => \$no_update, # Don't update the database?
    57            'no-op'         => \$no_op,     # Don't do any operations?
    58            ) or pod2usage( 2 );
     46    'exp_id=s'          => \$exp_id,    # Exposure identifier
     47    'fake_id=s'         => \$fake_id,   # Chiptool identifier
     48    'class_id=s'        => \$class_id,  # Class identifier
     49    'chiproot=s'        => \$chiproot,  # Input Chip files (root)
     50    'camroot=s'         => \$camroot,   # Input Camera files (root)
     51    'camera|c=s'        => \$camera,       # Camera
     52    'outroot|w=s'       => \$outroot,   # output file base name
     53    'dbname|d=s'        => \$dbname,    # Database name
     54    'reduction=s'       => \$reduction, # Reduction class
     55    'verbose'           => \$verbose,   # Print to stdout
     56    'no-update'         => \$no_update, # Don't update the database?
     57    'no-op'             => \$no_op,        # Don't do any operations?
     58    'redirect-output'   => \$redirect,
     59    ) or pod2usage( 2 );
    5960
    6061pod2usage( -msg => "Unknown option: @ARGV", -exitval => 2 ) if @ARGV;
     
    7172$ipprc->define_camera($camera);
    7273
     74my $logDest = $ipprc->filename("LOG.IMFILE", $outroot, $class_id)  or &my_die("Missing entry from camera config", $exp_id, $fake_id, $class_id, $PS_EXIT_CONFIG_ERROR);
     75
     76$ipprc->redirect_output($logDest) if $redirect;
     77
    7378# Recipes to use based on reduction class
    7479$reduction = 'DEFAULT' unless defined $reduction;
     
    116121my $cameraObjects = $ipprc->filename("PSASTRO.OUTPUT",      $camroot)             or &my_die("Missing entry from camera config", $exp_id, $fake_id, $class_id, $PS_EXIT_CONFIG_ERROR);
    117122my $traceDest     = $ipprc->filename("TRACE.IMFILE",        $outroot, $class_id)  or &my_die("Missing entry from camera config", $exp_id, $fake_id, $class_id, $PS_EXIT_CONFIG_ERROR);
    118 my $logDest       = $ipprc->filename("LOG.IMFILE",          $outroot, $class_id)  or &my_die("Missing entry from camera config", $exp_id, $fake_id, $class_id, $PS_EXIT_CONFIG_ERROR);
    119123
    120124# XXX check for existence of input data
Note: See TracChangeset for help on using the changeset viewer.