Skip to main content

tpfi

PyPI version License: MIT

tpfi is an easy-to-use visualization tool for astronomers to identify and analyze stars in the Kepler, K2, and TESS missions. The main focus of this project is on two functions: plot_identification and plot_season. These functions create plots to help visualize target stars and their surrounding environments.


Plot identification charts for Kepler, K2 and TESS.

pPKxsjH.png

pPKxcDA.png

pPKx6ud.png

The plot_identification function creates identification charts, which are useful for determining if a target is contaminated by nearby stars. In each chart, the right panel overlays the Gaia DR3 catalog onto the TESS Target Pixel Files (TPF) with the target marked by a cross symbol. The circle size represents the relative brightness of the stars according to Gaia G magnitude. The left panel displays the same sky coverage but taken from the DSS2 Red survey.

This function is revised based on tpfplotter.


Plot season charts for Kepler targets.

pPKxrge.png

The Kepler Space Telescope was designed to observe a specific field of stars continuously, but it also needed to ensure its solar panels faced the Sun to power its operations. As Kepler orbited the Sun, it performed a 90-degree roll every three months (or every quarter) to keep its solar panels sunward. After four of these quarterly rolls, amounting to a full year and a complete 360-degree rotation, Kepler would return to its original orientation. Consequently, every set of quarters separated by four (e.g., Q1, Q5, Q9) would find Kepler with the same pointing towards its target field, as the telescope effectively revisited its initial orientation after its annual orbit.

The plot_season function creates a plot of the TPF for each season of the Kepler mission for a given target star. Since the aperture mask may change even in the same season, the function only plots the aperture mask for the first quarter of each season. This function is only applicable for Kepler targets.

Season 1: Q1, Q5, Q9, Q13, Q17

Season 2: Q2, Q6, Q10, Q14

Season 3: Q3, Q7, Q11, Q15

Season 4: Q4, Q8, Q12, Q16

Installation

You can install this package using pip:

pip install tpfi

To upgrade to the latest version, run:

pip install -U tpfi

How to use

See the example notebook for more details.

How to cite

If you use this package in your research, please add the following sentence to the footnote or acknowledgement section of your paper:

This work has made use of \texttt{tpfi} (publicly available at \url{https://github.com/keyuxing/tpfi}).

and cite our paper:

Xing et al., 2024 [ads link][iop link]

Contributing

If you would like to contribute to this project, feel free to submit a pull request or open an issue on GitHub. Any suggestion, improvement, or bug report is welcomed.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Metadata

Release files for tpfi 1.2.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for tpfi 1.2.5
File Size Uploaded
tpfi-1.2.5.tar.gz 10.8 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for tpfi 1.2.5
File Interpreter ABI Platform
tpfi-1.2.5-py3-none-any.whl Python 3 none any Details

Total release size: 21.3 kB

Release files / tpfi-1.2.5.tar.gz

Download URL tpfi-1.2.5.tar.gz
Size 10.8 kB
Tags Source
SHA-256 checksum
How to use checksums
58a7abe8f7c77e60dc7c4a9e1a87f00898691ba8f15812a0de6624ce64c22a42
BLAKE2b-256 checksum
How to use checksums
78c6073930d77a077c1e21b9b48ba53fedeb42ebb562c6adda2ff260669658f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 22, 2025.

Transparency log

Release files / tpfi-1.2.5-py3-none-any.whl

Download URL tpfi-1.2.5-py3-none-any.whl
Size 10.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6420c4f03905912ee514bd51c1c6abecbbf5a8d934124636a1a23df317992d1f
BLAKE2b-256 checksum
How to use checksums
7d7016e54ac72808bf2cad3321348f1b58879df542612bb1488e0459b7896ff0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 22, 2025.

Transparency log

Release history Release notifications | RSS feed

This release

1.2.5 This release

2 release files

1.2.4

2 release files

1.2.3

2 release files

1.2.2

2 release files

1.2.1

2 release files

1.2.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.7

2 release files

1.0.6

2 release files

1.0.5

2 release files

1.0.4

2 release files

1.0.3

2 release files

1.0.2

2 release files

1.0.1

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page