Start with the three files and the original observing night
The observations are from 10 December 2013, programme GS-ENG-GPI-COM. The fixed author-repository commit is 72a7517b1a34bdc29c33211f2ef591ddff64dcf9, contributed on 9 August 2016. Its three files end in S0092, S0099 and S0111, each followed by _spdc_distorcorr.fits. The files were reduced in 2016, so the observing date, later processing date and paper date describe different events.
Each original file is 14,673,600 bytes. The downloader requests exact original headers and ten selected SCI and DQ planes through anonymous HTTP ranges. It checks status 206, Content-Range, length and SHA256 for every piece. Whole-file Git blob identifiers are preserved, but a whole-file SHA256 is not claimed from partial downloads.
The ten original zero-based channel indices are 0, 4, 8, 12, 16, 20, 24, 28, 32 and 36. All three inputs remain actual observed backgrounds. Synthetic PSF injections are added only later, in explicitly separate calibration experiments.
| File number | UTSTART–UTEND on 2013-12-10 | AVPARANG / degrees |
|---|---|---|
| S0092 | 05:38:15.843–05:39:48.718 | 14.9632 |
| S0099 | 05:51:16.703–05:52:48.843 | 22.3861 |
| S0111 | 06:14:45.796–06:16:19.187 | 34.6878 |
Reading: Bonnefoy et al. · Jason Wang and contributors · GPI Data Pipeline 1.4.0 data formats
Read units and quality flags before the image
SCI has thirty-seven native wavelength planes with 281 pixels on each spatial axis. BUNIT says ADU per coadd. ITIME is 88.74219 seconds per coadd and COADDS is one. The start and end windows include overhead, so their midpoint is not automatically a charge-weighted exposure midpoint. Projection uses the CD matrix; measured AVPARANG values check the field-rotation span.
Wavelength starts at 1.11407300105 micrometres, with a native step of 0.00654594640474 micrometres and a one-based reference pixel of one. The selected channels run to 1.34972707162 micrometres. Native sampling is finer than the published resolving power of about 35–39; ten retained channels are not ten independent resolution elements.
The DQ extension carries bit flags. The default mask excludes the bad-pixel and two saturation bits. Up-the-ramp outlier-removal bits and repaired/interpolated pixels are retained unless the basic bad bit is also set. The companion validation tries the stricter policy of masking every nonzero flag and reports when a measurement loses enough valid pixels to fail.
There is no ERR extension giving a calibrated variance cube. Reprocessed ADU values should not be treated as independent Poisson electrons. The tutorial estimates a conditional spatial/spectral covariance from processed comparison patches and keeps the resulting underfit visible.
Reading: GPI Data Pipeline 1.4.0 data formats · Bonnefoy et al.
Check the compass and remeasure the satellite spots
Use the two-by-two CD matrix for small sky offsets. Its column norm corresponds to 14.14 milliarcseconds per native pixel. The older CDELT values conflict with it, and the PAR_ANG comment explicitly says to use AVPARANG. FITS CRPIX is one-based; the source reader treats PSFCENT and SATS spot locations as native zero-based coordinates.
S0099 and S0111 repeat exactly the SATS location strings and PSFCENT values. Preserve those original cards. The script independently fits the actual spot pixels with a local Gaussian plus a tilted background plane. A free iterative centroid can drift into a nearby speckle; the adopted fit searches only one pixel around the header location, rejects boundary solutions and is checked with independent empirical-PSF injections.
The independent registration test adds empirical spot shapes at known positions on other actual halo patches. Of 144 injections, 114 local fits pass and thirty fail; the accepted 95th-percentile position bias is about 0.825 pixel. Those failures and template differences limit any precision interpretation of the real spot registration.
Average the remeasured satellite positions to register each native image. Then project through the original CD matrix onto a north-up, east-left grid. The strongest middle-annulus point in the sparse reduction lies at a position angle about 212.62 degrees. The historical Table 1 value is 211.6 plus or minus 1.3 degrees. That comparison checks orientation at pixel scale. Precision astrometry for the later reduction needs its own plate-scale and north calibration.
Reading: GPI Data Pipeline 1.4.0 data formats · Jason Wang and contributors · Bonnefoy et al.
Calibrate flux with one consistent finite template
For each exposure and channel, take small measured satellite-spot stamps, subtract local background and average their centered shapes. The template is normalized with the same three-pixel circular aperture and local background convention used for the satellite flux. The normalizing number is an integrated aperture flux; SATF header peak values are not substituted for it.
Section 2 adopts a J-band satellite-to-star magnitude difference of 9.36 with a 0.15-magnitude uncertainty. The script adopts that historical ratio as a constant common calibration across the selected reduced channels; it is not a measured precision chromatic calibration. The bare off-axis throughput lookup is not applied because its provenance and uncertainty remain unresolved. The historical magnitude error gives about fourteen percent fractional scale uncertainty and correlates all spectral channels. It is kept separate from the empirical noise covariance.
This yields a reduced-channel planet/star contrast spectrum under the adopted empirical template calibration. Obtaining absolute planet flux would additionally require a stellar spectral model and its calibration. The published paper does that with adopted stellar templates; this tutorial stops at contrast.
Reading: Bonnefoy et al. · Greco & Brandt
Process, inject and read the actual result
The primary reduction uses the mean of all three registered frames as its angular reference. Each residual is projected through its own CD matrix before coaddition. The disclosed local region of interest uses the historical separation of 430 milliarcseconds and position angle of 211.6 degrees. This choice uses earlier knowledge of the companion position; it is not a blind discovery.
Inject an empirical point-source template into each original selected channel, run the entire subtraction and projection again, and measure all output channels. A second run adds SDI before ADI to expose spectral mixing. These deterministic injections calibrate processing on this frozen observed background; they do not create an independent photon realization.
Representative central-aperture results are listed below. Their error bars are conditional empirical noise estimates. The common magnitude calibration and the individual-spot template sensitivity are separate saved outputs. Source-photon variance cannot be reconstructed exactly from these reduced ADU without the omitted gain and raw-noise information.
| Native channel | Wavelength / micrometres | ADI contrast | Conditional noise standard error |
|---|---|---|---|
| 0 | 1.11407 | 0.0000272 | 0.00000731 |
| 16 | 1.21881 | 0.0000514 | 0.00000679 |
| 20 | 1.24499 | 0.0000671 | 0.00000694 |
| 32 | 1.32354 | 0.000105 | 0.00000549 |
Reading: Bonnefoy et al. · Pueyo · Greco & Brandt
Keep the spatial failure beside the spectrum
Ten aperture fluxes can fit ten channel contrasts exactly. The script therefore also uses central, radial-difference and tangential-difference measurements in every channel. Forty-seven comparison patches estimate this thirty-dimensional covariance. It profiles ten contrasts over an expanded forty-nine-point position grid and twenty-four additional local refinements, keeping the measurement region and covariance fixed.
The expanded ADI profile reaches a minimum quadratic residual of about 175 for twenty residual dimensions, at an interior grid point near 430 milliarcseconds and 213.1 degrees. The ASDI profile remains much poorer, near 389, and its local refinement still reaches an edge. The simple spatial model underfits these data. Different individual satellite templates also change the extracted colors. This is a reason to retain a conditional diagnostic spectrum and seek better PSF/background modeling before fitting atmosphere parameters.
The ASDI diagnostic also leaves a negative final-channel estimate, about minus 0.00000836. It is retained. Strong changes between processing choices and empirical templates are part of the uncertainty story, even when the combined image still shows a bright point.
The available inputs are three public files, not the paper’s complete nineteen-exposure reduction. Upstream microlens spectral cross-talk and within-exposure motion are not fully reconstructed. The published analysis supplies a historical comparison and a reading target; the saved failures describe the smaller calculation actually performed here.
Reading: Bonnefoy et al. · Samland et al. · Greco & Brandt
Run locally and retain the source attribution
Download the science-only materials below into one folder. The public package contains our scripts, the exact source-range manifest, preserved original headers and numerical results. It does not embed the GPI science or derived image pixels: a data-specific redistribution grant remains unresolved. The downloader obtains the pinned files directly from the original author’s public repository, with a named User-Agent and byte checks.
Run the commands in a clean environment. The optional local-images flag writes locally derived pixel arrays for your own inspection. Keep the source manifest next to those products and distinguish an injected calibration source from the observed companion in any figure you make.
python3.12 -m venv .venv
. .venv/bin/activate
python -m pip install numpy==2.3.5
python download-gpi-ranges.py --manifest data-source-manifest.json --output gpi-cache
python reproduce-gpi.py --manifest data-source-manifest.json --cache gpi-cache --output local-results
python reproduce-gpi.py --manifest data-source-manifest.json --cache gpi-cache --output local-results --algorithm asdi
python validate-gpi-registration.py --manifest data-source-manifest.json --cache gpi-cache --output registration-validation.json
Reading: Jason Wang and contributors · GPI Data Pipeline 1.4.0 data formats