IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Feb 8, 2013, 11:50:49 AM (13 years ago)
Author:
bills
Message:

For warp_bg stage add column alt_cam_label. If set use the smf file
from that cam run for the astrometry. This is intended to be a
camRun with the nomal backckground subtraction.

File:
1 edited

Legend:

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

    r35127 r35134  
    3939
    4040my ($warp_bg_id, $skycell_id, $tess_dir, $reduction, $camera, $dbname, $outroot, $threads, $verbose, $no_update, $no_op, $redirect, $save_temps);
    41 my ($astrometry, $imageName, $maskName, $weightName, $magicked);
     41my ($astrometry, $imageName, $maskName, $weightName, $magicked, $exp_tag, $alternate_astrometry_label);
    4242GetOptions(
    4343    'warp_bg_id|i=s'      => \$warp_bg_id, # Warp identifier
    4444    'skycell_id|s=s'      => \$skycell_id, # Skycell identifier
    4545    'tess_dir|s=s'        => \$tess_dir, # Tesselation identifier
     46    'exp_tag|=s'          => \$exp_tag, # exposure tag
    4647    'camera|c=s'          => \$camera, # Camera name
    4748    'dbname|d=s'          => \$dbname, # Database name
     
    5152    'mask-list=s'         => \$maskName, # list of input mask files
    5253    'astrometry=s'        => \$astrometry,
     54    'alt_cam_label=s'     => \$alternate_astrometry_label,  # camRun.label for alternate astrometry
    5355    'magicked=s'          => \$magicked,
    5456    'threads=s'           => \$threads,   # Number of threads to use for pswarp
     
    8486}
    8587
     88if ($alternate_astrometry_label) {
     89    my_die( "--exp_tag is required when using alternate astrometry", $warp_bg_id, $skycell_id, $PS_EXIT_PROG_ERROR )
     90        unless defined $exp_tag;
     91}
     92
    8693my $ipprc = PS::IPP::Config->new( $camera ) or
    8794my_die( "Unable to set up", $warp_bg_id, $skycell_id, $PS_EXIT_CONFIG_ERROR ); # IPP configuration
     
    119126my $tempOutRoot = "/tmp/background.warp.$warp_bg_id.$skycell_id";
    120127
    121 # XXX: get this from recipe
    122 my $alternate_astrometry_label = 'M31.test.20130206.bgsub';
    123 # XXX: get exp_id from command line
    124 my $exp_id = 196758;
    125 
    126128if (!defined $imageName) {
    127129    # go find our inputs
    128130    my $astrom_path_base;
    129131    if (defined $alternate_astrometry_label) {
    130         my $command = "$camtool -processedexp -exp_id $exp_id -label $alternate_astrometry_label";
     132        my $command = "$camtool -processedexp -exp_tag $exp_tag -label $alternate_astrometry_label";
    131133        $command .= " -dbname $dbname" if $dbname;
    132134        my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
Note: See TracChangeset for help on using the changeset viewer.