> **2026-10-04 follow-up:** [SOURCE_CONSISTENT_SIGNALS.md](SOURCE_CONSISTENT_SIGNALS.md) completes spatially consistent injections/refits. The stronger test fails at1.55152% amplitude error; controlled attribution identifies sky-ring-driven profile normalization. Earlier local-only numerical results remain historical/conditional.

# Neighbour leakage and a source-consistency gap — 2026-10-03

**Conclusion: neighbour contamination remains relevant, and the primary
signal test needs to include each source in every illuminated cutout.**
The new sensitivity run does not identify a unique physical correction.
Model assumptions strongly affect far-wing predictions. More decisively,
actual source/reference cutouts share detector pixels even though their IDs
are disjoint. Earlier primary injections did not carry that source into
other cutouts, so their amplitude pass is conditional on the narrower test.
The current candidate is unchanged; the full goal remains active/unmet.

Run: `/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/`.
Worktree: `/home/kshukawa/syndiff_pipeline/dev/.worktrees/temporal-raw-epsf/`,
branch `codex/temporal-raw-epsf`, local only. Scripts are
`temporal_raw_epsf/neighbour_response.py`, `neighbour_leakage.py`,
`neighbour_leakage_assessment.py`, and `neighbour_source_overlap.py`.
The [existing canvas](http://localhost:18888/temporal-raw-epsf/canvas/temporal_raw_epsf.html)
contains the images below and the preceding reference-expansion failure.

## Fixed experiment and checks

All 482 existing extraction targets and all 36 preselected FFIs are retained.
The descriptive cohorts are 165 eligible science stars, 235 original references,
and 47 provisional new references. Other sources remain in the stored arrays.
Catalogue neighbours within 20 pixels and relative catalogue flux above 0.001
are separated into 0–13 and 13–20 pixel annuli. Target IDs are strings and are
excluded explicitly. There are 24,556 target/neighbour links and 23,455 unique
neighbours; one link uses the explicitly flagged missing-colour fallback of 1.0.

The catalogue is the existing S24 C2K2 pipeline Gaia catalogue. Its checksum
and exact WCS reference FFI are in `results/neighbour_leakage_full/config.json`.
It retains the original catalogue/epoch convention; no proper-motion update
or new absolute astrometric accuracy is claimed. Neighbours use the inherited
target-fold population template/state and target-relative static position
anchor. Consequently this is not yet a single globally consistent scene.

Three PSF families are tested: the signed empirical population model, its
positive-clipped sensitivity, and an independent asymmetric Gaussian mixture.
The analytic model has exact pixel integrals and analytic x/y/cross/dilation
derivatives. Its baseline agrees with a separate implementation, derivatives
agree with finite differences, and shifted-cutout fluxes agree on common
pixels. Both targeted unit tests pass. Analytic shape is independent of the
spline, but the temporal state coefficients remain inherited.

Population neighbours have one fixed normalization on their OWN centred
first-epoch 15×15 stamp. A truncated target cutout is never normalized to one.
The analytic mixture is normalized over the whole plane. A single static
catalogue-to-electron scale gives a shared neighbour the same flux and the same
deterministic injected phase/period wherever it appears. No target time trend
fits these amplitudes.

All target positions replay exactly, original neighbour-core exclusions replay,
and a real-pixel injection agrees with its aperture projection within
2.48e-11 electrons/second. Every 16-target pilot output replays bitwise in
the full run. Condor 2424.0, schedd plscience3 and execute plscience2, completed
normally with exit 0 using eight requested CPUs. The source loop took 225 s.
Reported memory was sampled too sparsely to establish peak memory.

The initial pilot failed because workers inherited a shared compressed-file
seek position. The corrected pilot loads arrays before forking; no input file
was corrupt or changed. The failed directory remains. Presentation was also
corrected to use recorded orbit membership, rather than the largest sparse
sample gap, for line breaks; numerical summaries were asserted unchanged.

## What was measured in the sensitivity calculation

For constant neighbours the modeled aperture contribution is

$$b_{s,t}=\sum_{n\in\mathcal N_s} f_n
\frac{\sum_p w_{s,t,p}P_{n,t,p}}{r_{s,t}}.$$

Here $s$ indexes a target, $t$ an exposure, $n$ a catalogue neighbour in set
$\mathcal N_s$, and $p$ a target-stamp pixel. The fixed catalogue estimate
$f_n$ is a neighbour's electron/second flux; $P_{n,t,p}$ is its dimensionless
normalized profile on the target grid; $w_{s,t,p}$ is the existing dimensionless
retained-aperture/response-aware-sky weight; $r_{s,t}$ is the existing modeled
partial/complete aperture response ratio; and $b_{s,t}$ is in electrons/second.
The weights include the actual target's response changes even in the static
neighbour control. Full motion/shape, motion only, shape only and static
illumination are therefore all evaluated; differences from static isolate
the change in neighbour illumination.

The variable-neighbour sensitivity replaces $f_n$ by $f_n a_n(t)$, where
$a_n(t)$ is a dimensionless 0.2-amplitude sine with a source-ID-determined
phase and one of 5/10/20/30-day periods. This is an injection, **not measured
20% variability in the catalogue population**.

![Neighbour sensitivity by brightness and source role](/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/results/neighbour_leakage_full/assessment/response_by_magnitude.png)
![Actual predicted histories for catalogue-first examples in each readout](/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/results/neighbour_leakage_full/assessment/individual_predictions.png)
![Actual input images and underlying modeled pixel changes on shared scales](/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/results/neighbour_leakage_full/assessment/actual_and_predicted_pixels.png)

For the original 235 references:

| Profile family | Constant-neighbour temporal RMS, median/p95 ppm | Variable-neighbour injection RMS, median/p95 ppm | Outer-annulus RMS, median/p95 ppm |
|---|---:|---:|---:|
| Signed population | 41.87 / 910.69 | 461.03 / 4350.44 | 12.16 / 410.96 |
| Positive population | 35.13 / 461.12 | 352.77 / 3138.03 | 9.96 / 162.08 |
| Independent analytic | 21.60 / 157.54 | 258.24 / 1194.85 | 0.13 / 3.84 |

All denominators are each target's recorded median aperture rate. These are
model sensitivities, not confidence intervals, observed contamination, or
noise floors. The far-wing disagreement is a reason to measure those wings
directly; the analytic model is not an independently calibrated truth model.
The population profile's sky gauge and positivity choices must not be
mistaken for a validated physical halo.

## Effect through the current reference correction

With reference weights held fixed, remove only the changing modeled neighbour
light, not a catalogue-derived DC blend:

$$\delta\ell_{j,t}=-\sum_s W_{s,j}
\log\!\left[1-\frac{b_{s,t}-\overline b_s}{A_{s,t}}\right].$$

Here $j$ indexes a science star, $W_{s,j}$ is its existing dimensionless
reference weight, $\overline b_s$ is the temporal mean modeled neighbour
rate, $A_{s,t}$ is the current physically restored reference aperture rate
in electrons/second, and $\delta\ell_{j,t}$ is the dimensionless change in
the science log flux. It is centred once over both orbits. For the variable
injection the bracket instead adds the injected neighbour contribution.
This freezes reference precision/ratio fits and is only a sensitivity.

![Conditional transport into science curves](/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/results/neighbour_leakage_full/assessment/reference_transport.png)

Across the 165 eligible science stars using the original references, constant
neighbour changes produce median/p95 RMS 19.65/35.37, 14.27/24.67, and
4.93/12.83 ppm for signed, positive and analytic families respectively.
The corresponding variable-neighbour injections give 130.76/464.65,
55.16/141.67 and 49.29/86.82 ppm. None is an adopted correction or an
end-to-end validation result. Below-threshold/beyond-20-pixel light, extended
backgrounds, neighbour shot noise and joint onboard count loss are not modeled.

## Actual overlapping pixels expose an injection gap

Rank donors using catalogue geometry, mean profile response and the existing
mean science-reference weights, before examining donor time histories. All
three families identify the same largest donor:
Gaia **1622915828734016128** (science index 50, cube index 1956). Its neighbour
Gaia **1622824775427569408** (cube index 1933) is an active reference.

![Actual donor/reference pixels and measured histories](/astro/armin/koji/syndiff/dev_runs/temporal_raw_epsf_20261001/results/neighbour_leakage_full/source_overlap/observed_overlap.png)

The stamp rectangles share 66 physical detector pixels, 61 retained in the
reference mask. Their raw arrays are identical on the intersection for all
1,224 exposures. The donor is already excluded from the quiet science cohort;
its measured current 5th/95th percentile variation is −16.93/+14.97 ppt and
RMS 11.15 ppt. This does not prove an astrophysical origin or the wing amplitude.
The reference remains in the calibration. Dropping the donor from a science
summary did not remove its light from neighbouring reference measurements.

The catalogue sensitivity identifies 16 science-to-original-reference links
(16 distinct donors and references), plus four science-to-science links.
This is only the tested 20-pixel/flux-cut inventory, not complete PSF support.

Code inspection of `response_profile_relearn.py` shows the earlier primary
injection modifies only the current science cutout; reference-only rows
return before primary injection. `response_profile_calibration.py` recomputes
the injected science ratios but uses unchanged reference aperture counts.
The earlier signal-amplitude pass is therefore conditional on these local
injections. It does not certify a spatially consistent source injection.
This strengthens the stated validation limit; no earlier numerical result
is silently replaced.

## Next required test

1. Assign each injected science source one absolute detector trajectory,
   profile and time-dependent normalization. Project it into every science
   and reference cutout it illuminates, preserving identical additions on
   shared detector pixels. Use direct bounds on omitted analytic tails,
   rather than claiming the catalogue's 20-pixel cut is complete support.
2. Relearn the affected science profiles, recompute both science aperture
   ratios and reference counts, and refit ratio transport/reference precision.
   Include all original science sources and the same amplitude criterion.
   Existing unaffected fits may be reused only after exact overlap tests.
3. Evaluate the real donor/reference pair with the measured pixel information
   and held-out time blocks. Do not fit away a trend simply because it agrees
   with a chosen PSF wing, or assume a 20% injection is measured variability.
4. Improve/retest neighbour treatment and outer-profile constraints on the full
   population. Preserve instrument calibration, WCS and physical covariance
   work; neither a successful injection nor lower RMS alone proves Poisson limits.

Exact frozen commands and exits are in `condor/neighbour_leakage_pilot`,
`neighbour_leakage_pilot_checked`, `neighbour_leakage_full`,
`neighbour_leakage_assessment`, `neighbour_leakage_figures_checked`, and
`neighbour_source_overlap`. All are terminal; the first is the preserved
failed attempt and the remainder succeeded. No PSF was trained or scene
refitted in this milestone, so the shared training-residual gallery is unchanged.

**Conclusion:** the neighbour hypothesis is not ruled out; its amplitude is
model-dependent. Actual pixel overlap proves a missing coupling in the current
primary-injection validation. The next correction must be judged with signals
inserted consistently across all affected cutouts. No photon-limited or
systematic-free claim is justified, and no new science product is promoted.
