Notes

tsfresh

A raw sensor trace is useless to most machine-learning models: a few thousand numbers in a row, with everything interesting buried in their shape. tsfresh fixes that by turning each time series into a single row of descriptive numbers — and then throwing most of them away.

Extract, then select
The library runs in two stages, and the second is what its name points at — Time Series FeatuRe Extraction on the basis of Scalable Hypothesis tests:

  • extract_features computes hundreds of characteristics per series: means, variances, autocorrelations, FFT and wavelet coefficients, peak counts, entropy, trend slopes, stationarity statistics;
  • select_features tests each candidate against the target with an appropriate statistical test and controls the false-discovery rate, keeping only features with evidence behind them;
  • extract_relevant_features performs both steps in one call.

Controlling the cost
The default ComprehensiveFCParameters setting is deliberately exhaustive and slow; EfficientFCParameters drops the expensive calculators and MinimalFCParameters gives a quick first pass. Input arrives in long format with an id column identifying each series, and roll_time_series converts a continuous stream into overlapping windows when you need a prediction per time step rather than per series.

Why it fits the pipeline
Once the series have become feature rows, the problem is a tabular one, so everything downstream works unchanged — gradient-boosted trees, a tabular AutoML tool, plain logistic regression. That makes tsfresh the standard bridge for predictive maintenance, machine-condition monitoring and wearable-signal classification, where the data is a waveform but the model wants a table.

tsfresh is an open-source Python library that automates feature engineering for time series: extract_features computes hundreds of characteristics per series — autocorrelations, spectral coefficients, entropy, trend statistics — and select_features keeps only those with statistically significant relevance to the target, controlling the false-discovery rate. It matters because it converts raw signals into a table that ordinary models and tabular AutoML tools consume directly.

A heart-rate trace or a vibration recording is just a very long list of numbers, and most prediction software can do nothing useful with that.

tsfresh is a tool that reads such a recording and describes it instead: how fast it wobbles, how steadily it rises, how often it spikes, how much it repeats itself. It produces hundreds of these descriptions automatically, then runs a statistical check and discards every one that has no real connection to what you are trying to predict. What is left is a neat table of clues, which ordinary machine-learning tools handle easily. It is a favourite for spotting machines that are about to fail.