NASA - National Aeronautics and Space Administration Follow this link to skip to the main content + Contact NASA
Kepler Guest Observer Program

PyKE Primer - 3. Target Pixel Files (TPFs)

Each individual Kepler target light curve files is accompanied by a TPF. The TPF is the single-most informative resource in the archive for understanding the instrumental, non-astrophysical features within a target light curve. Consequently, it is recommended that users always examine a TPF in conjunction with its light curve. They provide the detector pixel and celestial coordinate mapping of a target mask and its subset containing the optimal aperture. TPFs reveal the motion of a target across the optimal aperture, and the motion of nearby contaminating sources.

The TPF content is organized by timestamp. The timestamps are the barycentric Julian date at the midpoint of each accumulated exposure. Pixel data are presented as a time-series of images, one image per timestamp, all located within the first extension of the FITS file. Typical Kepler targets (Kp > 12) will contain 10-50 pixels, but bright sources will include a larger pixel set. A typical quarter will contain approximately 4,300 collected images in long cadence for each target, while a typical month will yield 43,200 images in short cadence mode. For each timestamp within the TPF, there is an image of the uncalibrated pixels collected around a target. This group of pixels is referred to as the target mask, which contain pixels assigned either to the optimal aperture or a halo around it. The optimal aperture is the set of pixels over which the collected flux is summed by the Kepler pipeline to produce a light curve. The halo pixels are those pixels surrounding the optimal aperture pixels, which are used for calibration purposes and provide operational margin.

For each timestamp, the TPF includes the raw counts (FITS column labeled “RAW”) a fully calibrated postage stamp pixel image (FLUX) which incorporates bias correction, dark subtraction, flat fielding, cosmic ray removal, gain and nonlinearity corrections, smear correction (the Kepler photometer has no shutter), and local detector electronic undershoot (i.e. sensitivity of the pixel response to bright objects). The Data Processing Handbook (Fanelli et al. 2011) contains further details of these corrections. The TPFs also provide pixel images for each timestamp containing the 1-σ flux uncertainties of each pixel (FLUX_ERR), a calibrated sky background (FLUX_BKG), 1-σ uncertainties to the sky background (FLUX_BKG_ERR), and cosmic rays incidences (COSMIC_RAYS). All of these postage stamp images are found in the first extension of the FITS file. Sky background generally cannot be well-estimated from the TPFs themselves because target masks do not encompass enough sky for a good background estimation. Instead 4,464 pixels across each channel are recorded at long cadence specifically to measure the sky background. Those measurements are interpolated across each target mask to characterize the local sky background for each aperture.

Each timestamp has a quality flag coupled to it which alerts the user to phenomena and systematic behavior that may bring the quality of the photometric measurement within that timestamp into question. Detrimental behavior is generally associated with one of the following: i) physical events such as cosmic rays followed by short term detector sensitivity dropouts, ii) foreign particles such as dust, iii) spacecraft motion due to attitude-control reaction wheel resets, zero-torque crossing events, spacecraft pointing offsets and/or loss of fine-pointing upon guide stars, iv) time-dependent variation in incident solar radiation and telescope focus (caused by either Kepler’s orbit, autonomous operational commands directing the spacecraft to re-point towards a safe direction, or pointings towards Earth for the transmission of data), and v) differential velocity aberration (DVA) which is caused by the spacecraft’s orbital motion constantly changing the local pixel scale and field distortion. See Christiansen et al. (2011) for more detailed descriptions of each event listed above and Fraquelli & Thompson (2011) for a list of quality flags in the TPF and its corresponding events.

A pixel bitmap indicating the use of each target mask pixel in the Kepler pipeline is stored as an image in the second FITS extension of the TPF. The target masks do not track and follow stellar motion, and the large pixel scale under-samples the point spread function. Optimal apertures in general cannot provide absolute photometry because target flux is always lost outside the pixel borders and contamination from nearby objects falls inside the collection area. Spacecraft motion and focus variation are detrimental to Kepler photometry because time-dependent variation in either property results in different fractions of target light being lost from the aperture and different amounts of source contamination falling into the aperture. Despite Kepler’s cadence-to-cadence pointing generally being stable at the milli-arcsecond level, motion larger than this threshold has a measurable consequence at the few 10-5 photometric accuracy. Kepler simple aperture photometry is consequently a combination of astrophysical signal from the target and systematics from the spacecraft and its environment. The more precise the scientific requirement, the more care one must take to achieve accurate photometric results.

