With this package that builds on lightkurve, you can reduce TESS data while preserving transient signals. You can supply a TPF or give coordinates and sector to construct a TPF with TESScut. The background subtraction accounts for the smooth background and detector straps. Alongisde background subtraction TESSreduce also aligns images, performs difference imaging, and can even detect transient events!
An additional component that is in development is calibration of TESS photometry, and reliably link muti-sector light curves.
TESSreduce can be installed through pip:
pip install git+https://github.com/CheerfulUser/TESSreduce.git
Example reduction for SN 2018fub:
import tessreduce as tr
obs = tr.sn_lookup('sn2018fub')
| Sector | Covers | Time difference |
| | | (days) |
|----------+----------+--------------------|
| 2 | True | 0 |
| 29 | False | 721 |
tess = tr.tessreduce(obs_list=obs)
OR
import tessreduce as tr
ra = 10.127
dec = -50.687
sector = 2
tess = tr.tessreduce(ra=ra,dec=dec,sector=sector)
If you have a downloaded TPF you can load that directly into tessreduce.
tess = tr.tessreduce(tpf='file')
Photometry method
TESSreduce can perform aperture and PSF photometry. The photometry method used is set by the phot_method option which can either be aperture or psf. In general the PSF method appears to be more robust, however, there are cases where aperture still provides a better lightcurve. The default method is aperture. Using the example above we can use different photometry methods as follows.
tess = tr.tessreduce(obs_list=obs,phot_method='psf') # runs PSF photometry for reduction
tess = tr.tessreduce(obs_list=obs,phot_method='aperture') # runs aperture photometry for reduction
You can also define the photometry method when creating a lightcurve with diff_lc as follows.
lc, sky = tess.diff_lc(phot_method='psf')
The PRF photometry method uses the TESS_PRF package which can be found here: https://github.com/keatonb/TESS_PRF
Flux calibration
TESSreduce can calibrate TESS counts to physical flux, or AB magnitudes, by using PS1 data, If your field is dec >-30, and SkyMapper data for Southern field. IF you want a flux calibrated light curve then use:
tess.to_flux()
OR
tess.to_mag()
Several options are available for flux and are interchangeable, however, mag is currently not reversible. To easily plot the resulting light curve:
tess.plotter()
Extracting key variables
The main variables that TESSreduce assigns during the reduction can be accessed as follows:
- flux:
tess.flux - background:
tess.bkg - reference:
tess.ref - reference index:
tess.ref_ind - lightcurve:
tess.lc - Mask:
tess.mask - Source catalog:
tess.cat
TESS data can be complicated, and there are a lot of other functions burried in TESSreduce, so if you want some guidence on how to do a specific analysis contact me at: ryan.ridden@canterbury.ac.nz
Example reductions
We include a few notebooks for some possible reductions and science cases in the examples folder.
Citing TESSreduce
If you make use of TESSreduce, please cite Ridden-Harper et al. (2021):
@ARTICLE{2021arXiv211115006R,
author = {{Ridden-Harper}, R. and {Rest}, A. and {Hounsell}, R. and {M{\"u}ller-Bravo}, T.~E. and {Wang}, Q. and {Villar}, V.~A.},
title = "{TESSreduce: transient focused TESS data reduction pipeline}",
journal = {arXiv e-prints},
keywords = {Astrophysics - Instrumentation and Methods for Astrophysics, Astrophysics - High Energy Astrophysical Phenomena},
year = 2021,
month = nov,
eid = {arXiv:2111.15006},
pages = {arXiv:2111.15006},
archivePrefix = {arXiv},
eprint = {2111.15006},
primaryClass = {astro-ph.IM},
adsurl = {https://ui.adsabs.harvard.edu/abs/2021arXiv211115006R},
adsnote = {Provided by the SAO/NASA Astrophysics Data System}
}
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file tessreduce-2.0.0.tar.gz.
File metadata
- Download URL: tessreduce-2.0.0.tar.gz
- Upload date:
- Size: 230.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
942864c36d1a38b968c67b6b1ce642b5dccecb15aff52c756df8a0bda809a3bd
|
|
| MD5 |
c344053074e5369a6a9c7da4ad59208f
|
|
| BLAKE2b-256 |
1eba342738cfb551aa8801020034dc48838156d89c3cc5028c66a2371997d79e
|
File details
Details for the file tessreduce-2.0.0-py3-none-any.whl.
File metadata
- Download URL: tessreduce-2.0.0-py3-none-any.whl
- Upload date:
- Size: 223.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.12.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
661c823ff83c785287c038a6aea382a4a9b28957eba602c6c8b607a1d71513ac
|
|
| MD5 |
937146d7147ec96eb17957d9145a6798
|
|
| BLAKE2b-256 |
fc915683eb5892cd9c452ad96c33614d8d1b49fd9d85fa453d58ee7cad8f66ee
|