PSFEx native sampling leaves a g1 residual on sub-0.5″ exposures; PSF consumers assume PSF_SAMP = 1
Les mainteneurs répondent en général sous 1 jour
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Accessibilité débutants
- 25/100
Piste de recherche
Start with psfex_interp.py and the PSFExInterpolator.interpsfex entry point; inspect how it reads PSF_SAMP and find its existing tests. The proposed guard should reject sampling values other than 1, with a test that covers the rejection. Later sampling support and the bounded galaxy shear pilot require separate validation; completion criteria for those are not specified in the issue.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Claude Opus on behalf of Cail; investigation by GPT-6.1 Sol.
On the best-seeing exposures, PSFEx at native sampling (PSF_SAMPLING 1) leaves a coherent g1 residual. Our PSF consumers assume unit sampling, so the obvious config fix would silently break them.
The residual shows up at exposure level once the mean PSF FWHM is below ≈0.5″ (≈2.7 px). 286 of the 15,523 v2 validation exposures (1.8%) are that sharp; 2,504 (16%) are below 0.6″. Above ≈0.5″ the median residual is flat at zero, so a blanket seeing cut isn't warranted.

For one exposure, 2780860 (18BD97, 2 Sept 2022, 0.50″), against a same-region control at 0.70″:
- Production gives Δg1 = −4.0×10⁻³; the control gives −0.2×10⁻³. The rerun reproduces production's PSFEx basis exactly.
- PSFEx at 0.5-px sampling (101×101 model) gives −1.3×10⁻³ with centered validation stamps. Rendered at each validation star's sub-pixel phase, it gives −0.02 to +0.26×10⁻³, depending on the Lanczos kernel: consistent with zero.
- Phase-matching the native model alone brings it to −1.0 to −2.7×10⁻³ (kernel-dependent). On the control, all four conventions agree, so pixel phase matters only once the stars are undersampled.

Why PSF_SAMPLING 0 (auto) is not the fix: with SAMPLE_AUTOSELECT N, PSFEx assumes a nominal 6-px FWHM and picks 1.28 px per model pixel, which is coarser. And any sampling other than 1 breaks the consumers:
PSFExInterpolator.interpsfex(psfex_interp.py) returns the rawPSF_MASKgrid and ignoresPSF_SAMP.- PSF validation attaches the CCD's native WCS to that grid. On a 0.5-sampled model it measures ΔT/T = −0.75: twice the linear size, four times the area.
- The
galaxy_psfstore carries the array without sampling metadata, and ngmix'smake_ngmix_observationbuilds the PSF Jacobian from the image WCS.
Proposed:
- A guard, now:
psfex_interpraises ifPSF_SAMP ≠ 1, with a test. It protects every consumer until sampling is supported. - For run 2:
psfex_interpemits native-pixel effective-PSF stamps with an explicit centering convention. Then validate sampling 0.5 / size 101 as the candidate configuration. - For run 1: flag the sub-0.5″ exposures for diagnostics. Measure the galaxy shear bias on a bounded pilot (a few nights, paired ngmix fits) before any rerun. The galaxy-level effect is unmeasured; the star residual does not set it.
Possibly related: #956, a ~0.4% PSF size residual on P3 tiles, measured with phase-shifted models. Not the same measurement.
Report, data and reproduction: Nibi /scratch/cdaley/psf-undersampling/REPORT.md.
- Langage dominant
- Python
- Étoiles
- 18
- Forks
- 14
- Merge moyen
- 3 j 18 h
- PR mergées (30 j)
- 27
Préparer son environnement
- Fournit un Dockerfile ou un fichier Docker Compose
- Propose un modèle de pull request
- Lire le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de CosmoStat/shapepipe
-
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 85/100
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
Les mainteneurs répondent en général sous 1 jour
-
PSF star selection: apply the manual mask; M33 shows outlier rejection fails where contaminants dominatePeut-être pris @cailmdaley l’a pris il y a 1 jour. Ouverte
Difficulté 4/5 3-5 jours Accessibilité débutants 45/100
CosmoStat/shapepipe#993 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Run 2: publish the survey as order-5 HATS pixels, uploaded once per pixel, replacing latest/ and snapshotsPeut-être pris Une pull request liée à cette issue est ouverte ou déjà fusionnée. Ouverte
Difficulté 5/5 Plus d'une semaine Accessibilité débutants 25/100
Les mainteneurs répondent en général sous 1 jour
Toutes les issues de CosmoStat/shapepipe
Issues similaires
-
Release notes from PR titlesOuverte
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
-
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
Les mainteneurs répondent en général sous 1 jour
-
[DATA] BDC portfolio DataFrame converts filed zero fair value and principal to missing valuesOuvertebug
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
dgunning/edgartools#1853 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 80/100
Imbad0202/academic-research-skills#1039 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 1/5 Moins d'une heure Accessibilité débutants 82/100
openmainframeproject/feilong#980 ·
Les mainteneurs répondent en général sous 5 jours