Skip to main content

TransitFetcher

An automated space-based (Kepler/TESS) exoplanet transit retrieval and preprocessing pipeline.

Simply provide a host star name (e.g. Kepler-10), then TransitFetcher automatically downloads and extracts all individual transit light curves (from MAST via lightkurve) for known transiting planets in the system!

Example image

Installation

Install the latest stable release from PyPI:

pip install transitfetcher

Usage

TransitFetcher only has one function: fetch(), which retrieves and (optionally) plots various transit light curves. For example,

from transitfetcher import fetch

fetch("WASP-148")

Function Parameters

fetch(
    target,
    output_root=None,
    includes=["Kepler", "TESS"],
    normalize_flux=False,
    plot_entire_lightcurve=True,
    plot_individual_transits=True,
    plot_folded_transits=True,
    plot_riverplot=True,
    generate_transitfit_csvs=False
)
Parameter Type Default Description Notes
target str Required Target name or identifier. Do not include planet letters (e.g. "Kepler-10" NOT "Kepler-10 b").
output_root str or Path None Root directory for output files. None defaults to the current working directory.
includes list[str] ["Kepler", "TESS"] Missions to include when searching for transit data. Only accepts "Kepler" and/or "TESS".
normalize_flux bool False Prioritize flux-detrended data (by Savitzky-Golay filtering) when processing transits.
plot_entire_lightcurve bool True Generate unfolded light curve plots by quarter/sector.
plot_individual_transits bool True Generate plots for individual transit events.
plot_folded_transits bool True Generate phase-folded transit plots by quarter/sector. Always uses detrended data
plot_riverplot bool True Generate transit river plots by mission. Always uses detrended data
generate_transitfit_csvs bool False Generate configuration CSV files for TransitFit.

Output

For each target, TransitFetcher creates a dedicated output directory containing the retrieved light curves, extracted transit events, plots, and other auxiliary files. Directories containing planet-specific outputs (folded_transit_plots, individual_transit_csv, individual_transit_plot, and transitfit_configs) are further organized into sub-directories for each known transiting planet in the system.

TransitFetcher_<target>/
├── folded_transit_plots/       # Phase-folded light curves per planet (always detrended)
│   ├── <planet_1>/
│   ├── <planet_2>/
│   └── ...
├── individual_transit_csv/     # Individual transit CSVs (detrended if normalize_flux=True)
│   ├── <planet_1>/
│   ├── <planet_2>/
│   └── ...
├── individual_transit_plot/    # Individual transit plots (detrended if normalize_flux=True)
│   ├── <planet_1>/
│   ├── <planet_2>/
│   └── ...
├── lightcurve_plots/           # Full mission light curve plots (detrended if normalize_flux=True)
├── river_plots/                # River plots for each mission per planet (always detrended)
├── transitfit_configs/         # Configuration files for further TransitFit use
│   ├── <planet_1>/
│   ├── <planet_2>/
│   └── ...
├── <target>_lc_flattened.csv         # Combined detrended light curve
├── <target>_lc_unflattened.csv       # Combined original light curve
└── <target>_transit_ephemerides.csv  # Planetary parameters queried from exo.MAST

Usage Notes

  • TransitFetcher does not perform transit fitting or parameter inference of any kind. It is intended for automatic extraction of individual transit events to be subsequently analyzed using arbitrary methods and software, particularly geared towards transit timing variation (TTV) studies.
  • TransitFetcher currently uses lightkurve.SearchResult.download_all() for MAST light curve downloads. While direct bulk downloads via astroquery.mast may be supported in the future, TransitFetcher currently does not, and so you may see yourself rate limited if you were to fetch many target light curves using a for loop.
  • It is highly recommended to keep normalize_flux as False (default) to preserve original flux values. TransitFetcher uses a Savitzky-Golay filter (polynomial degree 2) with a window length of at least 4x the transit duration or 25 hours (51 for Kepler and 751 for TESS), which may be unreliable for some transits. Users should always manually inspect folded transit plots if normalize_flux is True.

Metadata

Release files for transitfetcher 1.0.1

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

Source distribution (sdist)

Source distribution for transitfetcher 1.0.1
File Size Uploaded Provenance Actions
transitfetcher-1.0.1.tar.gz 14.6 kB Without provenance Details for transitfetcher-1.0.1.tar.gz

Built distribution (wheel)

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

Total release size: 27.8 kB

Release files / transitfetcher-1.0.1.tar.gz

Download URL transitfetcher-1.0.1.tar.gz
Size 14.6 kB
Tags Source
SHA-256 checksum
How to use checksums
db6723dafa4bea31bc9b78bf88c717663d34116f5ee40dc33f789cfd8f706726
BLAKE2b-256 checksum
How to use checksums
3b280804b4802ca3eb0ae11efd851cb07b63d57e02e2b0de04db194d99d7f81b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.5

Release files / transitfetcher-1.0.1-py3-none-any.whl

Download URL transitfetcher-1.0.1-py3-none-any.whl
Size 13.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
fed93b568a83b034f8f260c8ac8ae7118e37e3702810f7acaca0f753349875f0
BLAKE2b-256 checksum
How to use checksums
dbea078aff2fb3341f80c5f42db583ec5ee71d43a54a629df49b88fd3e5c0494
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.0.1 CPython/3.12.5

Security for transitfetcher 1.0.1

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files No provenance

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