Using the motion across the detector of a set of reference stars, the Kepler pipeline predicts the motion of the target over time and provides a predicted position for each timestamp within the TPF (the FITS columns labeled POS_CORR1 and POS_CORR2). Predictions of the target motion trace many of the Kepler systematics, and thus measured astrometric deviations from the reference star predictions are likely to be astrophysical in nature. For example, as a target’s brightness varies, the centroid of the flux distribution across the pixels will move if there are contaminating sources in the target mask’s pixels. Detecting the change in the flux centroid position within a mask is a method that can help detect faint, unresolved background binaries or other variable stars, which can appear as a false detection of a planetary transit.

Figure 1: Quarter 2 long cadence SAP light curve of the eclipsing binary star V1950 Cyg (KIC 12164751; Horne 2008), produced by the PyKE tool kepdraw. The most-prominent systematic effect in this light curve is the long-term decay in flux from the target which falls by 3% over the duration of the quarter. This drop is a consequence of differential velocity aberration pushing the under-captured target position across the fixed pixel aperture over time.


Figure 1 provides a typical example of a Kepler long cadence light curve, specifically the quarter 2 simple aperture photometry of the eclipsing binary star V1950 Cyg. In this example, the flux affected by short-term systematics are dominated by the high-amplitude intrinsic variability of the target, but the effects of DVA still clearly manifest as a 3% decrease in target flux over the duration of the quarter. The situation is clarified by inspection of the associated TPF. Figure 2 reconstructs the photometry for each individual pixel within the target mask of the source of interest. The mask includes both the star itself and the halo pixels around the star. The pixels in Figure 2 with gray backgrounds are used by the Kepler pipeline to be the photometric optimal aperture for the archived light curve. The other pixels in the halo are associated with the target mask but they play no part in the calculation of the archived time-series photometry. The wings of the point spread function extend into many pixels surrounding the optimal aperture. Kepler apertures, in general, are designed to maximize signal-to-noise which usually under-captures target flux. Without full capture of a source, motion and focus-induced artifacts in the summed light curve are inevitable. In Figure 2, as the quarter proceeds, note how the flux captured in each pixel can increase or decrease as the target moves across the pixel array. This example shows that the flux is continuously being redistributed between neighboring pixels of the optimal aperture, and different amounts of flux will fall outside this aperture over time. The times and nature of events related to the discontinuities seen in the TPF light curves are recorded under the QUALITY column in the TPF FITS headers.

Figure 2: Example output plots from PyKE tools keppixseries and kepdraw. (left) The plot is created from the quarter 2 target pixel file. The numbers along the axes identify the pixel column and row on the CCD. The pixels comprising the optimal aperture for the target have a gray background. No data are collected in the black pixels, and the white pixels, which typically collect some of the target’s flux, are the halo pixels. The axes labels “arbitrary flux” and “time” refer to the photometric time series plotted for each individual pixel. Each light curve in the gray and white pixels is plotted on an identical linear flux scale. The target flux is continuously being redistributed among the neighboring pixels of the optimal aperture as the quarter progresses. (right) A magnification of the calibrated light curve from CCD pixel (97,796). The decline of target flux indicates the target moved within the optimal aperture pixels. The missing flux was redistributed to the pixel above, as seen in the left panel. The pixel light curves are for Quarter 2 long cadence observations of V1950 Cyg.


There are instances when extracting target pixels over a larger detector area compared to the optimal aperture chosen by the pipeline minimizes or removes the instrument effects from the light curves. However, the artifact mitigation of including more pixels comes at a cost. More pixels within the flux summation decreases the photometric signal-to-noise by adding more sky background from the additional pixels. The user must decide whether adding more pixels is an acceptable mitigation for the systematics. Many Kepler targets exist within crowded fields, and multiple nearby sources may contribute to the flux within the target mask. While it is sometimes beneficial to include more pixels within a modified optimal aperture, in the worst case scenario, the systematic errors in a light curves and source contamination can increase significantly by including more pixels in extraction.

Previous: Data Resources Up: PyKE Primer Next: Light Curve Files


Questions concerning Kepler's science opportunities and open programs, public archive or community tools? Contact us via the email address.
FirstGov - Your First Click to the US Government
+ Freedom of Information Act
+ Budgets, Strategic Plans and Accountability Reports
+ The President's Management Agenda
+ NASA Privacy Statement, Disclaimer,
and Accessibility Certification

+ Inspector General Hotline
+ Equal Employment Opportunity Data Posted Pursuant
to the No Fear Act

+ Information-Dissemination Priorities and Inventories
NASA - National Aeronautics and Space Administration
Editor: Martin Still
NASA Official: Jessie Dotson
Last Updated: Jan 6, 2012
+ Contact NASA