IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 25074


Ignore:
Timestamp:
Aug 14, 2009, 12:39:56 PM (17 years ago)
Author:
Paul Price
Message:

For MOPS, write exposure name as FPA_ID, exposure identifier as EXP_ID.

Location:
trunk
Files:
5 edited

Legend:

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

    r25072 r25074  
    8282my %zp;                         # Zero points
    8383my %exp_id;                     # Exposure identifiers
     84my %exp_name;                   # Exposure names
    8485{
    8586    my $command;                # Command to run
     
    118119            $zp{"$skycell_id.pos"} = $zp;
    119120            $zp{"$skycell_id.neg"} = $zp if defined $comp->{bothways} and $comp->{bothways};
    120             $exp_id{"$skycell_id.pos"} = $comp->{exp1};
    121             $exp_id{"$skycell_id.neg"} = $comp->{exp2} if defined $comp->{bothways} and $comp->{bothways};
     121            $exp_id{"$skycell_id.pos"} = $comp->{exp_id_1};
     122            $exp_id{"$skycell_id.neg"} = $comp->{exp_id_2} if defined $comp->{bothways} and $comp->{bothways};
     123            $exp_name{"$skycell_id.pos"} = $comp->{exp_name_1};
     124            $exp_name{"$skycell_id.neg"} = $comp->{exp_name_2} if defined $comp->{bothways} and $comp->{bothways};
    122125        } elsif ($stage eq 'camera') {
    123126            my $cam_id = $comp->{cam_id};
     
    125128            $zp{$cam_id} = $zp;
    126129            $exp_id{$cam_id} = $comp->{exp_id};
     130            $exp_name{$cam_id} = $comp->{exp_name};
    127131        }
    128132    }
     
    140144    my $zp = $zp{$comp};
    141145    my $exp_id = $exp_id{$comp};
     146    my $exp_name = $exp_name{$comp};
    142147    if ($product eq "IPP-MOPS") {
    143148        my $outuri = "$outroot.$comp.fits";
     
    145150            &my_die( "Unable to resolve output file $outuri", $pub_id, $PS_EXIT_SYS_ERROR);
    146151
    147         my $command = "$ppMops $file $zp $exp_id $out";
     152        my $command = "$ppMops $file $zp $exp_id $exp_name $out";
    148153        my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
    149154            run(command => $command, verbose => $verbose);
  • trunk/ippTools/src/difftool.c

    r25071 r25074  
    11791179
    11801180        if (!available && (num != skycell_count)) {
    1181             psTrace("difftool", PS_LOG_INFO, "%" PRId64 " skyfiles with stack found for warp_id %"
    1182                 PRId64 " need %" PRId64, num, skycell_count, warp_id);
     1181            psTrace("difftool", PS_LOG_INFO, "%" PRId64 " skyfiles with stack found for warp_id %" PRId64
     1182                    " need %" PRId64, num, warp_id, skycell_count);
    11831183            continue;
    11841184        }
  • trunk/ppMops/src/ppMops.c

    r25072 r25074  
    66int main(int argc, char *argv[])
    77{
    8     if (argc != 5) {
     8    if (argc != 6) {
    99        fprintf(stderr, "Insufficient arguments.\n");
    1010        fprintf(stderr, "Usage: %s DETECTIONS ZP EXP_ID OUTPUT\n", argv[0]);
     
    1616    data->zp = atof(argv[2]);
    1717    data->exp_id = atoll(argv[3]);
    18     data->output = psStringCopy(argv[4]);
     18    data->exp_name = psStringCopy(argv[4]);
     19    data->output = psStringCopy(argv[5]);
    1920
    2021    if (!isfinite(data->zp)) {
     
    137138        psMetadataAddF64(outHeader, PS_LIST_TAIL, "TEL_ALT", 0, "Telescope altitude", alt);
    138139        psMetadataAddF64(outHeader, PS_LIST_TAIL, "TEL_AZ", 0, "Telescope azimuth", az);
    139         psMetadataAddS32(outHeader, PS_LIST_TAIL, "DIFFIMID", 0, "Difference image identifier", imageid);
    140         psMetadataAddS32(outHeader, PS_LIST_TAIL, "FPA_ID", 0, "Exposure identifier", data->exp_id);
     140        psMetadataAddS64(outHeader, PS_LIST_TAIL, "DIFFIMID", 0, "Difference image identifier", imageid);
     141        psMetadataAddStr(outHeader, PS_LIST_TAIL, "FPA_ID", 0, "Exposure name", data->exp_name);
     142        psMetadataAddS64(outHeader, PS_LIST_TAIL, "EXP_ID", 0, "Exposure identifier", data->exp_id);
    141143        psMetadataAddStr(outHeader, PS_LIST_TAIL, "OBSCODE", 0, "IAU Observatory code", OBSERVATORY_CODE);
    142144        psMetadataAddF32(outHeader, PS_LIST_TAIL, "STARPSF", 0, "Stellar PSF (arcsec)", psf);
  • trunk/ppMops/src/ppMops.h

    r25072 r25074  
    1717    float zp;                           // Magnitude zero point
    1818    psS64 exp_id;                       // Exposure identifier
     19    psString exp_name;                  // Exposure name
    1920    psString output;                    // Output filename
    2021} ppMopsData;
  • trunk/ppMops/src/ppMopsData.c

    r24242 r25074  
    1111{
    1212    psFree(data->detections);
     13    psFree(data->exp_name);
    1314    psFree(data->output);
    1415    return;
     
    2223    data->detections = NULL;
    2324    data->zp = NAN;
     25    data->exp_id = 0;
     26    data->exp_name = NULL;
    2427    data->output = NULL;
    2528
Note: See TracChangeset for help on using the changeset viewer.