Manuscript Offprint
arXiv:2608.25019EncoTESS: Age-Sensitive Encodings from Raw TESS Light Curves
Open access. PaperVantage converted this article to text, so layout and figures may differ from the original.
ABSTRACT
Main sequence stars of spectral types late F through M exhibit systematic variability in photometric light curves, particularly when they are young. Rotational modulation of starspots manifests as quasi-sinusoidal variability, which enables the measurement of stellar rotation periods ( ). Variability can also be stochastic, as in stellar flaring. However, since measurements of stochastic processes are highly dependent on the time of observation, they are typically noisier. Considering that different manifestations of variability have unique observational nuances, models that naturally unify these different types of variability are incredibly useful for stellar characterization. Towards this goal, we have developed EncoTESS: a Time Series Foundation Model (TSFM) trained on a subset of TESS 2-min light curves. EncoTESS is specifically designed to handle the observational noise, heteroskedastic measurements, irregular sampling, and large data gaps common to TESS data. It is also of the size of a typical literature TSFM, so can be run easily on a modern laptop. EncoTESS encodes light curves into a fixed-size latent parameter space, which can be used to infer physical stellar properties and recovers light curve summary statistics well. EncoTESS outperforms and variability amplitude as age indicators for stars that have not converged onto the slow rotator sequence yet; broadly these include K and M stars Myr, and M stars Gyr. We focus on age inference as an application of EncoTESS in this work, but other downstream tasks such as stellar classification could also be explored. The architecture of EncoTESS enables its future extension to TESS light curves of all cadences, and additional surveys such as Kepler and the upcoming PLATO mission. The core EncoTESS framework and library of encodings produced for the stars used in this work are publicly available at https://github.com/philvanlane/encotess.
Keywords: Stellar astronomy (1583) — Solar physics (1476) — M dwarf stars (982) — Stellar ages (1581) — Stellar rotation (1629) — Neural networks (1933) — Bayesian statistics (1900) — Time series analysis (1916) — Irregular cadence (1953) — Light curves (918)
1. INTRODUCTION
Photometric variability, a term used to describe the fluctuations in an object's brightness over time, is a fundamentally intuitive property that can be measured from sequential observations.
In the modern era, long-time-baseline observing programs have yielded groundbreaking systematic variability analyses, such as the HK project at the Mount Wilson Observatory (O. C. Wilson 1968), which characterized the magnetic activity cycles of solar-type stars. The recent space-based surveys Kepler (W. J. Borucki et al. 2010), K2 (S. B. Howell et al. 2014), and Transiting Exoplanet Survey Satellite (TESS; G. R. Ricker et al. 2015) have produced large catalogs of short cadence photometric time series data, which are useful for studying variability on timescales of minutes to hours. These data are predominantly formatted as “light curves” (LCs), which consist of a flux measurement, typically with associated observational error, at each timestamp of observation. Visually, LCs often appear as quasi-sinusoidal due to different types of periodic and stochastic variability of both astrophysical and instrumental origin.
In this work we focus on main sequence (MS) stars with spectral types of late F to M, whose variability is driven by surface magnetic fields that arise due to convective stellar envelopes (R. P. Kraft 1967). In particular we investigate how variability can be applied to constrain their ages, which are typically difficult to estimate using other methods.
Since these stars evolve minimally in color-magnitude space over their MS lifetimes, isochrone fitting is very challenging if they are not known members of a coeval population (D. R. Soderblom 2010). Asteroseismology is useful for dating large evolved stars, but the oscillation amplitude of asteroseismic signatures decreases towards cooler stars on the MS. This makes pulsation signals difficult to detect for FGKM stars; oscillations have been detected in only hundreds of F and G type stars, K type stars, and no M type stars to date (W. J. Chaplin et al. 2026). Lithium depletion can be useful at young ages, but its reliability decreases for stars Gyr (e.g. R. D. Jeffries et al. 2023).
However, rotation period ( ) can be used as an age indicator for these stars; this practice is known as gyrochronology (S. A. Barnes 2003). The short observational cadences of Kepler, K2, and TESS have increased the number of literature measurements by orders of magnitude (e.g. A. W. Boyle et al. 2026; A. R. G. Santos et al. 2021, 2019; A. McQuillan et al. 2014) over previous ground-based catalogs. This increase in data volume, along with recent innovations in data-driven and machine learning (ML) methods, have enabled a new class of empirical gyrochronology models (L. G. Bouma et al. 2023; Y. Lu et al. 2024; P. R. Van-Lane et al. 2025) that estimate stellar ages probabilistically from and mass or some proxy for mass such as temperature or color.
Although gyrochronology works reasonably well for FGK stars that have converged onto the “slow rotator” sequence, there is still intrinsic scatter in the relationship, particularly for young stars. There is also multimodality in the spindown behavior of M dwarfs, and these patterns hinder the accuracy and precision of gyrochronology for the youngest, reddest stars (e.g. S. A. Barnes 2003; E. K. Pass et al. 2022, 2024; P. R. Van-Lane et al. 2025). This motivates the need for additional indicators to improve age constraints, and LC-derived metrics would be particularly useful as they would allow us to leverage the wealth of LCs already produced by Kepler, K2, and TESS.
One example of another LC-derived age indicator is stellar flaring rate, which is often parameterized by the number of flares, total flare energy, or time spent flaring. Flaring rates change systematically with age at a population level (J. R. A. Davenport et al. 2019; A. D. Feinstein et al. 2020; A. A. Medina et al. 2022; A. D. Feinstein et al. 2024; E. Mamonova et al. 2025; A. Tran & I. Song 2026), but since flares are stochastic events it takes an impractically long temporal baseline to constrain flaring rates for individual stars.
Another example of a LC-derived age indicator is the photometric magnetic activity index , which S. Mathur et al. (2023) measured from Kepler LCs and showed is correlated with age. Notably, S. Messina (2021) showed that among stars with similar colors and , photometric variability amplitude can provide additional age information and can therefore be used as a complementary indicator to .
While measurements such as , flaring, and are useful age indicators, combining these handpicked features in a single model is difficult to optimize analytically since they are correlated. Furthermore, they are summary statistics calculated from data points in each LC, and their values depend on how they are measured. For example, several different methods are widely used in literature to calculate , such as Lomb-Scargle Periodograms (LSPs; N. R. Lomb 1976; J. D. Scargle 1982), autocorrelation functions (ACFs; e.g. A. McQuillan et al. 2013), wavelet transforms (e.g. R. A. García et al. 2014), and Gaussian Processes (GPs; e.g. R. Angus et al. 2018), which each have their own drawbacks that contribute to uncertainty (R. Angus et al. 2018). There is also inherent loss of information that comes from deriving any single summary statistic from an entire LC. This motivates the need for a more holistic, data-driven approach to analyzing LC data.
Given recent progress in computing and artificial intelligence (AI), it is now feasible to implement such an approach. In this work, we develop EncoTESS: a Time Series Foundation Model (TSFM; H. Ismail Fawaz 2020; J. Ye et al. 2024, and references therein) to encode TESS LCs. Unlike task-specific models, TSFMs are trained under self supervision to learn generalized patterns of time series data. The goal is typically to characterize the processes driving the observations. TSFMs are now routinely used across fields and industries to analyze different families of time series data such as stock prices, temperature fluctuations, and the housing market.
Several TSFMs have already been developed for astronomy, including Astromer 1 and Astromer 2 (C. Donoso-Oliva et al. 2023, 2026), DESA (I. Kamai et al. 2025), and FALCO (X. Zuo et al. 2026). Readers may also be familiar with the prominent astronomy foundation model AION-1 (L. Parker et al. 2025), which combines imaging, spectroscopic, and tabular data, but importantly it does not handle time series data. Our work also draws inspiration from other models that are not strictly TSFMs, but that implement state-based approaches to modeling astronomical processes (J. A. Esquivel et al. 2025; R. Herrera et al. 2026; R. Zimmerman et al. 2024).
While previous astronomy TSFMs are similar conceptually to ours, there are several key considerations we aim to address with EncoTESS:
-
Training dataset. Most literature TSFMs are trained on Kepler LCs, which have a 4 year baseline but come from a small patch of sky ( 115 deg ). Since TESS is an all sky survey, it has observed many more M dwarfs , which are important to this work since they are particularly difficult to date using . Since TESS photometry is 10× noisier than Kepler as measured by transit timescale noise (J. E. Van Cleve et al. 2016), and the continuous viewing period is only 27 days per sector, Kepler-trained models are unlikely to transfer well to TESS data, so we need a model directly trained on the noisier, shorter TESS LCs.
-
Observational Sampling. We need to handle irregularly spaced, heteroskedastic data, and be robust to different temporal resolutions and variable sequence length. This flexibility is crucial for handling the downlink time in TESS LCs, which manifest as a data gap of 1 day in each sector, and for extensibility to different sampling cadences. Most literature models are not explicitly designed with such nuances in mind.
-
Architecture. Most TSFMs use a transformer architecture, which is computationally expensive to scale to long LC sequences. We want a model that can run on consumer hardware efficiently, so we implement a Recurrent Neural Network (RNN) based approach.
Notably, there are 2 literature TSFMs that have been trained on TESS LCs that are worth describing here.
D. Poznanski (2026) uses a Quantile Graph (QG) to convert 2-min TESS LCs into fixed-length feature vectors. However, in pre-processing they divide the LCs into approximately continuous segments of 4096 data points ( 6 days) and ignore small gaps within those segments. This methodology is not scalable to other cadences, and it ignores the longer term LC context. They also detrend each LC in pre-processing, which can remove signal from longer term variability such as slow rotation.
J. Ding et al. (2026) developed StarCLR, which is pre-trained on TESS LCs at multiple cadences, and crucially does use observational timestamps as input so is gap aware. However, they fix LC sequences to 8192 data points in pre-processing, and only pretrain on LCs that already have evidence of periodic variability based on a prior LSP analysis. Since one of our goals is to consider all types of variability and not rely on periodicity, this filter is a crucial restriction.
Additionally, neither D. Poznanski (2026) nor J. Ding et al. (2026) incorporate flux measurement uncertainties into their models.
For these reasons, we opted to develop our own TSFM instead of adopting one from literature. §2 describes our training dataset, §3 presents our model and training architecture, and in §4 we evaluate its ability to reconstruct LCs. In §5 we explore how the latent encodings are correlated with physical properties, and test its recovery of traditional summary statistics. We interpret what EncoTESS actually learns from LCs in §6. §7 explores age inference as an application, and shows that EncoTESS outperforms models that use only and/or variability amplitude as age indicators. We investigate whether EncoTESS can predict field star ages in §8. We discuss systematic effects and future directions in §9, and conclude in §10.
Originally named ASTROMER by C. Donoso-Oliva et al. (2023) but then referred to as Astromer 1 by C. Donoso-Oliva et al. (2026).
We selected targets based on literature catalogs, from three general categories. The first is exoplanet hosts, which includes all stars from the NASA Exoplanet
Y. N. E. Eschen & M. Kunimoto (2024) quote 117,475 M dwarfs with a TESS magnitude > 13.5 mag based on the TESS Input Catalog (TIC) Candidate Target List (CTL) v8.01 (K. G. Stassun et al. 2019), compared to the 4,218 Kepler targets classified as M dwarfs by E. Gaidos et al. (2016).
| Reference | # Stars | # LCs |
|---|---|---|
| P. R. Van-Lane et al. (2025) | 2,495 | 7,166 |
| A. D. Feinstein et al. (2024) | 6,753 | 25,198 |
| R. Kiman et al. (2021) | 753 | 2,964 |
| S. G. Engle (2024a) | 54 | 205 |
| E. Magaudda et al. (2020) | 154 | 372 |
| E. Mamonova et al. (2025) | 320 | 1,985 |
| MOCAdb (J. Gagné et al. 2026) | 436 | 1,006 |
| E. R. Newton et al. (2016) | 1,615 | 6,571 |
| E. R. Newton et al. (2018) | 485 | 1,864 |
| E. K. Pass et al. (2022) | 24 | 75 |
| E. K. Pass et al. (2023) | 115 | 515 |
| E. K. Pass et al. (2024) | 119 | 362 |
| E. Gaidos et al. (2023) | 173 | 826 |
| B. Kim & S. Lépine (2022) | 6,047 | 8,784 |
| NASA Exoplanet Archive | 3,952 | 19,990 |
| 21,507 | 69,345 |
De-duplicated across sources.
Table 1. Number of stars and total LCs (TESS sectors) in the EncoTESS training catalog, broken down by literature source.

