IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 29027


Ignore:
Timestamp:
Aug 23, 2010, 4:14:50 PM (16 years ago)
Author:
eugene
Message:

if modelFlux is missing, cache it (psphotExtendedSourceFits); remove test image dump

Location:
trunk/psphot/src
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/psphot/src/psphotExtendedSourceAnalysis.c

    r29004 r29027  
    121121        if (source->peak->y > AnalysisRegion.y1) continue;
    122122
     123        // fprintf (stderr, "xsrc: %f, %f : %f\n", source->peak->xf, source->peak->yf, source->peak->SN);
     124
    123125        // replace object in image
    124126        if (source->tmpFlags & PM_SOURCE_TMPF_SUBTRACTED) {
     
    178180    }
    179181
     182    // fprintf (stderr, "xsrc : tried %ld objects\n", sources->n);
     183
    180184    return true;
    181185}
  • trunk/psphot/src/psphotExtendedSourceFits.c

    r29015 r29027  
    200200            }
    201201            psFree(job);
    202             }
     202        }
    203203    }
    204204    psFree (cellGroups);
     
    270270        // set the radius based on the footprint (also sets the mask pixels)
    271271        if (!psphotSetRadiusFootprint(&radius, readout, source, markVal, 1.0)) {
     272            fprintf (stderr, "skipping (1) %f, %f\n", source->peak->xf, source->peak->yf);
    272273            psFree (fitOptions)
    273274            return false;
     
    280281        // XXX save the psf-based moments for output
    281282        if (!pmSourceMoments (source, radius, 0.0, 0.0, maskVal)) {
     283            fprintf (stderr, "skipping (2) %f, %f\n", source->peak->xf, source->peak->yf);
    282284            // subtract the best fit from the object, leave local sky
    283285            pmSourceSub (source, PM_MODEL_OP_FULL, maskVal);
     
    289291        psImage *modelFluxStart = psMemIncrRefCounter (source->modelFlux);
    290292        if (!modelFluxStart) {
    291           // XXX raise an error of some kind?
    292           continue;
     293            pmSourceCacheModel (source, maskVal);
     294            modelFluxStart = psMemIncrRefCounter (source->modelFlux);
     295            if (!modelFluxStart) {
     296                fprintf (stderr, "skipping (3) %f, %f\n", source->peak->xf, source->peak->yf);
     297                // XXX raise an error of some kind?
     298                continue;
     299            }
    293300        }
    294 
     301       
    295302        if (savePics) {
    296303          psphotSaveImage (NULL, readout->image, "image.xp.fits");
     
    317324          float SNlim = psMetadataLookupF32 (&status, model, "SNLIM_VALUE");
    318325          assert (status);
     326
     327          // fprintf (stderr, "xfit: %f, %f : %f\n", source->peak->xf, source->peak->yf, source->peak->SN);
    319328
    320329          // limit selection to some SN limit
     
    449458    psFree (fitOptions);
    450459
     460    // fprintf (stderr, "xfit : tried %ld objects\n", sources->n);
     461
    451462    // change the value of a scalar on the array (wrap this and put it in psArray.h)
    452463    scalar = job->args->data[7];
  • trunk/psphot/src/psphotStackMatchPSFsUtils.c

    r28013 r29027  
    346346    if (!fake) goto escape;
    347347
    348     dumpImage(fake, readoutSrc, index, "fake");
    349     dumpImage(readoutSrc,  readoutSrc, index, "real");
     348    // dumpImage(fake, readoutSrc, index, "fake");
     349    // dumpImage(readoutSrc,  readoutSrc, index, "real");
    350350
    351351    if (threads) pmSubtractionThreadsInit();
     
    380380    }
    381381
    382     dumpImage(readoutOut, readoutSrc, index, "conv");
    383     dumpImageDiff(readoutOut, fake, readoutSrc, index, "diff");
     382    // dumpImage(readoutOut, readoutSrc, index, "conv");
     383    // dumpImageDiff(readoutOut, fake, readoutSrc, index, "diff");
    384384
    385385    psFree(fake);
Note: See TracChangeset for help on using the changeset viewer.