IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Jun 8, 2008, 4:03:31 PM (18 years ago)
Author:
eugene
Message:

update from changes on eam_branch_20080511 : adding photometry of fake sources, force photometry; major cleanups

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ppSim/src/ppSimMakeDark.c

    r17557 r18011  
    1111    psMetadata *recipe = psMetadataLookupMetadata(&mdok, config->recipes, PPSIM_RECIPE); // Recipe
    1212
    13     float darkRate = psMetadataLookupF32(NULL, recipe, "DARK.RATE"); // Dark rate
    14     float expTime  = psMetadataLookupF32(NULL, recipe, "EXPTIME"); // Exposure time
     13    bool dark = psMetadataLookupBool(&mdok, recipe, "DARK"); // Generate a DARK?
     14    if (!dark) return true;
     15
     16    float darkRate = psMetadataLookupF32(&mdok, recipe, "DARK.RATE"); // Dark rate
     17    if (isnan(darkRate)) {
     18      psError(PS_ERR_UNKNOWN, false, "missing DARK.RATE\n");
     19      return false;
     20    }
     21
     22    float expTime  = psMetadataLookupF32(&mdok, recipe, "EXPTIME"); // Exposure time
     23    if (isnan(expTime)) {
     24      psError(PS_ERR_UNKNOWN, false, "missing EXPTIME\n");
     25      return false;
     26    }
     27
     28    psTrace("ppSim", 6, "darkRate: %f, expTime: %f\n", darkRate, expTime);
    1529
    1630    for (int y = 0; y < signal->numRows; y++) {
Note: See TracChangeset for help on using the changeset viewer.