IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 19, 2008, 1:53:16 PM (18 years ago)
Author:
eugene
Message:

do not overwrite results in header from earlier stages

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psastro/src/psastroMosaicAstrom.c

    r19518 r20269  
    6363
    6464    // save WCS and analysis metadata in update header.
    65     psMetadata *updates = psMetadataAlloc();
     65    // (pull or create local view to entry on readout->analysis)
     66    psMetadata *updates = psMetadataLookupMetadata (&status, fpa->analysis, "PSASTRO.HEADER");
     67    if (!updates) {
     68        updates = psMetadataAlloc ();
     69        psMetadataAddMetadata (fpa->analysis, PS_LIST_TAIL, "PSASTRO.HEADER",  PS_META_REPLACE, "psastro header stats", updates);
     70        psFree (updates);
     71    }
    6672    if (!pmAstromWriteBilevelMosaic (updates, fpa, NONLIN_TOL)) {
    6773        psAbort ("failed to save header terms");
     
    7076    // write the elapsed time here; this will be updated in psastroMosaicAstrometry, if called
    7177    psMetadataAddF32 (updates, PS_LIST_TAIL, "DT_ASTR", PS_META_REPLACE, "elapsed psastro time", psTimerMark ("psastroAnalysis"));
    72 
    73     psMetadataAddMetadata (fpa->analysis, PS_LIST_TAIL, "PSASTRO.HEADER",  PS_META_REPLACE, "psastro header stats", updates);
    74     psFree (updates);
    7578
    7679    // update the headers based on the results
Note: See TracChangeset for help on using the changeset viewer.