IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 30030


Ignore:
Timestamp:
Dec 14, 2010, 9:04:16 AM (15 years ago)
Author:
eugene
Message:

update to use modified psImageMapFit APIs

Location:
branches/eam_branches/ipp-20101205/psphot/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ipp-20101205/psphot/src/psphotApResid.c

    r29936 r30030  
    378378
    379379    // XXX test for errors here
    380     if (!pmTrend2DFit (apTrend, mask, 0xff, xPos, yPos, apResid, dMagSoft)) {
     380    bool goodFit = false;
     381    if (!pmTrend2DFit (&goodFit, apTrend, mask, 0xff, xPos, yPos, apResid, dMagSoft)) {
     382        // XXX this is probably a real error, and I should exit
     383        psWarning("Failed to fit trend for %d x %d map", Nx, Ny);
     384        psFree (apTrend);
     385        return NULL;
     386    }
     387    if (!goodFit) {
    381388        psWarning("Failed to fit trend for %d x %d map", Nx, Ny);
    382389        psFree (apTrend);
  • branches/eam_branches/ipp-20101205/psphot/src/psphotMakeFluxScale.c

    r25755 r30030  
    5555    fPts->n = Npts;
    5656
    57     if (!pmTrend2DFit (trend, NULL, 0xff, xPts, yPts, fPts, NULL)) {
     57    // XXX we should allow the spatial sampling to decrease if the fit fails
     58    bool goodFit = false;
     59    if (!pmTrend2DFit (&goodFit, trend, NULL, 0xff, xPts, yPts, fPts, NULL)) {
    5860        psError(PS_ERR_UNKNOWN, false, "Unable to fit trend");
     61        success = false;
     62        goto DONE;
     63    }
     64    if (!goodFit) {
     65        psError(PS_ERR_UNKNOWN, false, "poor fit to flux-scale trend");
    5966        success = false;
    6067        goto DONE;
Note: See TracChangeset for help on using the changeset viewer.