IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Aug 9, 2016, 12:40:45 PM (10 years ago)
Author:
eugene
Message:

modify astrometry chip fitting and grid search weights based on distance from nominal photometry values

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/czw_branch/20160809/psModules/src/astrom/pmAstrometryObjects.c

    r36834 r39653  
    252252        y->data.F32[i] = refStar->FP->y;
    253253
    254         wt->data.F32[i] = 1.0;
     254        wt->data.F32[i] = 1.01 - exp(-10.0*PS_SQR(refStar->magCal - rawStar->magCal)); // sigma = 0.22 mag
    255255    }
    256256
     
    657657    obj->Color= 0;
    658658    obj->dMag = 0;
     659    obj->magCal = 0;
    659660
    660661    return (obj);
     
    685686    obj->Color =  old->Color;
    686687    obj->dMag  =  old->dMag;
     688    obj->magCal =  old->magCal;
    687689
    688690    return(obj);
     
    816818            }
    817819
     820            int Npts = 10 * exp(-10.0*PS_SQR(ob1->magCal - ob2->magCal));  // sigma = 0.22 mag
     821
    818822            // accumulate bin stats
    819             NP[iY][iX] ++;
    820             DX[iY][iX] += dX;
    821             DY[iY][iX] += dY;
    822             D2[iY][iX] += PS_SQR(dX) + PS_SQR(dY);
     823            NP[iY][iX] += Npts;
     824            DX[iY][iX] += dX*Npts;
     825            DY[iY][iX] += dY*Npts;
     826            D2[iY][iX] += PS_SQR(dX*Npts) + PS_SQR(dY*Npts);
    823827        }
    824828    }
     
    10791083                continue;
    10801084
    1081             xHist->data.F32[xBin] += 1.0;
    1082             yHist->data.F32[yBin] += 1.0;
     1085            int Npts = 10 * exp(-10.0*PS_SQR(ob1->magCal - ob2->magCal));  // sigma = 0.22 mag
     1086
     1087            xHist->data.F32[xBin] += Npts;
     1088            yHist->data.F32[yBin] += Npts;
    10831089        }
    10841090    }
Note: See TracChangeset for help on using the changeset viewer.