Figure 1. Distribution of Gaia DR3 colors by source category. Exoplanet hosts and thick disk stars are highly concentrated around , whereas the other targets are more evenly distributed are are responsible for the other peak at .
Archive filtered to records with the default flag, having a documented TIC_ID with associated 2-min LCs, and a populated gaia_dr3_id field. The second category is thick disk stars, which we included to bolster the sample of field age LCs used in training. This sample consists of all stars in the B. Kim & S. Lépine (2022) catalog that have associated 2-min LCs.
The third category consists of FGKM MS stars that exhibit variability or have independently calibrated ages. These FGKM MS targets are sourced from literature catalogs of open clusters and associations (P. R. Van-Lane et al. 2025; A. D. Feinstein et al. 2024; R. Kiman et al. 2021; E. Mamonova et al. 2025; J. Gagné et al. 2026), studies of magnetically active and/or rotating nearby M dwarfs (E. Magaudda et al. 2020; S. G. Engle 2024b; E. Gaidos et al. 2023; E. R. Newton et al. 2016, 2018), and M dwarfs in wide binaries (E. K. Pass et al. 2022, 2023, 2024).
Table 1 summarizes our LC dataset. It is grouped by literature source, and provides the total number of stars and total number of sectors with 2-min LCs from each. Since some targets were present in multiple sources, the total number of stars and LCs are less than the sum of all individual sources. Our final dataset consists of 69,345 individual LCs from sectors 1–101, which represent 21,507 unique stars.
Figure 1 presents the Gaia DR3 distribution of the entire dataset, broken down by literature source category. The distribution is essentially bimodal; there is a sharp peak at from exoplanet hosts and thick disk stars, and a broader peak at which is almost entirely from the other FGKM calibrators.
2.1. Light Curve Preprocessing
We used Lightkurve (Lightkurve Collaboration et al. 2018) to download all LCs, and applied the filter quality_bitmask="default" to remove unreliable flux measurements. The raw data we extracted from each LC were the observed PDCSAP flux f, the measurement uncertainty (flux_err) , and the time of observation t. Where f was recorded in the LC but no , we used a default of the median value from that LC. We also reset the times of each LC so they started at .
We normalized each LC to a median flux of 0 and a half interquartile range of 1, so that the normalized measurements ( , ) were:
These metrics were used because traditional z-score normalization based on mean and standard deviation was highly sensitive to extreme outliers, which are sometimes present at the very start and/or end of sectors.
Version 2.5.1 of Lightkurve was used, in which the default bitmask is 17087. This means that flux measurements with any of the bit value flags 1, 2, 4, 8, 16, 32, 128, 512, or 16,384 as described in Table 28 of P. Tenenbaum & J. M. Jenkins (2018) are excluded from our data.
The three observational channels we saved from each LC were therefore:
2.2. TESS and Light Curve Metadata
In addition to the three per-observation channels, we saved the TESS magnitude of the target, as well as the sector number S, camera number , and CCD number of the LC, which are provided by the Lightkurve objects. We also saved the two flux normalization parameters and , as inputs for EncoTESS. This is for two reasons: (i) they track overall activity levels and general variability, and (ii) they are correlated with noise levels and instrumental systematics, so including them explicitly helps EncoTESS disentangle systematic and astrophysical effects.
Finally, we included the cadence of observation as metadata; while this does not inform our model since it is 120s for all LCs in this work, we include it as a semantic step towards extending EncoTESS's applicability to all TESS LCs.
So, for every LC we save a 7-dimensional array of metadata:
2.3. Gaia Crossmatch
For all LCs, we crossmatched TIC IDs with Gaia Data Release 3 (DR3; Gaia Collaboration et al. 2023) IDs using a combination of the GAIA field in the MAST TIC catalog (which corresponds to Gaia DR2 ID) and the dr3.dr2_neighbourhood table in the Gaia DR3 database. This was required in some cases to identify the TIC IDs of sources from the literature catalogs, but we always performed this crossmatch regardless to identify any sources that did not have measured parallax, G, BP, or RP flux measurements in DR3, which we then excluded from this work.
We applied zeropoint corrections to the Gaia DR3 parallax using gaiadr3_zeropoint (L. Lindegren et al. 2021. Gaia DR3 G, BP, and RP were de-reddened using the dust maps from G. Edenhofer et al. (2024) and G. M. Green et al. (2019), with the sampling and conversion process described by P. R. Van-Lane et al. (2025) (hereafter V25). The one distinction worth noting is that V25 samples distances for each star were based on their Gaia DR3 parallax. In this work we sampled distances based on C. A. L. Bailer-Jones et al. (2021) where possible, and fell back to parallax otherwise.
G. Edenhofer et al. (2024) is used as the primary dust map in this work, and we supplement with G. M. Green et al. (2019) for stars that G. Edenhofer et al. (2024) does not cover. We discuss the implications of this choice in §9.
From this procedure we extract 6 metadata parameters for each star: de-reddened apparent Gaia magnitude , de-reddened color , parallax , and the associated uncertainties for each (notated , , and respectively).
3. MODEL ARCHITECTURE
Here we elaborate on the choice (described briefly in §1) to develop EncoTESS as a new TSFM instead of using a literature model. First, since TSFMs are designed to learn generalizable features of time series data, they naturally encode fundamental properties of the underlying processes instead of only information relevant to a specific task. This provides the additional benefit of characterizing the driving processes in a task-independent framework. TSFMs also often achieve results on downstream tasks comparable to bespoke models (e.g., A. Das et al. 2023; X. Liu et al. 2024). Therefore, while age inference is one of the primary goal of this work, we developed EncoTESS as a TSFM so it could potentially be used for other downstream tasks such as classification of spectral types or inference of other stellar properties.
In the following subsections we briefly describe the EncoTESS architecture in four logical segments, but refer readers who wish to understand the full mechanics to Appendix C. Figure 2 also presents an abstracted overview of EncoTESS, including the input data, training procedure, and outputs.
3.1. Input Data
Our input data for an LC of length L is a -dimensional matrix of normalized time series data:
and a 13-dim metadata vector:
We treat time as an observable instead of interpolating the data to a uniform grid because we want EncoTESS to learn the concept of absolute time. This is for two main reasons: (i) the model should understand the difference between an abrupt astrophysical jump in flux vs a gradual change in flux over a gap in measurements (e.g. TESS downlink time), and (ii) this is required for future integration of LCs with different observational cadences. EncoTESS needs to understand the difference between -min cadence observations spanning an hour, and -sec cadence observations spanning 10

Figure 2. A schematic view of the data flow and training process of EncoTESS. The training dataset consists of raw LCs (timestamp, flux, and flux measurement uncertainty values for each point), and their corresponding metadata consisting of stellar and sector parameters from Gaia DR3 and TESS. Training is via reconstruction: subsets of an LC are encoded using both forward and backward processing into hidden states ( and respectively), which are used to predict the flux at some offset. EncoTESS learns to construct these hidden states to maximize the likelihood of its predictions. This is repeated at variable prediction offsets. After training is complete, the hidden states corresponding to every observation in a LC are aggregated into a 1536-dim latent representation of each LC. In this schematic, solid lines represent one-time data processing and dashed lines represent computations that are executed iteratively during training. The colored grids represent vectors, where each pixel is a dimension and the color represents the magnitude of that dimension. The dimensions shown here are accurate: each and is 64-dim, so each is a 128-dim concatenation of and , and the final LC encoding is a 1536-dim vector constructed by pooling all vectors in 12 different ways (see Appendix C.4 for details).
minutes, and be able to project both sets of observations into a shared interpretation.
To the metadata fields, we apply simple normalizations to ensure all fields are approximately of order unity:
Appendix C.1 describes in detail how the LC and metadata parameters are encoded in the EncoTESS implementation.
We note here that including additional “views” of time series data as input, such as power spectra and/or ACFs, can help foundation models learn (e.g. I. Kamai et al. 2025). To determine whether this would help EncoTESS, we benchmarked the performance of several versions of EncoTESS which included frequency power spectra and ACFs calculated from each LC as additional input channels. We found that these additional channels did not improve performance (see Appendix A for details).
3.2. Recurrent Neural Network Architecture
Transformers are often considered to be the state-of-the-art for foundation models because of their ability to model short and long scale interactions between features via their “attention” mechanisms. However, the number of compute operations in transformers scales with sequence length as . This makes processing long sequences a computational concern.
In contrast, RNNs do not have a built in attention mechanism, and instead model long scale dependencies by carrying information through the time series sequentially. This means that while there isn't the same capability to model direct interaction between every feature as in transformers, the number of compute operations scales as instead of . This is an important computational advantage when considering long and densely sampled LCs.
There are two other distinct advantages of RNNs. First, transformers require fixed feature size (i.e., sequence length), but RNNs do not. Second, RNNs typically use significantly fewer parameters than transformers.
While another advantage of transformers is their ability to process sequences in parallel, in contrast with tradition RNNs that process sequentially, L. Feng et al. (2024) developed an RNN architecture termed a minGRU which implements parallel processing and therefore removes that key bottleneck.
For these reasons, we have developed EncoTESS as an RNN, and implement the minGRU architecture developed by L. Feng et al. (2024). The final EncoTESS architecture consists of only 64,000 parameters. This is tiny compared to most TSFMs, which are typically parameters at a minimum.
A new family of State Space Models (SSMs; e.g., A. Gu & T. Dao 2023) have also become more popular over the last several years, which have computational costs similar to RNNs but more flexible architecture that enables more efficient training on modern hardware. While it may prove useful to implement an SSM in future work, for EncoTESS we used the simpler RNN approach.
We describe the RNN implementation in detail in Appendix C.2, but the key concept is that EncoTESS learns to represent the LC at any point t using a 64-dim “forward hidden state” and a 64-dim “backward hidden state” . represents the context of the LC up until time t, and represents the context after time t. The hidden states depend on both the observational and metadata channels. Combining them yields a 128-dim hidden state , which therefore represents the full LC context at any point t including the stellar and observational information from the metadata too.
3.3. Training Procedure
Training is executed via unlabeled self supervised reconstruction. In practice, this means that we train EncoTESS to predict the flux value at some time based on the LC context and metadata. This method stems from the idea that to reasonably replicate a sequence of observations from partial information, a model must be able to intelligently describe the underlying processes, and therefore training in this way will force the model to learn rich representations of the stars. The simplest version of this training task is predicting the observation at some timestamp given observations from to .
To train EncoTESS we iterate this procedure over variable offsets (prediction “horizons”) extending from 2 minutes to 4 days, to encourage EncoTESS to capture long terms trends. We also apply masking to parts of each LC and metadata during training to improve EncoTESS’s robustness against missing data. The prediction component itself is a Conditional Normalizing Flow (CNF), which enables full probabilistic flux likelihood estimation instead of a point estimate with Gaussian uncertainty. These components are described in detail in Appendix C.3.
3.4. Model Output
Our RNN framework learns to represent each point in a LC as the 128-dim vector . A typical LC is therefore represented with data points, with the true size depending on the number of data points in the LC. This representation is not useful for downstream applications due to its large and variable size, so we apply different types of aggregation to reduce this to a fixed 1536-dim vector that we call for each LC. Details of this aggregation are provided in Appendix C.4. Importantly, while we mask portions of the input during training, we use the full metadata and set of observations in this work when processing LCs to compute .
A useful exercise is estimating the “intrinsic dimensionality” of a parameter space such as to estimate the minimum number of dimensions required to fully describe it. We used TwoNN (E. Facco et al. 2017) to probe this and measured an intrinsic dimensionality of 13.
Therefore, many of these 1536 dimensions are highly redundant, so for visualization and downstream tasks it can be useful and/or necessary to reduce the dimensionality further. We use three different dimensionality reduction techniques in this work, which are summarized here and explained in further detail in Appendix B.
-
Uniform Manifold Approximation and Projection (UMAP; L. McInnes et al. 2018b) is used to compress into 2 dimensions for visualization. The dimensions themselves are not meaningful so we do not perform any quantitative analysis with them, but we use UMAP for plots in the rest of this work.
-
Principal Component Analysis (PCA; H. Hotelling 1932) is an unsupervised method that re-orients into a new 1536-dim parameter space that we call , by maximizing the variance along its axes. These are called “principal components” (PCs), and PCA is designed such that information is concentrated in the earliest PCs. Therefore taking a small subset of PCs is much more useful than a small set of random features from . For example, 44% of the variance in is explained by PC1 alone. In this work we use different subsets of the PCA space depending on task complexity, but often use the top 4 PCs (which we call ), top 8 ( ), or top 16 ( ).
-
We use Partial Least Squares (PLS) to construct a 1536-dim space analogous to , however PLS is a supervised method that we design to maximize the covariance with age ( ) along its axes. We call this space . It therefore has its age-relevant information concentrated in its top components by design, so we use the top 3 components of (we call this subspace ) for age inference tasks in this work.
In the rest of this work we generally use the 2-dim UMAP for visualizations, the PCA space for interpretability and correlation analyses, and the 3-dim for age inference.
4. FLUX RECONSTRUCTION
Here we examine how well the final model is able to accomplish its training task: flux reconstruction. We explore its performance at predicting the flux at “unobserved” points in an LC, and also what factors affect its predictions. Practically, there are several contexts where this could be applied, including infilling lower cadence observations with higher cadence predictions, interpolating through large data gaps such as the TESS downlink time, or predicting future observations.
4.1. Context Effects
We first evaluate EncoTESS's performance at different prediction “horizons” , which is the time interval between data included in training context and the prediction target time. For example, a prediction horizon of one hour in the forward direction means that at a given time , the flux measurement is predicted based on a training scope that includes all observed flux measurements from to . We apply this horizon equally in both the forward and backward directions. As a consequence, flux measurements within of the beginning of the LC have no forward training context, and flux measurements within of the end of the LC have no backward training context, other than metadata. In Figure 3, we plot using two different prediction horizons: 0.5 hours and 17 hours. These correspond to average offsets of 16 data points and 1024 data points, respectively, in a 2-minute cadence LC. It is clear that at shorter horizons, EncoTESS is more confident and able to track variability better. At longer horizons, its confidence is weaker and its predictions trend closer to the long-term median flux. This is not surprising, given that uncertainty of specific flux measurements will accumulate over time in a noisy light curve.
Next, we test the impact of varying observational uncertainty. Figure 4 compares for scalings between and the real , which are used in the CNF prediction head. We see that there appears to be a minimum prediction uncertainty, characterized by the width, that the model learns even for low . This is representative of the typical noise floor of the LCs in our dataset. As expected, above that floor the

Figure 3. The confidence of flux predictions is highly dependent on the prediction horizon. Here we compare forward model predictions where the horizon is (i) 0.5 hours, and (ii) 17 hours. Shaded regions represent the confidence interval of predictions. Black points with the grey error bars are true measured values, normalized as per Equation 1.

Figure 4. The confidence of flux predictions also depends on the measurement error. Here we compare flux predictions using the real measurement error against reconstructions based on models with artificially dampened and inflated TESS flux uncertainty. Shaded regions represent the confidence interval of in each scenario. Black points with the grey error bars are true measured values, normalized as per Equation 1. Error bars are not shown in the prediction regime to avoid clutter. While the credible regions do not always symmetrically widen at every point with inflated , the uncertainty increases overall.
width increases with , and the median begins to regress towards the median of the entire LC.
4.2. Performance Compared to Baselines
It is also important to characterize how well EncoTESS can reconstruct flux compared to more naive models, to determine whether its architecture is providing value. To that end, we tested EncoTESS against three baseline models: (i) a naive deterministic baseline model, (ii) a model based only on stellar metadata, and (iii) an MLP-based model.
The naive baseline model uses a windowed mean to predict the flux at any time based on the 32 observations preceding the target time and the 32 observations following the target time. Uncertainty for this model is estimated as the root mean square error (RMSE) of predictions, which is a metric used only to estimate this prediction horizon (data points)

Figure 5. Flux reconstruction performance for the four model variants, using negative log likelihood (NLL) and median absolute errors (MAE) as metrics. Individual NLL values were clipped to for stability. The RNN architecture and CNF prediction head used in EncoTESS provide value, particularly when looking at prediction horizons of a few hours to days and when considering the entire likelihood shape, although the overall accuracy of EncoTESS and the MLP are comparable.
model's prediction uncertainty and not to compare between models.
The metadata-only baseline uses a CNF prediction head conditioned only on the 13 LC metadata fields and the target prediction time , so cannot use the preceding or following LC context.
The learned MLP baseline uses the 32 preceding and following observations, combined with the same stellar metadata fields used in EncoTESS, in an MLP to predict the flux along with a learned Gaussian uncertainty.
For reference, EncoTESS has 92,857 learned parameters; this includes the prediction head which is why this number is larger than the parameter count of the core model quoted elsewhere. The metadata baseline has 14,386 learned parameters and the MLP baseline has 69,658 learned parameters. The windowed mean model is fully deterministic model so has 0 learned parameters.
These baselines were used because they help us assess the value added by different components of the EncoTESS architecture:
-
The windowed mean model is effectively the most naive linear method of flux prediction, so it provides a minimum performance baseline.
-
The metadata model is EncoTESS without , so it provides a baseline for how much additional value the hidden states provide.
-
The MLP model uses only short-term LC context and no CNF prediction head, so it provides a baseline for how effective the RNN architecture is at capturing long term trends, and for how much value the CNF prediction head provides.
Figure 5 compares EncoTESS against the three baseline models using two different prediction metrics: negative log likelihood (NLL) and median absolute error (MAE). It is useful to consider both, since MAE measures how accurately the median estimates the true flux while the NLL also considers the shape and width of . The absolute MAE and NLL values are not important, but lower corresponds to a better fit.
By both metrics, we see that the metadata model is invariant with prediction horizon, which is expected given that it has no LC context. Also, at the longest horizons shown in this plot ( hr), the predictive capabilities of the MLP and EncoTESS asymptote to approximately the level of the metadata model. This indicates that at long horizons, those models rely heavily on stellar properties to predict flux, and the LC context captured in is not useful.
Comparing the other three models, by NLL it is clear that the naive windowed mean model performs the worst at all horizons, and EncoTESS performs the best. In contrast, by median absolute error (MAE), all 3 models are comparable at short term horizons, but the windowed mean performs worse at long horizons. This indicates that disregarding uncertainty, flux prediction by averaging between neighboring points works reasonably well at short timescales, however at longer timescales using this performs worse than a learned global mean, which is what the MLP and EncoTESS converge to.
The fact that EncoTESS outperforms the MLP in NLL more than it does in MAE indicates that the flexibility of the CNF head is an advantage. Since EncoTESS does still slightly outperform the MLP at long prediction horizons, the RNN architecture provides value for capturing trends on the scale of ~hours to ~days, although its advantage does seem to disappear at hrs. Since the model size of EncoTESS is only slightly

flux
time
TIC 280865190
Sector 7
time
UMAP 2
UMAP 1
(BP-RP)
Figure 6. LC encodings ( ) for two sample stars. The bottom right panel shows each star's position on a color-magnitude diagram. The bottom left panel shows the positions of each , compressed into two dimensions with UMAP. The background points are all other stars in our catalog. Example LCs from each star are shown in the top panel, which correspond to the circled LCs in the UMAP plot. The median distance between points ( ) representing different LCs from the same star is plotted for reference.
larger than that of the MLP, this indicates that there is real value in the architecture, and scaling up the size of EncoTESS in the future could improve performance. Furthermore, EncoTESS provides a built-in method of extracting the state of the LC at any point in time via the .
5. VARIABILITY CHARACTERIZATION WITH LIGHT CURVE ENCODINGS
As described in §3.4, we can compute for every LC in our dataset using the final trained version of EncoTESS. Figure 6 plots the 2-dim UMAP compressed versions of with two stars highlighted as examples. In green (TIC 394508465) is a high mass eclipsing binary (EB), and in gold (TIC 280865190) is a rapidly rotating M dwarf that exhibits frequent flaring. We have 4 LCs from the EB in our dataset, and 24 LCs from the M dwarf. One sample LC from each is plotted in full. For reference, we have also plotted the median pairwise difference between of LCs from the same stars across our entire catalog, demonstrating that unique LC features of the same star can shift .
While these stars were chosen as examples because they are distinctly different in many traditional ways, we can see how those properties translate to :
• They are on opposite ends of a color-magnitude diagram as shown in the lower right panel.
- The sample LCs exhibit very different properties; aside from the obvious EB signature, the M dwarf has a much noisier LC and exhibits flaring, which the EB does not.
• Even though each LC is encoded independently, the LCs from each star are clustered together. The M dwarf’s LCs are scattered more in the UMAP space than the EB’s.
These observations reinforce several characteristics of EncoTESS's expected behavior. Different LCs from the same star should be clustered given that they share stellar properties, but the scatter is also informative. While it partly depends on the absolute number of LCs, the noise properties of different sectors may also affect LC location. Furthermore, the stochastic nature of flares means that they may not appear in all of the M dwarf's

UMAP 1
Figure 7. All LC encodings, compressed from the 1536-dim into 2 dimensions with UMAP. Points are color coded by the Gaia color of the star.
LCs. Finally, noisier LCs are more susceptible to sector-specific systematics, and although we have tried to mitigate these effects in EncoTESS, there is likely some persistence of such artifacts.
This was one specific example, but one could investigate LCs across to study LC properties and stellar characteristics. For example, we found that most of the EB LCs in our dataset are extremely close to TIC 394508465 in the UMAP space. EncoTESS could be used in this way to classify different types of variability (e.g., flaring, rotation, eclipsing binaries, exoplanet transits, asteroseismic pulsations) automatically from light curves, similar to D. Poznanski (2026) and J. Ding et al. (2026).
5.1. Correlation with Physical Properties
In addition to examining specific light curve features, we can plot trends in different stellar properties and summary statistics across . As an example, in Figure 7 we have color coded each LC by Gaia of the star, plotted in UMAP space. Since color is one of our metadata input parameters, this partly reflects EncoTESS's own conditioning, but nevertheless the clear structure shows that color persists strongly through .
We can also go beyond color to inspect variability indicators that were not included as metadata input. Figure 8 shows the UMAP LC projections color-coded in each panel by the value of a summary statistic. Skewness measures the asymmetry in the flux distributions of each LC, and kurtosis measures how heavy the tail of the distribution is. Both of these were calculated directly from the LCs. The third panel shows rotation measurements derived by A. W. Boyle et al. (2026), and the last panel plots flaring equivalent duration ( ) as measured by A. D. Feinstein et al. (2024) . To get a single per LC, we simply added up all of the individual flare ED measurements as calculated by A. D. Feinstein et al. (2024) per sector and star.
There is clear structure in each plot, demonstrating that EncoTESS captures these measures of variability in . The quantities are also related in systematic, physical ways. To first order, we would expect stars that are rotating quickly to be younger and more magnetically active, and likely flaring more than slowly rotating stars. Stars that flare more are also more likely to have a larger flux kurtosis, and a larger skewness since flares manifest as positive jumps in flux. These relative trends are reflected in Figure 8, where we see that skewness/kurtosis/ are generally positively correlated with each other and negatively correlated with . Interestingly, a negative skewness can also be an indicator of a transiting exoplanet, which manifests as periodic dips in flux. We investigated this specifically and found that the region of negative skewness around the center of the UMAP also has a high density of transiting exoplanets.
5.2. Recovery of Variability Statistics
As a more quantitative test, we used EncoTESS to recover the summary statistics shown in Figure 8 from , and compared those results to three control models. In all four cases we trained a simple MLP predictor to estimate each summary statistic from the inputs. Since the architecture of is the same for each variant, this tells us whether truly is adding value over more naive inputs. The 4 models we compare are:
-
EncoTESS. Input is .
-
Pure Noise. Input is 1536-dim Gaussian noise, normalized to the same scale as . This model represents the performance we would expect if contained no useful information.
-
Metadata Baseline. Input is the 13 metadata fields used by EncoTESS. This model represents how well we can recover the summary statistics from stellar properties, so any improvement on that is due to information captured in from the LCs.
-
MLP Baseline. Input is a 256-dim vector pooled from the output of the last layer of the MLP
This is not the total time that a star is in a flaring state during any given sector, but rather the time that it would take a star in its normal quiescent phase to emit as much energy as was produced by its flares. This is why it is on a timescale of minutes in this plot, not hours or days.

UMAP 1
Figure 8. All stars in our dataset, positioned by two dimensional UMAP compression of their latent encodings. Each subplot shows the stars colour-coded by specific measured parameters, which are clearly tractable in all cases through the latent representations.

Figure 9. Violin plot comparing the recovery of 4 LC summary statistics from 4 different inputs: (i) The real computed by EncoTESS, (ii) pure noise, (iii) only metadata, and (iv) an MLP-derived baseline. (iii) and (iv) are analogous to the metadata and MLP variants described in §4.2, but with a metric recovery target instead of flux reconstruction target. EncoTESS performs best overall, indicating that our architectural choices provide value. Residuals are transformed and scaled for ease of visualization, but key metrics are provided in native units in Table 2
model described in §4.2. Any improvement over this can be attributed to the RNN architecture and EncoTESS's ability to capture longer-term LC trends.
For each variant, no LCs were held out from pretraining, but recovery metrics were computed using 5-fold cross validation, and reported from the held out fold so there was no leakage between training and test datasets.
We compare the models in Figure 9 by showing the distribution of residuals for each metric. These residuals are transformed and scaled for each of visualization, so only the relative spreads in that figure are meaningful, but we report key summary statistics in native units in Table 2. Specifically, we highlight: (i) the median residual for each model/metric combination, which is an indicator of overall bias, and (ii): the IQR of residuals, which is a measure of accuracy/precision.
For the and indicators, we see that the EncoTESS bias is tied or comparable with the MLP, and EncoTESS does marginally better than the MLP by IQR.
Table 2. Median and interquartile range (IQR) of the residuals for each model/metric combination from a recovery test, in native units.
| Model | skew() | kurt() | (d) | ED (min) | ||||
|---|---|---|---|---|---|---|---|---|
| Med. | IQR | Med. | IQR | Med. | IQR | Med. | IQR | |
| EncoTESS | 0.002 | 0.037 | 0.013 | 0.091 | 0.01 | 0.67 | 0.00 | 3.22 |
| MLP | 0.014 | 0.084 | 0.101 | 0.337 | 0.03 | 0.71 | 0.00 | 3.62 |
| metadata | 0.027 | 0.310 | 0.273 | 0.847 | -0.09 | 2.20 | -0.01 | 5.10 |
| noise | 0.134 | 0.181 | 0.675 | 0.986 | -0.04 | 5.33 | -0.66 | 8.51 |
Aside from that, EncoTESS outperforms the other models by both indicators across all metrics, demonstrating that EncoTESS's architecture provides a quantifiable advantage over simpler implementations.
In particular, it clearly outperforms the other models in recovering the higher order flux summary statistics (skewness and kurtosis). This points to a distinct advantage of the RNN architecture: it is able to retain memory over the entire LC better than the other models which focus on short-term variability or the ability to persist LC context.
It is not surprising that the performance of the MLP is comparable to EncoTESS in recovering , since flares manifest over relatively short segments of the LCs. It is more interesting that the performance is comparable for , but as shown in Figures 3 and 5, EncoTESS flux predictions starts to regress to the mean LC behavior over intervals on the order of days, so it doesn't capture long period rotation as well. As suggested in §4.2, a larger version of EncoTESS may be able to capture these trends better.
6. INTERPRETABILITY
Here we investigate our results in the context of 2 specific questions:
-
Which LC features or segments are important to EncoTESS?
-
How does correlate with summary statistics of variability and/or other key features?
-
What are the age important features that are complementary to ?
which we address in the following subsections through analysis of the lower-dimensional representations of .
6.1. Saliency Analysis
We can apply a deterministic approach to evaluate which parts of LCs are most heavily weighted by EncoTESS. This is typically called “saliency analysis”: the evaluation of which input parameters most strongly influence a model’s output. In the context of EncoTESS, this means measuring how much each point in an LC contributes to the LC’s learned representation. While it is likely rare for any single point in an LC to have a uniquely critical impact, saliency analysis can reveal important structure in the way LCs are encoded.
There are different targets that can be considered in this analysis as measures of the model's “output”, and multiple different methods to evaluate the contribution of each input. For EncoTESS in particular, there are three targets that could all provide useful information: (i) the hidden states that represent the LC at any point t, (ii) the encoding of each LC, and (iii) a lower dimensional representation of such as (the PCA vectors as described in §3.4. Here, we use the first principal component from , PC1, as our target since it is a single information-rich number that describes any LC.
We also consider two methods of evaluating the contributions of input points: the integrated gradient (IG) and occlusion. Since the gradient of our target PC1 with respect to any input point is defined, we calculate the IG as;
This provides a measurement of how sensitive PC1 is to changes in each input point. In contrast, occlusion measures the change in the target PC1 that results from masking any input point. Since this is a different metric than IG, we do not expect both to exhibit the same structure, but we do expect some correlation because both are some measure of the importance of each input point. While the absolute values of changes in PC1 as measured by IG and occlusion are not directly interpretable, the relative differences between points in the LC are.
In Figures 10 and 11, we show traces of the two LCs that were also highlighted in Figure 6 (the M dwarf TIC 280865190 and the eclipsing binary TIC 394508465), color coded by these saliency measurements.
Several interesting features can be seen in these. First, observations that are around the median flux generally contribute very little information (with the exception

Figure 10. Colour coded contribution of every point in the LC (TIC 280865190, sector 7) to PC1, measured using an integrated gradient (IG) technique and occlusion. Positive and negative contributions move PC1 in different directions, but the magnitude of the contribution can be considered as an “importance” score.

Figure 11. Analogous to 10, but for the eclipsing binary TIC 394508465, sector 39.
being the occlusion test for the EB). This effect seems to be accentuated in the noisier M dwarf LC ( hereafter).
Second, the flare towards the end of has a strong influence on PC1, indicating that flaring is an important component of our latent space. Interestingly, most of the points in the flare push PC1 in the positive direction, but the very tip of the flare pushes it in the negative direction. This apparent inconsistency is likely the result of only considering the single dimension PC1, as the latent space is much richer and the contributions of these points in the flare are unlikely to be truly opposite when the entire is considered.
Third, both the positive and negative local extrema in push PC1 in a negative direction, but moderate positive flux values push PC1 in the positive direction. This indicates that EncoTESS is interpreting these points differently. Perhaps it interprets the local extrema as mostly noise, and that the smaller deviations model the rotation of the star more accurately. This is supported by inspecting closely; the gold points at moderate positive flux do seem to visually track the rotation of this star very well.
Fourth, we see in the LC of the eclipsing binary ( hereafter), that in this high signal-to-noise regime, there is not the same noise characterization as seen with . Positive flux values all push PC1 in the positive direction, and negative flux values push PC1 in the negative direction.

Figure 12. Saliency analysis of the eclipsing binary TIC 394508465, sector 39, comparing the magnitudes of the integrated gradients of the forward and backward hidden states. It is clear that the forward state is more sensitive to individual measurements overall, but the backward state is particularly sensitive to the eclipse features.
Finally, EncoTESS weights the eclipses seen in heavily, indicating that these contribute significantly to .
These saliency tests help us understand what LC features are contributing to the EncoTESS encodings in a deterministic way. While we only analyzed two specific LCs here, these tests could be widely applied across LCs to interpret .
6.1.1. Forward vs backward encoding
Saliency analysis can also help us understand the differences in EncoTESS's forwards and backwards encoding channels. Naively, since LCs are generally symmetric (with the exception of flares, and in some cases occultations, which have a distinct morphology), we would expect the forwards and backwards channels to behave similarly. Interestingly, this is not true, as shown in Figure 12. Overall, the magnitudes of the IG measurements are much higher when only considering the flow through the forward state. In contrast, while the backward state is generally less sensitive to each point individually, the relatively high sensitivity to the eclipse features stands out. Furthermore, we found that each direction contributes approximately equally (within 5-10% depending on the metric used) , indicating that the backward state encodes just as much useful information. This has interesting implications for our knowledge of how EncoTESS behaves and how TSFMs learn in general: the forward and backward directions naturally encode different types of features, even when provided training sequences that are mostly symmetric. The forward training learns to respond aggressively to local fluctuations, while the backward state is more robust to those, but both contribute important information to the global structure of .
6.2. Correlation with variability summary statistics
At a broader level, we can inspect which traditional variability statistics of LCs are most strongly correlated with . Here, we again use PC1 as our low-dimensional representation of , and we measure correlation by computing the Pearson r statistic between each feature and PC1. Since PCA is unsupervised, PC1 is a good diagnostic here as it is not biased towards age or any other features by design; it represents the axis where there is the greatest variance between LCs.
We included every metadata field in this test aside from S, , and . We excluded these because even though they may be correlated with PC1, the numerical values and their ordering are not meaningful. We also included stellar age ( ), absolute magnitude ( ), and the 4 variability summary statistics presented in Figure 8.
Figure 13 presents the results. Only the top 10 features ranked by r are shown, but all others had correlations near the noise floor anyway. The strongest correlation is with , indicating that the overall amplitude of variability has a large influence on an LCs location in -space. The other strongest correlations are primarily related to the overall brightness of the target and/or its position on a CMD; these are , , , , and .
It is notable that there is significant correlation with age in PC1, even though PC1 was not designed specifically as an age diagnostic. The correlation with is

Figure 13. Top 10 light curve features that have the strongest correlation with the PC1 of . We included metadata features in this analysis as well as age (as provided in the source catalogs) and the variability statistics shown in Figure 8. It is clear that PC1 is primarily driven by the overall level of variability and target brightness, and color/magnitude measurements.
relatively minor, and approximately the same strength as with .
While this is a useful test, it comes with the caveat that this only explores PC1, which we did for ease of interpretability. Many of these features may have stronger correlations with later PCs, so these numbers should not be interpreted as the ceiling of correlation between and these features.
In Appendix D we show a corner plot of color coded by age as an example of how multiple PCs can be examined at once, however the makes interpretation more challenging.
6.3. Complementary Age Information
Here, we investigate what age information we can extract from that is complementary to . We start with a specific example in Figure 14. The stars are located at very similar points on a CMD and color- diagram, so they have almost identical age estimates from ageP. However, their true ages (from literature) differ by almost an order of magnitude. We also see that despite having similar rotation periods, they have different LC properties: in particular, there is a stronger rotational variability signal exhibited by TIC 405483684. This is reflected in : while there is some overlap in the positions of individual sectors (top left panel), the mean position of the LCs for each star are in different places in the UMAP encoding space. We see in the bottom left panel that ageET therefore estimates different ages for these stars, which are quite close to the literature ages.
We can check this in a more systematic way by probing the LC properties that are aligned most strongly with but not with . To do this, we first determined the linear direction in for which covariance with is maximized. Conceptually, this can be thought of as the primary axis in .
We then performed a linear regression to fit:
across all stars, from which we obtain a global and . From these we compute a “fitted” using the true of each star: , which we then subtract from to get the “residual” , which conceptually is the part of that cannot account for .
With we used PLS as described in §3.4 to obtain compute a 3-dim space analogous to that is linearly orthogonal to , and within this space we measured the correlation of various metadata features to the most predictive age direction. The provides a a quantification of the amount of -independent age information that each can provide. In this exercise we used all ages compiled from the source catalogs in Table 1, excluding ages from the NASA Exoplanet Archive. Importantly,
Since LC features may be correlated with each other in complex and highly nonlinear ways, this does not completely scrub from information. Some non-linear correlation with will survive, and this procedure also likely removes some non- information. We attempted to apply more complex nonlinear methods, but some residual information always remained, so we decided to use this method as an imperfect but useful and interpretable first-order approximation.

Figure 14. Schematic showing age inference for two stars that are in similar places on a color-magnitude and color-rotation diagram, but have different light curve properties and different encodings. ageP is unable to recover accurate ages from rotation alone, but ageET is able to recover very accurate ages using the light curve encodings.
while these are defined metrics that we can measure age correlation with, there are likely additional important features derived from that cannot be explained as easily with summary statistics.
Figure 15 presents our results. We measure the correlation between tested features and age using the absolute value of the Pearson r coefficient. In the left panel, we see that , which is the half interquartile range of flux measurements as described in §3.1 and a measure of the total level of variability in a LC, is the single most descriptive feature. The next four features (TESS magnitude , med(f), absolute magnitude and ) are all strong correlated with a star's position on a CMD. This is not surprising, as is not a useful age indicator without some proxy for the mass of a star, which CMD position describes and typical gyrochronology relations already include.
To also remove the most CMD-dependent features, we repeated this test, but residualized against the direction most aligned with the combination of , , and , instead of just . Parallax , and are still important features, indicating that the model may rely on these features as a proxy for absolute magnitude. is still the most age-correlated feature, re-emphasizing that it holds -independent value, although its Pearson decreases (likely due to its strong correlation with ). Both tests also show that the total equivalent flare duration is the next most important purely physical age-correlated feature. There is minor age correlation with overall flux skewness, but at a level close to the noise floor. Overall flux kurtosis is not helpful and is not shown on these plots.
The fact that is important to EncoTESS corroborates the findings of S. Mathur et al. (2023) and S. Messina (2021), the latter in particular having shown that photometric variability amplitude is correlated with age even in stars with similar colors and rotation periods across five young associations and open clusters. These results confirm that those findings hold true across a larger dataset extending to older ages. The results also agree with D. Poznanski (2026) who found that variabil-

Figure 15. Features other than that are most aligned with age in the EncoTESS latent space. In the left panel we measure the correlation of each feature with age in the 3-dim space that is linearly orthogonal to . We do the same in the right panel, but in a space linearly orthogonal to the primary direction. In each panel we only show the top six features; the correlation with any other features is .
ity amplitude was heavily reflected in their LC encodings.
In addition to the overall level of photometric variability, this shows that flaring also provides age information complementary to . There are quite possibly more LC features that do not manifest in the summary statistics we have included in this test, but are captured by via the computation and useful for age inference. Exploring that regime and connecting such LC features to physical processes in the future could be yield useful insights.
7. AGE INFERENCE
While EncoTESS could be conceivably used in many downstream applications, here we specifically examine its age inference capabilities. A qualitative test of 's age information is to plot stellar age over our UMAP encodings, analogous to Figures 7 and 8. We do this in Figure 16, and see clear structure. Since age was not directly included as an input parameter when training EncoTESS, these means that EncoTESS naturally encodes age-related observables. As discussed previously, there is vast literature on rotation as an age indicator, and on other observables such as (e.g. S. Mathur et al. 2025) and flaring rate (e.g. A. D. Feinstein et al. 2024), however it is challenging to derive an analytical age prescription that combines these metrics in a complementary way. Furthermore, there are likely additional LC features that could provide even more complementary age information. The EncoTESS encodings offer an alternative method for stellar age inference, where we can leverage the information that EncoTESS has already learned to characterize these stars.
7.1. Bayesian Inference Framework
To clearly distinguish between the core EncoTESS architecture and this downstream age inference framework, which are decoupled, we will refer to the age inference framework that uses as ageET going forward. ageET is architecturally identical to the ChronoFlow age inference framework presented by V25, with an added step. ChronoFlow trained a CNF to estimate the likelihood:
where is the observational uncertainty on and is the stellar age.
In ageET, we replace with as an age-informative representation of as described in §3.4. In this context, since we want to predict the age once for every star, we create an aggregate for each star by taking the maximum value of each of the 1536 dimensions across all from different LCs of the same star. This is commonly referred to as max pooling. We also tested mean and median pooling, but found max pooling to be the most stable.
We use instead of using directly because training a model to learn

UMAP 1
Figure 16. All LC encodings, compressed from 1536 dimensions into 2 dimensions with UMAP. Points are colour coded by the age of the star from the literature catalogs described in §2, and clear structure is visible.
where is difficult and unstable due to the high dimensionality of . is already designed to carry maximal age information in minimal dimensions, which is perfect for this task. We also tested training an MLP to learn a low-dimensional age-relevant representation of , however that was unstable and led to overfitting. A more thoughtful implementation of a targeted MLP could help in principle, but we leave that for future work and use the PLS-derived here. Therefore we parameterize the ageET likelihood as:
Using as shorthand for and as shorthand for for readability, we follow the methodology of V25 to compute posterior age probability distributions by applying Bayes' theorem and expanding:
We also use the same age prior as V25:
and the same color prior, which is the convolution of a uniform distribution of colors that we would expect to see ignoring measurement error:
with Gaussian measurement error . So, our final color prior conditioned on both age and color uncertainty is:
Also, the evidence term is constant across our model, and gets normalized out when evaluating the age posterior, so it can be ignored.
By using these closed form priors, we can easily evaluate the likelihood we learn from ageET over a grid of possible ages to compute our age posteriors .
7.2. Comparison to Gyrochronology
To determine whether the is more informative than as an age indicator, we compare ageET's age recovery performance against two baseline models:
-
ageP: A baseline gyrochronology model that is architecturally identical to ChronoFlow (V25).
-
agePfH: A model that uses both and as observational indicators.
All 3 model variants were trained on the 2,893 stars in the EncoTESS catalog with documented ages and rotation periods in the literature sources, to ensure that performance differences were purely based on the model. Exoplanet hosts were excluded from this due to the heterogeneity and typically high uncertainty of their age measurements. They all implement the same Bayesian inference framework, priors, and gridding strategy to evaluate the age posteriors as described in V25.
We used “leave-one-sector-out” (LOSO) cross validation to test each model. In this scheme, we constructed 10 folds of stars, with no overlap in sectors. We trained 10 different versions of each model using 9/10 folds for training with the 10th was held out to compute test statistics. Within the 9 training folds, an 85%/15% training/validation split was used to select the best model.
This entire procedure was repeated 5 times for each model with different random seeds, and the posterior age distributions from each were combined to get an ensemble age posterior for each star.
There is some nuance to the LOSO mechanics, since many stars appear in multiple sectors. To ensure that there was absolutely no leakage between the training and test datasets, if sector X was part of the test dataset, any star that had a LC in sector X was excluded from the training and validation datasets. This is a conservative way to prevent ageET from overfitting to any unique stellar signatures, as the purpose of this test is to evaluate ageET's ability to characterize LCs from "new" sectors.
| Method | Pearson r | MAE (dex) | median res (dex) | % |res| > 0.5 dex | Coverage p16-p84 (%) |
|---|---|---|---|---|---|
| All Stars | |||||
| ageET () | 0.674 | 0.431 | +0.028 | 31.0 | 72.1 |
| agePfH () | 0.601 | 0.496 | -0.039 | 34.7 | 66.5 |
| ageP () | 0.532 | 0.529 | -0.064 | 38.7 | 72.8 |
| KM Subset | |||||
| ageET () | 0.709 | 0.395 | +0.021 | 27.8 | 73.2 |
| agePfH () | 0.489 | 0.530 | -0.092 | 37.5 | 66.2 |
| ageP () | 0.348 | 0.567 | -0.138 | 42.5 | 75.2 |
Table 3. Results from three different age recovery models: ageET which uses the 3-dim as its indicator, agePfH which uses both and as indicators, and ageP which uses only as its age indicator. The models are compared using 5 different metrics: Pearson , median absolute error (MAE), median residual, % of residuals dex, and % of true ages covered by the p16-p84 posterior interval. This last metric should be close to for a well calibrated model. In 4/5 metrics, ageET outperforms agePfH which outperforms ageP. In p16-p84 coverage, agePfH outperforms the other two models, which both exhibit overly conservative posteriors (although only by ). We have measured these metrics over all stars in our catalog (upper block), and again over only the region of relatively young, active stars (we call this the KM region for simplicity) as outlined in Figures 18 and 19. The difference between ageET and the other 2 models is larger in this regime.
Preventing leakage between training and test sectors is important to consider because direct encoders like EncoTESS naturally include sector-specific systematics. This can be an advantage, as described in §2, since this enables EncoTESS to separate systematic from astrophysical signatures. However it also requires more thoughtful testing since age information can be leaked into test datasets through these systematics. This leakage can allow “cheating”, where EncoTESS learns to use the correlation between sector and age, since these stars are in localized open clusters and not randomly distributed across the sky. This is also important for agePfH since the metric is sensitive to sector-specific noise. It is not as important for ageP since measurements are more robust to sector-specific systematics, but we nevertheless train each model with LOSO for consistency.
Table 3 presents the results from these tests. In all metrics, agePfH outperforms ageP. In 4/5 metrics, ageET outperforms them both. We see by Pearson and median absolute error (MAE) that the ageET age estimates are more accurate than the other models. It also has the lowest median residual, indicating that it has the least systematic bias. Finally, it has the lowest percentage of residuals dex, meaning it has the fewest catastrophic failures. The only metric it does not beat agePfH in is the percentage of true ages that lie with the p16-p84 posterior interval. This is not an indication of poor age estimates, just that the width of its posteriors are overly conservative.
We computed these metrics for all stars, and then for a subset of KM stars that lie in the region highlighted in Figures 18 and 19. This is not an unbiased subset: we chose this region specifically because this is where ageET performs the best. In this parameter space, it outperforms the other models by even wider margins.
In Figure 17 we compare the distribution of residuals from ageP and the ageET LOSO test, where is the median of the age posterior. The approximate spectral types shown in the left panel are based on the updated table of M. J. Pecaut & E. E. Mamajek (2013). Overall, ageET residuals are narrower and centered closer to 0, indicating that is a better age calibrator overall than . This is particularly true for young red stars, as shown in the left and middle panels of Figure 17.
In Figures 18 and 19, we compare the difference in log likelihood (LL) between ageET/ageP and ageET/agePfH respectively. Using LL as a metric is more informative than residuals because it considers both the shape and width of . A larger LL corresponds to a better match, so ageET outperforms ageP in positive (blue) regions, and the inverse is true in negative (gold) regions. It is worth mentioning that the age axis in this figure is , not , so the interpretation is which age indicator is more reliable in a specific region of this parameter
While the original paper does not include colors, we use the table that is maintained online, which does include .

Figure 17. A comparison of ages inferred from ageET and ageP. The left panel plots the residuals against , with approximate spectral types shown on top. The middle panel plots them against true age; we place stars along the x-axis evenly here in order of increasing age for ease of interpretation. The right panel shows the overall distribution of residuals. ageET is more precise for younger and redder stars, and less biased to the mean than ageP. From the histogram we also see that ageET is less systematically biased and has a narrower distribution of residuals than ageP, indicating that its posterior age estimates are better calibrated.

Figure 18. Difference in LL values from ageET and ageP for stars in our catalog with measured rotation periods and ages. Blue regions indicate where ageET is stronger, and gold regions indicate where ageP is stronger by this metric. LL values are binned with a resolution of 0.01 in and 0.01 in . Bins are smoothed over 0.2 in each direction to remove noise, and only bins with stars are kept. Approximate spectral types are shown on top, as described in 17. To the bottom right of the red dashed line is the KM region described in Table 3, where ageET consistently outperforms ageP.

Figure 19. Analogous to Figure 18 but comparing ageET to agePfH. agePfH is stronger than ageP, but ageET still outperforms agePfH over the KM region.
space instead of which types of stars are better characterized by each age indicator. However, these questions are highly correlated, especially in regions where the models do well.
In these figures we include all stars in our catalog with ages and rotation periods from the literature sources (excluding the exoplanet hosts and thick disk stars from B. Kim & S. Lépine (2022)). We bin results in a grid size of 0.2 in and and only show for bins that have stars. We also apply Gaussian smoothing for ease of visualization.
There are clear broad trends that emerge across this parameter space. ageP is more reliable for ~F and G type stars, and for K and M stars past an age that increases with color. This generally follows where we expect FGKM stars to converge onto a slowly-rotating sequence that has minimal scatter (e.g., D. Godoy-Rivera et al. 2021; P. R. Van-Lane et al. 2025), so it is not surprisingly that is very useful in this regime. However, ageET outperforms ageP for stars that are younger/redder than this threshold, which includes late K stars younger than Myr, M stars Gyr, where stellar spindown has not narrowed the distribution from the initial periods yet (e.g., A. W. Boyle & L. G. Bouma 2022; P. R. Van-Lane et al. 2025). Generally, younger and redder stars are also more magnetically active and therefore exhibit stronger variability in other ways, so this is evidence that other variability signatures captured by do provide age information that is complementary to rotation.
Since ageET outperforms agePfH in the same parameter space that it outperforms ageP, although by a smaller margin, EncoTESS is clearly extracting variability signals relevant to age that is complementary to both and the amplitude of variability.
We note here that there is another regime at very young inferred ages ( where ageP beats ageET, even for young red stars. This is because there is a small population of stars across a range of older true ages that ageET estimates as extremely young. This indicates that any stars with very young ageET ages ( a few Myr) should be treated with caution, but otherwise the broad trends described previously are consistent.
8. APPLICATION TO FIELD STARS
We also examined whether contains age information for field stars, since these stars are typically older and less variable than open cluster stars. To test this, we used the subset of 2,430 exoplanet host stars from our catalog having an estimated stellar age in their default record in the NASA Exoplanet Archive. Most of these are older than the oldest cluster stars in our catalog. We note that these age estimates are extremely heterogeneous from a wide variety of sources and methods, and often with large uncertainty, so there are inherent systematic bias in using these as “true” ages that we hope to recover. A detailed analysis of these systematics are outside the scope of this paper, so we take these age estimates at face value to see qualitatively whether our can provide value for field star age estimates.
We tested age recovery with k-fold validation on the 2,430 exoplanet hosts. For each fold, we balanced sampling so that there was uniform representation across 10 different age bins spanning 0–14 Gyr in the training and validation samples. We did not perform LOSO tests since the exoplanet hosts do not experience the same spatial biases as cluster stars. Instead of using Bayesian inference, we train the age inference model (which we call ageETXH) to learn directly:
which can be done in this case because we have a relatively uniform distribution of host ages, in contrast to ageET which would be biased to the clustered ages seen in its training dataset. Here we do not need to compress the dimensionality of because predicting a single variable from the high-dimensional is more stable than trying to do the reverse.
Architecturally, ageETXH consists of an MLP with 2 hidden layers to compress into 4 dimensions, then a CNF with 6 transforms and 2 hidden layers to predict age from these 4 dimensions.
We compare against three baselines:
-
A pure noise model in which we replace with Gaussian noise of the same scale as ; this is analogous to the noise model in §5.2.
-
A model that only includes CMD-related metadata fields as input instead of : , , , , and associated errors.
-
A model that includes the above CMD fields plus the 2 LC normalization metadata fields as input: and .
The noise baseline represents a performance floor that is achieved by a model that only receives color as an input; practically it learns to predict the mean age conditioned on color for every star.
The second variant represents a CMD-based estimate of the stellar age, which for many of the older exoplanet hosts is the primary way that they are constrained.
The third model represents age estimates based on CMD properties and high level summary statistics of variability: this is the performance that we would expect from ageETXH if the addition of in was non-informative for these stars.
Figure 20 shows the results from comparing these three variants, with residuals binned into seven different age groups where each spans 2 Gyr. It is clear that the majority of ageETXH's predictive power comes from

Figure 20. Violin plot showing age recovery for the 2,430 exoplanet hosts in our catalog with ages in the default NASA Exoplanet Archive records, grouped into 2 Gyr age bins. EncoTESS performance is shown in blue, the noise baseline in grey, and the CMD-only and CMD+variability variants in gold and green respectively. The majority of ageETXH's predictive power for these stars comes from CMD indicators, with high level variability contributing in the 0-2 Gyr bin. The number of stars in each bin is shown on top of the plot. Past 6 Gyr, all models struggle.
CMD information, as those variants are statistically indistinguishable past 2 Gyr. In the 0-2 Gyr bin, and med(f) do provide additional useful information.
Overall, the performance of ageETXH is comparable to the variant with CMD and variability metadata inputs, indicating ageETXH is not gaining any additional age information from the RNN architecture for these stars.
9. DISCUSSION AND FUTURE WORK
So far, we have developed EncoTESS using a small subset of all of the TESS data that are available, but in the future this could be expanded to all TESS LCs at all cadences from all sectors. Since we developed EncoTESS to be time-aware, functionally the architecture can already accommodate this, however it will require testing. It could be valuable to make EncoTESS “live” by fine-tuning it on new sectors as more LCs become available, and updating a public library of the encodings for every LC as the model receives more training data. As part of this work we provide for all LCs processed by this version of EncoTESS,
This architecture should be applicable to other survey data as well, such as Kepler and K2 LCs. The upcoming PLATO (H. Rauer et al. 2025) mission will provide LCs over a much longer baseline than TESS (2 years per hemisphere compared to 27 days per sector), and over a much larger field of view than Kepler ( compared to ). Those characteristics make it a prime opportunity to test EncoTESS's ability to capture longer term variability. This type of framework could also conceivably be used for other astronomical time series products such as cluster-integrated LCs (e.g., T. M. Wainer et al. 2023).
We also note here that machine learning and artificial intelligence capabilities are changing rapidly, and within the last few years there have been significant advances in TSFMs such as TimesFM, Moirai-MoE, Moirai 2.0, Chronos-2, and Timer-S1 (A. Das et al. 2023; X. Liu et al. 2024; C. Liu et al. 2025; A. Fatir Ansari et al. 2025; Y. Liu et al. 2026), and in particular SSMs (e.g., A. Gu & T. Dao 2023). Many of these aim to address the scalability and heterogeneity concerns of existing TSFMs, which were two of the key motivations for developing EncoTESS from scratch. While most literature TSFMs still do not incorporate measurement uncertainty, it is quite conceivable that state-of-the-art industry TSFMs will soon be able to handle astronomy LCs well. Also, since general TSFMs (e.g., A. Das et al. 2023; X. Liu et al. 2024) can now achieve performance comparable to fully supervised task-specific models in forecasting, it may be more efficient in the near future to fine-tune general TSFMs to astronomy data instead of pre-training an astronomy-specific TSFM from scratch. In addition to considering pre-built TSFMs, it may be useful to also test the performance of off-the-shelf tabular models such as TabPFN (N. Hollmann et al. 2022) or Google's TabFM for downstream tasks.
Regardless whether we maintain the core architecture of EncoTESS as is going forward, or adopt components that have been proven in other contexts, this work shows that a stellar TSFM trained on multi-survey, multicadence, LCs has tremendous potential.
9.1. Systematics
P. R. Van-Lane et al. (2025) provide a detailed discussion of systematics that affect age inference in their gyrochronology model ChronoFlow; specifically the choice of dust map used for de-reddening, cluster membership criteria, and choice of cluster age used for calibration. Together, these factors contribute dex of uncertainty to age estimates. This is an important source of error when posterior age predictions are narrow, but posteriors from EncoTESS typically have a width of dex, so that error dominates. Nevertheless, we suggest adding this 0.08 dex systematic error to any reported age estimates from EncoTESS.
Since EncoTESS uses raw LCs an input, there are other systematics to consider related to the data acquisition, such as the instrumental noise for any specific observation. However, EncoTESS is designed to explicitly use observational parameters as input to account for this. We include the sector, camera, and CCD of each LC explicitly as metadata, and also , med(f), and , which carry both signal and noise properties. EncoTESS therefore has this observational context that can help separate observational artifacts from astrophysical signal.
This could be further improved with a contrastive learning scheme similar to that implemented by J. Ding et al. (2026). While our training scheme was purely self-supervised flux reconstruction, and was calculated as a byproduct, contrastive learning would aim to make from LCs of the same star (and similar stars) as equal as possible, and maximize the difference in between very different types of stars. This would help remove observational artifacts from while keeping the important astrophysical signal.
9.2. Downstream Astrophysics
We have deeply investigated the potential of EncoTESS for age inference using its encodings, however this is one of many potentially useful applications of EncoTESS. Another is a variability classifier, which D. Poznanski (2026) and J. Ding et al. (2026) both presented as an application of their frameworks. We could also identify regions in space that correspond to known distinct populations of stars, and find other candidates for the population by proximity in .
Parameter inference is also possible, as the ageET architecture could be easily modified to predict properties such as mass or temperature instead of age.
In the near future, expanding our training sample to include asteroseismic calibrators is well attainable and could provide additional value for age inference and these other applications.
10. CONCLUSION
In this work we developed EncoTESS: a Time Series Foundation Model (TSFM) based on a Recurrent Neural Network (RNN) architecture, trained on 69,345 2-minute TESS light curves from 21,507 main sequence stars of spectral type FGKM. We built EncoTESS to be robust to high levels of noise, and to handle measurement uncertainty, irregular sampling, and large data gaps. EncoTESS uses raw light curves, stellar properties, and data acquisition parameters as input, to distinguish between astrophysical effects and observational systematics, and produces a meaningful fixed-dimension light curve encoding that can be used for downstream tasks such as classification or age inference.
The combination of the RNN architecture and probabilistic prediction head enables EncoTESS to outperform more naive models at predicting flux and recovering summary statistics. Interestingly, the forwards and backwards training components naturally encode different LC features, with the forward model being more sensitive to local flux variations but both contributing equally to the encoding.
Importantly,
• EncoTESS is only 64,000 parameters, which is at least two orders of magnitude smaller than typical literature TSFMs, and can trivially be run on most modern laptops.
• We showed that EncoTESS is able to characterize stars using their raw light curves, and encode that information into a latent representation that tracks different types of variability such as rotation, flaring, and higher order moments of the flux distribution.
• We found that EncoTESS outperforms and variability amplitude as age indicators for younger, redder stars that have not converged onto the slowly-rotating sequence. This confirms that EncoTESS is able to extract age-dependent variability signatures that are complementary to .
• These results indicate that EncoTESS is useful for age inference in regimes where gyrochronology is less precise.
While EncoTESS is specifically trained on TESS 2-minute light curves, expanding its scope to multicadence data, as well as Kepler, K2, and PLATO light curves, has the potential to be incredibly fruitful for characterizing stellar variability, age inference, and therefore for downstream science. With this architecture, it would also be possible to train an EncoTESS-type model live as light curves are observed, and maintain a library of encodings that get updates as new data is acquired.
Overall, EncoTESS provides a promising conceptual foundation for a data-driven approach to characterizing stellar variability, and generating useful data products for downstream science.
ACKNOWLEDGMENTS
P.R.V. was supported by funding from the Dunlap Institute, and a Postgraduate Scholarships - Doctoral (PGS-D) Award [PGS D - 589175 - 2024] from the Natural Sciences and Engineering Research Council of Canada (NSERC). PV would also like to thank Jonathan Gagné at the Montreal Planetarium and Université de Montréal for helping to extract data from MocaDB (J. Gagné et al. 2026), Andrea Zonca and Javier Hernandez Nicolau at SDSC for helping to optimize the EncoTESS code, and Ting Li at University of Toronto for providing local compute resourcing.
J.S.S. acknowledges the support of the Data Science Institute at the University of Toronto. J.S.S. was also supported by NSERC Discovery Grant RGPIN-2023-04849 and a University of Toronto Connaught New Researcher Award.
R.C. acknowledges the support of the Natural Sciences and Engineering Research Council of Canada (NSERC) and the Canada Research Chairs (CRC) Program [Award ID: CRC-2024-00372].
Gaia DR3 and TIC IDs of exoplanet hosts were retrieved from the Planetary Systems Composite Table (NASA Exoplanet Science Institute 2020) of the NASA Exoplanet Archive (R. L. Akeson et al. 2013) on March 16, 2026. The NASA Exoplanet Archive is operated by the California Institute of Technology under contract with NASA under the Exoplanet Exploration Program.
This project made use of GPU resources from the Bridges-2 supercomputer at the Pittsburgh Supercomputing Center (PSC), and the Expanse system at the San Diego Supercomputer Center (SDSC), allocated under the NSF Access project PHY240253.
This research has made use of the Astrophysics Data System, funded by NASA under Cooperative Agreement 80NSSC21M00561.
The authors disclose the use of Claude AI in this work for the purposes of developing and testing EncoTESS. Specifically, while all architectural and technical decisions were made by the authors, Claude Opus 4.6–5 was used to create and modify code. All AI-developed code was reviewed and validated by the authors, for which the authors assume complete ownership and responsibility.
All EncoTESS source code is available on Zenodo at: [insert here] and on GitHub at https://github.com/philvanlane/encotess. These repositories also contain our catalog of light curve encodings.
Facilities: Transiting Exoplanet Survey Satellite (TESS), Bridges-2 at Pittsburgh Supercomputing Center (PSC), Expanse at San Diego Supercomputer Center (SDSC).
Software:
This work made use of the following software packages: Jupyter (F. Perez & B. E. Granger 2007; T. Kluyver et al. 2016), matplotlib (J. D. Hunter 2007), numpy (C. R. Harris et al. 2020), pandas (Wes McKinney 2010; T. pandas development team 2025), python (G. Van Rossum & F. L. Drake 2009), scipy (P. Virtanen et al. 2020; R. Gommers et al. 2025), h5py (A. Collette 2013; A. Collette et al. 2023), PyTorch v2.9.1 , umap-learn (L. McInnes et al. 2018a; L. McInnes et al. 2018), and Zuko (F. Rozet et al. 2022, 2024).
This research made use of Lightkurve, a Python package for Kepler and TESS data analysis (Lightkurve Collaboration et al. 2018).
Software citation information aggregated using The Software Citation Station (T. Wagg & F. S. Broekgaarden 2024; T. Wagg et al. 2025).
REFERENCES
Akeson, R. L., Chen, X., Ciardi, D., et al. 2013, PASP, 125, 989, doi: 10.1086/672273
Angus, R., Morton, T., Aigrain, S., Foreman-Mackey, D., & Rajpaul, V. 2018, MNRAS, 474, 2094, doi: 10.1093/mnras/stx2109
Bailer-Jones, C. A. L., Rybizki, J., Fouesneau, M., Demleitner, M., & Andrae, R. 2021, AJ, 161, 147, doi: 10.3847/1538-3881/abd806
Barnes, S. A. 2003, ApJ, 586, 464, doi: 10.1086/367639
Borucki, W. J., Koch, D., Basri, G., et al. 2010, Science, 327, 977, doi: 10.1126/science.1185402
Bouma, L. G., Palumbo, E. K., & Hillenbrand, L. A. 2023, ApJL, 947, L3, doi: 10.3847/2041-8213/acc589
https://github.com/pytorch/pytorch
Boyle, A. W., & Bouma, L. G. 2022, arXiv e-prints, arXiv:2211.09822, doi: 10.48550/arXiv.2211.09822
Boyle, A. W., Bouma, L. G., & Mann, A. W. 2026, arXiv e-prints, arXiv:2603.05586, doi: 10.48550/arXiv.2603.05586
Chaplin, W. J., Campante, T. L., Lund, M. N., et al. 2026, A&A, 710, A361, doi: 10.1051/0004-6361/202659600
Cho, K., van Merrienboer, B., Gülçehre, Ç., et al. 2014, CoRR, abs/1406.1078
Collette, A. 2013, Python and HDF5 (O'Reilly)
Collette, A., Kluyver, T., Caswell, T. A., et al. 2023, h5py/h5py: 3.8.0, 3.8.0 Zenodo, doi: 10.5281/zenodo.7560547
Das, A., Kong, W., Sen, R., & Zhou, Y. 2023, arXiv e-prints, arXiv:2310.10688, doi: 10.48550/arXiv.2310.10688
Davenport, J. R. A., Covey, K. R., Clarke, R. W., et al. 2019, ApJ, 871, 241, doi: 10.3847/1538-4357/aafb76
Ding, J., Chen, X., Gao, X., et al. 2026, ApJ, 1003, 141, doi: 10.3847/1538-4357/ae64ef
Donoso-Oliva, C., Becker, I., Protopapas, P., et al. 2026, A&A, 707, A170, doi: 10.1051/0004-6361/202554026
Donoso-Oliva, C., Becker, I., Protopapas, P., et al. 2023, A&A, 670, A54, doi: 10.1051/0004-6361/202243928
Durkan, C., Bekasov, A., Murray, I., & Papamakarios, G. 2019, arXiv e-prints, arXiv:1906.04032, doi: 10.48550/arXiv.1906.04032
Edenhofer, G., Zucker, C., Frank, P., et al. 2024, A&A, 685, A82, doi: 10.1051/0004-6361/202347628
Engle, S. G. 2024a, ApJ, 960, 62, doi: 10.3847/1538-4357/ad0840
Engle, S. G. 2024b, ApJ, 960, 62, doi: 10.3847/1538-4357/ad0840
Eschen, Y. N. E., & Kunimoto, M. 2024, MNRAS, 531, 5053, doi: 10.1093/mnras/stae1496
Esquivel, J. A., Shen, Y., Leos-Barajas, V., et al. 2025, ApJ, 979, 141, doi: 10.3847/1538-4357/ad95f6
Facco, E., d'Errico, M., Rodriguez, A., & Laio, A. 2017, Scientific Reports, 7, 12140, doi: 10.1038/s41598-017-11873-y
Fatir Ansari, A., Shchur, O., Küken, J., et al. 2025, arXiv e-prints, arXiv:2510.15821, doi: 10.48550/arXiv.2510.15821
Feinstein, A. D., Montet, B. T., Ansdell, M., et al. 2020, AJ, 160, 219, doi: 10.3847/1538-3881/abac0a
Feinstein, A. D., Seligman, D. Z., France, K., Gagné, J., & Kowalski, A. 2024, AJ, 168, 60, doi: 10.3847/1538-3881/ad4edf
Feng, L., Tung, F., Osama Ahmed, M., Bengio, Y., & Hajimirsadeghi, H. 2024, arXiv e-prints, arXiv:2410.01201, doi: 10.48550/arXiv.2410.01201
Gagné, J., Moranta, L., Faherty, J. K., et al. 2026, arXiv e-prints, arXiv:2602.15695, doi: 10.48550/arXiv.2602.15695
Gaia Collaboration, Vallenari, A., Brown, A. G. A., et al. 2023, A&A, 674, A1, doi: 10.1051/0004-6361/202243940
Gaidos, E., Claytor, Z., Dungee, R., Ali, A., & Feiden, G. A. 2023, MNRAS, 520, 5283, doi: 10.1093/mnras/stad343
Gaidos, E., Mann, A. W., Kraus, A. L., & Ireland, M. 2016, MNRAS, 457, 2877, doi: 10.1093/mnras/stw097
García, R. A., Ceillier, T., Salabert, D., et al. 2014, A&A, 572, A34, doi: 10.1051/0004-6361/201423888
Godoy-Rivera, D., Pinsonneault, M. H., & Rebull, L. M. 2021, ApJS, 257, 46, doi: 10.3847/1538-4365/ac2058
Gommers, R., Virtanen, P., Haberland, M., et al. 2025, scipy/scipy: SciPy 1.16.3, v1.16.3 Zenodo, doi: 10.5281/zenodo.17467817
Green, G. M., Schlafly, E., Zucker, C., Speagle, J. S., & Finkbeiner, D. 2019, ApJ, 887, 93, doi: 10.3847/1538-4357/ab5362
Gu, A., & Dao, T. 2023, arXiv e-prints, arXiv:2312.00752, doi: 10.48550/arXiv.2312.00752
Harris, C. R., Millman, K. J., van der Walt, S. J., et al. 2020, Nature, 585, 357, doi: 10.1038/s41586-020-2649-2
Herrera, R., Leos-Barajas, V., Eadie, G., Semenova, E., & Davenport, J. 2026, arXiv e-prints, arXiv:2606.22601, doi: 10.48550/arXiv.2606.22601
Hochreiter, S., & Schmidhuber, J. 1997, Neural Computation, 9, 1735, doi: 10.1162/neco.1997.9.8.1735
Hollmann, N., Müller, S., Eggensperger, K., & Hutter, F. 2022, arXiv e-prints, arXiv:2207.01848, doi: 10.48550/arXiv.2207.01848
Hotelling, H. 1932, Journal of Educational Psychology, 24, 417, doi: 10.1037/h0071325
Howell, S. B., Sobeck, C., Haas, M., et al. 2014, PASP, 126, 398, doi: 10.1086/676406
Hunter, J. D. 2007, Computing in Science & Engineering, 9, 90, doi: 10.1109/MCSE.2007.55
Ismail Fawaz, H. 2020, arXiv e-prints, arXiv:2010.00567, doi: 10.48550/arXiv.2010.00567
Jeffries, R. D., Jackson, R. J., Wright, N. J., et al. 2023, MNRAS, 523, 802, doi: 10.1093/mnras/stad1293
Jenkins, J. M., Twicken, J. D., McCauliff, S., et al. 2016, in Society of Photo-Optical Instrumentation Engineers (SPIE) Conference Series, Vol. 9913, Software and Cyberinfrastructure for Astronomy IV, ed. G. Chiozzi & J. C. Guzman, 99133E, doi: 10.1117/12.2233418
Kamai, I., Bronstein, A. M., & Perets, H. B. 2025, ApJ, 994, 110, doi: 10.3847/1538-4357/ae0cbc
Kazemi, S. M., Goel, R., Eghbali, S., et al. 2019, CoRR, abs/1907.05321
Kim, B., & Lépine, S. 2022, MNRAS, 510, 4308, doi: 10.1093/mnras/stab3671
Kiman, R., Faherty, J. K., Cruz, K. L., et al. 2021, AJ, 161, 277, doi: 10.3847/1538-3881/abf561
Kluyver, T., Ragan-Kelley, B., Pérez, F., et al. 2016, in Positioning and Power in Academic Publishing: Players, Agents and Agendas, ed. F. Loizides & B. Schmidt, IOS Press, 87–90
Kraft, R. P. 1967, ApJ, 150, 551, doi: 10.1086/149359
Lightkurve Collaboration, Cardoso, J. V. d. M., Hedges, C., et al. 2018, Lightkurve: Kepler and TESS time series analysis in Python., Astrophysics Source Code Library http://ascl.net/1812.013
Lindegren, L., Bastian, U., Biermann, M., et al. 2021, A&A, 649, A4, doi: 10.1051/0004-6361/202039653
Liu, C., Aksu, T., Liu, J., et al. 2025, arXiv e-prints, arXiv:2511.11698, doi: 10.48550/arXiv.2511.11698
Liu, X., Liu, J., Woo, G., et al. 2024, arXiv e-prints, arXiv:2410.10469, doi: 10.48550/arXiv.2410.10469
Liu, Y., Su, X., Wang, S., et al. 2026, arXiv e-prints, arXiv:2603.04791, doi: 10.48550/arXiv.2603.04791
Lomb, N. R. 1976, Ap&SS, 39, 447, doi: 10.1007/BF00648343
Lu, Y., Angus, R., Foreman-Mackey, D., & Hattori, S. 2024, AJ, 167, 159, doi: 10.3847/1538-3881/ad28b9
Magaudda, E., Stelzer, B., Covey, K. R., et al. 2020, A&A, 638, A20, doi: 10.1051/0004-6361/201937408
Mamonova, E., Shan, Y., Kowalski, A. F., Wedemeyer, S., & Werner, S. C. 2025, A&A, 700, A53, doi: 10.1051/0004-6361/202554614
Mathur, S., Claytor, Z. R., Santos, Å. R. G., et al. 2023, ApJ, 952, 131, doi: 10.3847/1538-4357/acd118
Mathur, S., Santos, Å. R. G., Claytor, Z. R., et al. 2025, ApJ, 982, 114, doi: 10.3847/1538-4357/adb8cc
McInnes, L., Healy, J., & Melville, J. 2018, ArXiv e-prints. https://arxiv.org/abs/1802.03426
McInnes, L., Healy, J., Saul, N., & Grossberger, L. 2018a, The Journal of Open Source Software, 3, 861
McInnes, L., Healy, J., Saul, N., & Großberger, L. 2018b, Journal of Open Source Software, 3, 861, doi: 10.21105/joss.00861
McQuillan, A., Mazeh, T., & Aigrain, S. 2013, ApJL, 775, L11, doi: 10.1088/2041-8205/775/1/L11
McQuillan, A., Mazeh, T., & Aigrain, S. 2014, ApJS, 211, 24, doi: 10.1088/0067-0049/211/2/24
Medina, A. A., Winters, J. G., Irwin, J. M., & Charbonneau, D. 2022, ApJ, 935, 104, doi: 10.3847/1538-4357/ac77f9
Messina, S. 2021, A&A, 645, A144, doi: 10.1051/0004-6361/202038739
NASA Exoplanet Science Institute. 2020, Planetary Systems Composite Table., NASA IPAC DataSet, NEA13 doi: 10.26133/NEA13
Newton, E. R., Irwin, J., Charbonneau, D., et al. 2016, ApJ, 821, 93, doi: 10.3847/0004-637X/821/2/93
Newton, E. R., Mondrik, N., Irwin, J., Winters, J. G., & Charbonneau, D. 2018, AJ, 156, 217, doi: 10.3847/1538-3881/aad73b
pandas development team, T. 2025, pandas-dev/pandas: Pandas, v2.3.3 Zenodo, doi: 10.5281/zenodo.17229934
Parker, L., Lanusse, F., Shen, J., et al. 2025, arXiv e-prints, arXiv:2510.17960, doi: 10.48550/arXiv.2510.17960
Pass, E. K., Charbonneau, D., Irwin, J. M., & Winters, J. G. 2022, ApJ, 936, 109, doi: 10.3847/1538-4357/ac7da8
Pass, E. K., Charbonneau, D., Latham, D. W., et al. 2024, ApJ, 966, 231, doi: 10.3847/1538-4357/ad3631
Pass, E. K., Winters, J. G., Charbonneau, D., Irwin, J. M., & Medina, A. A. 2023, AJ, 166, 16, doi: 10.3847/1538-3881/acd6a2
Patil, A. A., Eadie, G. M., Speagle, J. S., & Thomson, D. J. 2024, AJ, 168, 193, doi: 10.3847/1538-3881/ad7029
Pecaut, M. J., & Mamajek, E. E. 2013, ApJS, 208, 9, doi: 10.1088/0067-0049/208/1/9
Perez, F., & Granger, B. E. 2007, Computing in Science and Engineering, 9, 21, doi: 10.1109/MCSE.2007.53
Poznanski, D. 2026, arXiv e-prints, arXiv:2605.05324, doi: 10.48550/arXiv.2605.05324
Rauer, H., Aerts, C., Cabrera, J., et al. 2025, Experimental Astronomy, 59, 26, doi: 10.1007/s10686-025-09985-9
Ricker, G. R., Winn, J. N., Vanderspek, R., et al. 2015, Journal of Astronomical Telescopes, Instruments, and Systems, 1, 014003, doi: 10.1117/1.JATIS.1.1.014003
Ronneberger, O., Fischer, P., & Brox, T. 2015, arXiv e-prints, arXiv:1505.04597, doi: 10.48550/arXiv.1505.04597
Rozet, F., Divo, F., & Schnake, S. 2024, probabilists/zuko: Zuko 1.1.0, 1.1.0 Zenodo, doi: 10.5281/zenodo.10571785
Rozet, F., et al. 2022, Zuko: Normalizing flows in PyTorch, doi: 10.5281/zenodo.7625672
Rumelhart, D. E., Hinton, G. E., & Williams, R. J. 1986, Nature, 323, 533, doi: 10.1038/323533a0
Santos, A. R. G., Breton, S. N., Mathur, S., & García, R. A. 2021, ApJS, 255, 17, doi: 10.3847/1538-4365/ac033f
Santos, A. R. G., García, R. A., Mathur, S., et al. 2019, ApJS, 244, 21, doi: 10.3847/1538-4365/ab3b56
Scargle, J. D. 1982, ApJ, 263, 835, doi: 10.1086/160554
Smith, J. C., Stumpe, M. C., Van Cleve, J. E., et al. 2012, PASP, 124, 1000, doi: 10.1086/667697
Soderblom, D. R. 2010, ARA&A, 48, 581, doi: 10.1146/annurev-astro-081309-130806
Stassun, K. G., Oelkers, R. J., Paegert, M., et al. 2019, AJ, 158, 138, doi: 10.3847/1538-3881/ab3467
Stumpe, M. C., Smith, J. C., Catanzarite, J. H., et al. 2014, PASP, 126, 100, doi: 10.1086/674989
Stumpe, M. C., Smith, J. C., Van Cleve, J. E., et al. 2012, PASP, 124, 985, doi: 10.1086/667698
Tenenbaum, P., & Jenkins, J. M. 2018, TESS Science Data Products Description Document, Tech. Rep. EXP-TESS-ARC-ICD-TM-0014, Rev. D, NASA Ames Research Center
Thomson, D. J. 1982, IEEE Proceedings, 70, 1055, doi: 10.1109/PROC.1982.12433
Tran, A., & Song, I. 2026, arXiv e-prints, arXiv:2602.20402, doi: 10.48550/arXiv.2602.20402
Van Cleve, J. E., Howell, S. B., Smith, J. C., et al. 2016, PASP, 128, 075002, doi: 10.1088/1538-3873/128/965/075002
Van-Lane, P. R., Speagle, J. S., Eadie, G. M., et al. 2025, ApJ, 986, 59, doi: 10.3847/1538-4357/adcd73
Van Rossum, G., & Drake, F. L. 2009, Python 3 Reference Manual (Scotts Valley, CA: CreateSpace)
Virtanen, P., Gommers, R., Oliphant, T. E., et al. 2020, Nature Methods, 17, 261, doi: 10.1038/s41592-019-0686-2
Wagg, T., Broekgaarden, F., Van-Lane, P., Wu, K., & Gültekin, K. 2025, TomWagg/software-citation-station: v1.4, v1.4 Zenodo, doi: 10.5281/zenodo.17654855
Wagg, T., & Broekgaarden, F. S. 2024, arXiv e-prints, arXiv:2406.04405. https://arxiv.org/abs/2406.04405
Wainer, T. M., Zasowski, G., Pepper, J., et al. 2023, AJ, 166, 106, doi: 10.3847/1538-3881/ace960
Wes McKinney. 2010, in Proceedings of the 9th Python in Science Conference, ed. Stéfan van der Walt & Jarrod Millman, 56–61, doi: 10.25080/Majora-92bf1922-00a
Wilson, O. C. 1968, ApJ, 153, 221, doi: 10.1086/149652
Ye, J., Yu, Y., Zhang, W., et al. 2024, arXiv e-prints, arXiv:2405.02358, doi: 10.48550/arXiv.2405.02358
Zimmerman, R., van Dyk, D. A., Kashyap, V. L., & Siemiginowska, A. 2024, MNRAS, 534, 2142, doi: 10.1093/mnras/stae2082
Zuo, X., Tao, Y., Huang, Y., et al. 2026, AJ, 171, 10, doi: 10.3847/1538-3881/ae1467
APPENDIX
A. MODEL PERFORMANCE WITH ADDITIONAL INPUT CHANNELS
We compared out model's ability to recover data both with and without extra input channels. The first extra input channel we considered for each LC is the power spectrum. This is a measure of how much information is contained in the LC at different frequencies. For signals that are strongly periodic at a single frequency, we would expect the power spectrum to have a strong peak at that frequency and smaller values at all other frequencies.
While Lomb-Scargle (LS) periodograms (N. R. Lomb 1976; J. D. Scargle 1982) are often used to compute these power spectra, they can suffer from spectral leakage, particularly in the case of irregularly sampled data. J. D. Scargle (1982) suggested that tapering (reducing the amplitude at the edges of the time series data) can mitigate this spectral leakage and reduce the bias of the power spectrum estimate, but at the cost of increasing the variance. D. J. Thomson (1982) introduced the concept of multitapering, which combines the results from applying multiple orthogonal tapers to the same time series to produce a power spectrum estimate that reduces both bias and variance. A. A. Patil et al. (2024) implement this concept in their tapify code, which we use to compute the power spectrum for each LC in our sample.
To homogenize our data and avoid including the frequencies of our power spectra as input, we re-sampled each power spectrum to a uniform grid of 16,000 frequency bins with a maximum of 360 cycles/day (which approximately corresponds to the Nyquist frequency of 2-minute cadence data. In addition to the power values, tapify provides the f-statistic for each frequency, which is a measure of how periodic the signal is. We combine the power values and the f-statistics in our first extra input channel.
The second extra input channel is the autocorrelation function (ACF) for each LC. We calculated this simply by applying the scipy.fft.ifft method to the re-sampled power spectrum, which provides an “autocorrelation coefficient” over a grid of time offsets . At values that correspond to a strong periodic signal, the amplitude of the coefficient will be large.
We considered both of these channels because they are views of the data in different domains: the PS in the frequency domain and the ACF in the domain. Since RNNs can have difficulty learning patterns over long offsets, these channels could provide helpful additional context.
First, we trained autoencoders and decoders to reconstruct the PS and ACF. This was most successful using a UNet-style (O. Ronneberger et al. 2015) Convolutional Neural Network (CNN) architecture. We then trained two versions EncoTESS with and without these extra channels. They were included by concatenating the PS and ACF encodings into the input for the hidden state computation at each step in the RNN.

Figure 21. Reconstruction of the power spectrum of TIC 67787319 Sector 43. The left panel shows the reconstruction based on the core EncoTESS model, and the right panel shows the reconstruction when PS and ACF channels are included in training. Recovery of some features is marginally improved by including PS and ACF in training, but the overall shape is very similar.


Figure 22. Comparison of age (left) and (right) inference tests using our , compared between the final EncoTESS model and a version that included the PS and ACF encoders in training.
We compared the performance in several ways: (i) the reconstruction loss curve, (ii) ability to recover rotation periods, (iii), ability to recover ages, and (iv) ability to reconstruct the PS and ACFs from the latent space. All models had comparable performance across these tests, indicating that EncoTESS is able to capture the periodicity information from the flux channel equally as well as it can from the PS and ACFs equally well. Therefore it is not worth the extra model complexity and computational expense of including the PS and ACF channels in EncoTESS. Examples of the rotation period and age inference tests, and a random power spectrum reconstruction, are shown in Figures 22 and 21.
B. LOW-DIMENSIONAL ENCODING REPRESENTATIONS
Here we discuss in detail three methods for reducing the dimensionality of the 1536-dim LC encodings .
B.1. UMAP Representation
UMAP learns how objects are clustered in a high dimensional space, and then places them in a lower dimensional space that is optimized to preserve that structure, so it is particularly useful for visualization. The actual values of the UMAP dimensions are not meaningful, so we do not show them any plots, but the relative positions of the LCs reveal important trends. 2-dimensional space is naturally intuitive for visualizations, so we use 2-dim UMAP projections of frequently throughout the rest of this paper, but since it does not capture the intrinsic dimensionality of well we do not use it for quantitative analysis.
B.2. PCA Representation
PCA re-orients a parameter space by iteratively defining axes that align with the directions of greatest variance. In the context of our 1536-dim space, the first principal component (PC1) is a unit vector that maximizes the normalized variance of all projected onto it. The next component PC2 is defined as the unit vector linearly orthogonal to PC1 that maximizes the projected variance of all . PC3 is the unit vector that maximizes the projected variance of while being orthogonal to PC1 and PC2, and subsequent components are defined in the same manner.
This can be done for any number of components up to the dimensionality of the parameter space, but the marginal signal diminishes with each PC added. For example, PC1 explains 44% of the variance in on its own, PCs 2 through 4 explain an additional 28% together, and PCs 5 through 1536 together explain the remaining 28%.
Since PCA is a relatively intuitive way of choosing a low-dimensional representation of , we use it in most of the quantitative analysis in this work. PCA is also flexible; depending on the complexity of the downstream task that uses the number of PCs can be chosen to balance performance with completeness. To this point, in this work we truncate to 4, 8, or 16 PCs for various tasks depending on the context and goal, referred to as , and .
It is also important to note that the number of useful PCs does not necessarily correlate with the intrinsic dimensionality of . While PCA is restricted to a linear basis, TwoNN captures nonlinear dimensionality, meaning that more than 13 PCs would be required to capture the nonlinear 13-dim space described by TwoNN.
B.3. PLS Representation
The PLS representation is constructed using the same procedure as PCA, with one key difference. Instead of constructing axes to maximize the variance of the projected , PLS constructs axes to maximize the covariance of the projected with stellar age .
This means that age information is concentrated by design in the top few PLS components, in contrast to PCA where its unsupervised nature might result in more age information occurring in lower components.
We specifically use the top 3 PLS dimensions for age inference analysis because they are very informative, and overfitting significantly increased at higher dimensions. We tested this by measuring 's correlation with both true ages and fabricated (inaccurate) ages at various dimensions, and found that the correlation with fabricated ages increased significantly past 3 dimensions, indicating that the marginal increase in signal was primarily due to noise.
C. DETAILED MODEL ARCHITECTURE
This Appendix describes the EncoTESS implementation in detail, which we have written with the goal of complete reproducibility. It is divided into four subsections, mirroring the brief descriptions provided in §3:
-
A description of the encoding layers that transform the raw inputs into learned representations.
-
The core RNN framework.
-
The self-supervised training procedure that uses a Conditional Normalizing Flow (CNF) head to predict flux.
-
The aggregation process that constructs the fixed-size latent representation ( ) from LCs.
C.1. Input Encoding
Our inputs for each light curve are the normalized time series channels
and the normalized metadata fields
We encode the timestamps as , where is an 8-dim vector and is an 88-parameter Multilayer Perceptron (MLP) having one 8-dim linear hidden layer with a ReLU activation and an 8-dim linear output layer with no activation. is trained in parallel with the rest of EncoTESS . The purpose of this encoding is to improve EncoTESS's ability to learn periodic and quasi-periodic temporal trends; this is a common encoding strategy (e.g. S. M. Kazemi et al. 2019; C. Donoso-Oliva et al. 2026) so timestamps that are far apart in real time but closer in phase space become closer in the encoding space. This means that each observed data point consists of the 10-dimensional input , so an entire LC with observations is described by a vector of size .
We apply another MLP to process the metadata parameters into a 32-dim vector . has 41,376 parameters and consists of 3 128-dim hidden linear layers with layer normalization, GELU activation and 10% dropout, and a 32-dim linear output layer with no activation. 's first hidden layer has 26 input dimensions, corresponding to the 13 metadata fields and the 13-dim binary mask channel.
MLPs are widely considered the canonical “standard” neural network (D. E. Rumelhart et al. 1986) and are often the building blocks of more complex models.
C.1.1. Metadata Masking
The binary mask channel is used to indicate whether or not a specific metadata parameter is masked out or not, and is applied at two levels. First, a block mask is applied to all metadata based on:
(C3)
meaning that every LC has a 15% chance of having all metadata parameters masked. Then, for stars where that block mask is not applied, field level masking is applied according to:
for each field. Note that is the probability of masking out metadata completely, but is the probability of keeping the field. For stars that pass the block mask, a minimum of one metadata field is kept.
The result of this procedure is that some stars have metadata completely masked from training, and others have varying numbers and combinations of individual metadata fields that are masked. Masking is functionally applied by setting the value of the field to 0 and the value of the corresponding mask channel field to 0. Any metadata fields that are unmasked keep their true value and the corresponding mask channel field is set to 1.
This masking scheme encourages EncoTESS to not over-rely on systematic metadata signatures during training, and the masking is recomputed every batch and every training epoch so that LCs are not masked in the same way every iteration.
When computing for use in downstream age inference, we do not apply any metadata masking since we want to have maximal information.
C.1.2. Light Curve Masking
In addition to metadata masking, we mask a portion of each LC as a way to improve EncoTESS's robustness against data gaps. This also reduces overfitting as EncoTESS sees different portions of the same LC each iteration of training. Practically, we do this by iteratively drawing mask segments of length
which we place at a starting point in the LC drawn from
so that the entire mask fits in the LC. We chose this distribution to prioritize learning short term variability while still being sensitive to offsets up to approximately the size of the largest gaps in TESS LCs.
Masks are generated iteratively for each LC until the total length of masked segments reaches 50% of the LC, and the last mask is truncated so that the total number of masked data points does not exceed 50%. We ignore the effect of overlapping masks, so the typical LC ends up being masked.
Masking is functionally applied by excluding masked points from the hidden state computations described in Appendix C.2. However, those points are still used as prediction targets in the training procedure described in Appendix C.3, since they provide an additional opportunity to train across data gaps.
Similar to the metadata masking, when computing for use in downstream age inference we do not apply any masking to the LCs since we want to have maximal information.
C.2. Recurrent Neural Network Framework
The concept driving RNNs is that time series data can be encoded as “hidden states” , where each represents the state of a process at some measurement after some measurement at time . With this notation, is a state representing some process before any observations, is the state after the first observation, and is the final state after the th observation. In this framework, these hidden states accumulate information as a set of observations is processed sequentially. is derived from initial conditions, is computed from and the 1st observation, is computed from and the 2nd observation, and so on. In this manner, each hidden state holds information about the first observations.
The downside to traditional RNNs is therefore that every must be computed sequentially. We do not provide equations here, but direct the reader to L. Feng et al. (2024), who provide examples for two specific types of RNNs:
Long Short-Term Memory (LSTM) networks (S. Hochreiter & J. Schmidhuber 1997) and Gate Recurrent Unit (GRU) networks (K. Cho et al. 2014). However, they also demonstrated that it is possible to simplify LSTM and GRU networks in a way that allows parallel computation of while achieving performance comparable to transformers and traditional LSTM and GRU networks. Critically, this lets us remove the computational bottleneck of sequential processing, while taking advantage of the other benefits of RNNs as described in §3.2. L. Feng et al. (2024) formalize both LSTM and GRU implementations of this parallel architecture, defined as minLSTM and minGRU models, which they provide example PyTorch implementations for. We use the minGRU implementation directly in EncoTESS, although we tested the minLSTM model as well and performance was comparable. As a benchmark, minGRU provided a speedup in training over sequences of data points compared to the sequential GRU implementation.
Specifically, the computation of hidden states within the minGRU network can be described as:
where J is a 64-dim linear neural layer that transforms the 42-dim input for each point into , b is a 64-dim linear neural layer with a custom activation function defined by L. Feng et al. (2024), and a is a 64-dim linear neural layer with sigmoid activation.
While in this framing there still appears to be a dependency of on , through clever refactoring L. Feng et al. (2024) show that this can be reduced to purely a dependence on , which allows all in a LC to be computed simultaneously. Compressing the above equations, we use the notation
for simplicity, where represents all inputs from to . The exact calculations for the minGRU “cell” can be found in our publicly available code, mirrors the architecture provided by L. Feng et al. (2024). Including the input projection , our minGRU cell is 11,072 parameters.
The result is that we are able to compute a 64-dim corresponding to every point in a LC. contains information from the entire context of the LC up to and including , and also the LC metadata. Therefore through training, these should describe the variability that we see in each LC within the context of the stellar and LC metadata properties. These are therefore the core products of the EncoTESS architecture, and what we use for downstream analysis.
C.2.1. Bidirectionality
While the description of our RNN architecture above has only considered modeling LCs forward through time, we can implement the same procedure for LCs in reverse. This is useful for capturing behavior that is unique in the forwards or backwards direction, which occurs in asymmetric LC features such as flares that typically exhibit an abrupt rise in flux but a smoother decay.
We implement distinct (but architecturally identical) minGRU cells in both the forwards and backwards directions, which we distinguish hereafter in this work as and respectively. There are therefore two different hidden states (the forward and the backward ) computed for every point in the LC:
where now represents all inputs from to and represents all inputs from to . At each point in the LC, we now have a 128-dim hidden state:
that characterizes the variability of both the preceding and following portions of the LC, with the context of the stellar and LC metadata.
Including the input projection J, each minGRU cell is 11,072 parameters, so the total size of our RNN architecture is 22,144 parameters.
C.3. Model Training
As described briefly in §3.3, we train EncoTESS to predict the flux at some time , given both LC and metadata context, the encoded time of prediction , and the measurement error of the prediction . We never want to provide our flux predictor with information on the observation it is predicting, so the maximum LC context we provide is the forward hidden state at the preceding point , and the backward hidden state at the following point . To train EncoTESS to capture longer term patterns, we can extend this concept to arbitrary offsets of the hidden states, and , for up to a practically useful limit.
Additionally, instead of training EncoTESS to predict a discrete flux value with some error, we use a Conditional Normalizing Flow (CNF) which computes a full probabilistic likelihood of the target flux. We do this because individual LC flux measurements are highly noisy, so we do not consider the accuracy of any individual flux prediction as important as successfully predicting the general trends with a well-calibrated likelihood distribution. It also allows complete flexibility in the shape of the flux distribution.
Specifically, we use a 28,974-dim Neural Spline Flow (C. Durkan et al. 2019) with 2 transforms. Each transform consists of a 2 64-dim hidden linear layers with ReLU activation, and a 23-dim linear output layer (corresponding to an 8-bin spline).
Formalizing all of the above, we train the CNF to predict:
The bottom portion of Figure 2 illustrates this architecture. We choose a different offset k for each batch during training, which is drawn from:
is a 2-min offset and is a 4-day offset assuming constant 2-min sampling. We choose this distribution to prioritize learning short term variability while still being sensitive to offsets up to approximately the size of the largest gaps in TESS LCs, similar to the masking strategy described in Appendix C.1.2.
To calculate loss we use the negative log-likelihood (NLL; ) of , at the observed flux. NLL is widely used as a loss metric for non-Gaussian likelihoods, and in such cases is a better representation of the accuracy of than other metrics such as . Conceptually, this is a measure of how well the true observed flux value is aligned with the predicted distribution. Predictions are scored based on the “height” of at the observed value; in other words the density of our predicted flux at that point. Our loss function is therefore:
This is calculated for every unmasked observation, and our training procedure minimizes the average NLL across the observations from all LCs in a batch.
C.4. Computation of LC Encodings
Our goal is to generate a meaningful fixed-size encoding from every LC using EncoTESS. As described above, through training we iteratively optimize our model weights to maximize the LC reconstruction ability of EncoTESS. With the final optimized model, we can compute all hidden states for any LC having L observations, which contain characteristic information about each star is expected to behave. Naively, these could be used directly as , however each is a 128-dim vector that exist for each data point, resulting in a total size of features per LC. This is not practical for characterization or downstream analysis, and we also require a fixed size for our latent representations to be useful. So, we apply an aggregation strategy to try to reduce the encoding size by discarding redundant information while retaining important signal. Specifically, we save the following aggregations for each LC:
-
The maximum, minimum, mean, and standard deviation of each dimension across all in the LC (512-dim).
-
Hidden state at the first and last timestamps: and (256-dim).
-
The mean and standard deviation of the rate of change of each dimension across all , measured using absolute time (256-dim).
-
The mean of each dimension of the hidden states, divided into four sequential bins with equal numbers of observations. This is essentially four versions of #3, where each is calculated over 1/4 of the hidden states (512-dim).
By concatenating these, we obtain a 1536-dim encoding for each LC. These can be thought of as a series of stellar parameters. Although the physical meaning behind each of these numbers is obscured, thoughtful interpretation can help characterize this latent space, which we explore in §5.
D. LATENT SPACE CORNER PLOT
Figure 23 presents a corner plot visualizing the correlations between age and the top 8 PCs in . The intrinsic nonlinear dimensionality of is as measured by TwoNN (see §3.4), and PCA is linear, so therefore it takes > 13 PC components to create a subspace without losing any information. We show the top 8 PCs here simply for ease of visualization.
It is clear that PC1 carries strong age signal, and to a lesser extent PC3. There appears to be relatively strong correlation between PC1/PC3 and PC1/PC5.
There are also distinct clustered subpopulations in PC2 that are not apparent in the other PCs, which could potentially be useful for classification.

Figure 23. Age gradient over the top 8 PCs of . It is apparent that the top component (PC1) carries strong age signal.