IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 7326


Ignore:
Timestamp:
Jun 2, 2006, 6:04:10 PM (20 years ago)
Author:
eugene
Message:

changed pmPSF_MaskApTrend functions for new API

File:
1 edited

Legend:

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

    r6918 r7326  
    9898    if (!strcasecmp (ApTrendOption, "CONSTANT")) {
    9999        stats->clipIter = 2;
    100         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    101         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    102 
    103         stats->clipIter = 3;
    104         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
     100        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     101        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     102
     103        stats->clipIter = 3;
     104        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
    105105        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    106106    }
     
    110110        // first clip out objects which are too far from the median
    111111        stats->clipIter = 2;
    112         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    113         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    114 
    115         // apply the fit
    116         stats->clipIter = 3;
    117         pmPSF_MaskApTrend (psf, PM_PSF_SKYBIAS);
     112        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     113        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     114
     115        // apply the fit
     116        stats->clipIter = 3;
     117        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYBIAS);
    118118        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    119119    }
     
    122122        // first clip out objects which are too far from the median
    123123        stats->clipIter = 2;
    124         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    125         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    126 
    127         // apply the fit
    128         stats->clipIter = 2;
    129         pmPSF_MaskApTrend (psf, PM_PSF_SKYBIAS);
    130         psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    131 
    132         // apply the fit
    133         stats->clipIter = 3;
    134         pmPSF_MaskApTrend (psf, PM_PSF_SKYSAT);
     124        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     125        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     126
     127        // apply the fit
     128        stats->clipIter = 2;
     129        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYBIAS);
     130        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     131
     132        // apply the fit
     133        stats->clipIter = 3;
     134        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYSAT);
    135135        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    136136    }
     
    140140        // first clip out objects which are too far from the median
    141141        stats->clipIter = 2;
    142         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    143         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    144 
    145         // apply the fit
    146         stats->clipIter = 3;
    147         pmPSF_MaskApTrend (psf, PM_PSF_XY_LIN);
     142        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     143        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     144
     145        // apply the fit
     146        stats->clipIter = 3;
     147        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_XY_LIN);
    148148        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    149149    }
     
    153153        // first clip out objects which are too far from the median
    154154        stats->clipIter = 2;
    155         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    156         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    157 
    158         // apply the fit
    159         stats->clipIter = 3;
    160         pmPSF_MaskApTrend (psf, PM_PSF_XY_QUAD);
     155        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     156        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     157
     158        // apply the fit
     159        stats->clipIter = 3;
     160        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_XY_QUAD);
    161161        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    162162    }
     
    166166        // first clip out objects which are too far from the median
    167167        stats->clipIter = 2;
    168         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    169         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    170 
    171         // apply the fit
    172         stats->clipIter = 3;
    173         pmPSF_MaskApTrend (psf, PM_PSF_SKY_XY_LIN);
     168        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     169        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     170
     171        // apply the fit
     172        stats->clipIter = 3;
     173        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKY_XY_LIN);
    174174        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    175175    }
     
    179179        // first clip out objects which are too far from the median
    180180        stats->clipIter = 2;
    181         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
    182         psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    183 
    184         // apply the fit
    185         stats->clipIter = 3;
    186         pmPSF_MaskApTrend (psf, PM_PSF_SKYBIAS);
    187         psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    188 
    189         // apply the fit
    190         stats->clipIter = 3;
    191         pmPSF_MaskApTrend (psf, PM_PSF_SKYSAT_XY_LIN);
     181        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
     182        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     183
     184        // apply the fit
     185        stats->clipIter = 3;
     186        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYBIAS);
     187        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
     188
     189        // apply the fit
     190        stats->clipIter = 3;
     191        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYSAT_XY_LIN);
    192192        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    193193    }
     
    196196        // first clip out objects which are too far from the median
    197197        stats->clipIter = 2;
    198         pmPSF_MaskApTrend (psf, PM_PSF_CONSTANT);
     198        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_CONSTANT);
    199199        psf->ApTrend  = psVectorClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    200200
    201201        // fit just SkyBias and clip out objects which are too far from the median
    202202        stats->clipIter = 2;
    203         pmPSF_MaskApTrend (psf, PM_PSF_SKYBIAS);
     203        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_SKYBIAS);
    204204        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    205205
    206206        // finally, fit x, y, SkyBias and clip out objects which are too far from the median
    207207        stats->clipIter = 3;
    208         pmPSF_MaskApTrend (psf, PM_PSF_ALL);
     208        pmPSF_MaskApTrend (psf->ApTrend, PM_PSF_ALL);
    209209        psf->ApTrend  = psVectorChiClipFitPolynomial4D (psf->ApTrend, stats, mask, PSFTRY_MASK_ALL, apResid, dMag, xPos, yPos, r2rflux, flux);
    210210    }
Note: See TracChangeset for help on using the changeset viewer.