Changelog#

This changelog highlights notable updates. For full commit history, refer to GitHub.

Unreleased#

  • Fix EAggloDetector(member=...) for sorted negative or fractional cluster labels that collided during relabelling. Equivalent initial partitions now produce the same segmentation instead of raising ZeroDivisionError.

  • Move the E-Agglo diagnostic and calibration scripts and the SNLDS audit script and results to scripts/diagnostics/. examples/ now contains only the worked gallery examples and their supporting files; detector guides use the updated commands.

  • Clarify the getting-started guide’s constructor-based guidance: passing y does not set change-point or state counts for the illustrated detectors, and DynP still uses a fixed count when n_cps is omitted. Correct the link to the installation guide.

  • Add a Contributor Covenant Code of Conduct, contribution workflow, security policy and support guide, with GitHub issue forms and a pull request template.

  • New online detector FLOSSDetector (FLOSS, Gharghabi et al., ICDM 2017), the online counterpart of FLUSSDetector: it keeps the last sliding_window_size points (10,000 by default), updates their one-directional matrix profile point by point with stumpy.floss, and reports a change point where the one-directional corrected arc curve drops below threshold (0.45 by default), at least exclusion_factor * window_size points after the previous one. Univariate and multivariate (mean of the curves of the channels), unsupervised; needs the fluss extra. FLUSSDetector and its outputs are unchanged.

  • New OnlineF1Score(max_delay=...) metric for online event logs. Matching uses the first detection time in each true change’s half-open deadline interval, bounded by the next change. Returns F1@D, precision, recall, mean/median detection delay, false alarms per 10,000 observed points and mean localization error. Existing metrics and detector outputs are unchanged.

  • SNLDSDetector is now reproducible at a fixed random_state: two fits give the same weights and labels, and two calls to predict on one fitted model give the same labels. The inference network samples the continuous states in a TensorFlow while loop that runs up to ten steps in parallel; with one stateful seed, the steps took their noise draws in a variable order. Each step now samples with a stateless seed derived from one seeded draw per call and the step index, retaining the parallel loop. The non_deterministic tag is now set only when random_state=None. Outputs change (other noise draws from the same distribution), so SNLDS scores need to be recomputed, as they already did after the new training defaults below.

  • Online detection: new base class tsseg.algorithms.base_online.BaseOnlineSegmenter and tag capability:online (False for every existing detector). An online detector ingests a stream with update(X), which returns the change points detected meanwhile as events (position, detection_time, score; append-only log in events_); predict(X) replays the stream on a copy, so batch use, metrics and the generic tests are unchanged. Existing detectors and their outputs are unchanged.

  • New online detector ClaSSDetector (ClaSS, Ermshaus et al., PVLDB 2024), vendored from claspy 0.2.8 (BSD-3-Clause) with the split rule of the authors’ code: a change point within 5 * window_size of the window edge is rejected and the next segment starts at the reported change point (claspy placed a change that had just entered the window early). Univariate, unsupervised, numba required (tsseg[accelerators]). Mean Covering 0.848 on the 75 TSSB series (claspy: 0.838; authors’ code: 0.807). 2024), vendored from claspy 0.2.8 (BSD-3-Clause; same change points and detection times as claspy). Univariate, unsupervised, numba required (tsseg[accelerators]). Mean Covering 0.838 on the 75 TSSB series (authors’ code: 0.807).

  • The accelerators extra and the Conda environment recipe no longer request Cython, which tsseg does not use. Numba and detector behaviour are unchanged. Install Cython explicitly for other packages or manual source builds that require it; existing installations retain it.

  • New online detector ChangeFinderOnlineDetector (ChangeFinder, Takeuchi & Yamanishi, TKDE 2006). Its change point score is that of ChangeFinderDetector, equal at every point and computed as the stream arrives; an alarm is raised when the score crosses a threshold (by default the mean plus two standard deviations of the positive scores seen so far), at least min_distance points (20, the paper’s alarm policy) after the previous one, and the change point is placed at the largest first-stage score among the last smooth_window points. Univariate and multivariate (L2 norm of the channels), unsupervised. ChangeFinderDetector and its outputs are unchanged.

0.5.0 (2026-11-29)#

Upgrading from 0.4.0: outputs change for TireDetector (every domain, including the default domain="both"), TiccDetector (window_size > 1), SNLDSDetector (new training defaults) and FLUSSDetector (its default "ensembling" strategy); earlier scores of these detectors need to be recomputed. Outputs may change for EspressoDetector (three or more chain expansions), for the "ensembling" strategy of BOCDDetector, BeastDetector and ChangeFinderDetector (whose default tolerance is now 1% for BOCD and ChangeFinder), for model="normal" of the ruptures detectors and for LaplacianDetector on duplicate frames or zero bandwidths. The other detectors keep their outputs with their defaults. Active detector constructors are keyword-only: positional calls still work with a FutureWarning for at least one release. New: FLUSSDetector(multivariate_strategy="cac_mean").

  • ESPRESSO’s matrix profile now returns z-normalised Euclidean distances directly. The FFT helper already took their square root; a second root at the self-join return transformed the distances again. Nearest-neighbour indices are unchanged. Semantic densities and change points may change with three or more chain expansions, whose cost budget depends on the distance values; no detection-quality improvement is established.

  • SNLDSDetector has new training defaults: learning_rate=1e-3 (was 1e-4), use_temperature_annealing=False and use_cross_entropy_reg=False (both were True); n_train_steps stays 2,000. This is the regime of the paper’s bouncing ball experiment. Compressed into 2,000 steps, the Reacher schedules kept the learned transitions near uniform, and the labels switched hundreds of times. On the nine bundled MoCap trials (true number of states, three seeds each), the mean ARI goes from 0.078 to 0.171 and the bidirectional covering from 0.035 to 0.203 (better on 26 of 27 fits), with three times fewer label changes and the same fit time. Default outputs change, and earlier SNLDS scores need to be recomputed; the former behaviour is SNLDSDetector(learning_rate=1e-4, use_temperature_annealing=True, use_cross_entropy_reg=True). SNLDS stays experimental: a single MoCap fit of the 27 reaches an ARI of 0.7, and the labels still change about 1,100 times per trial for 5 to 10 true changes.

  • The extras table of the README and of the installation guide now lists every detector that tsseg[accelerators] speeds up: GaussianHMMDetector and the numba backend of PeltDetector, DynpDetector, BinSegDetector, BottomUpDetector, WindowDetector and SeededBinSegDetector were missing. All of them still run without numba.

  • The Gaussian likelihood cost (model="normal" of PeltDetector, DynpDetector, BinSegDetector, BottomUpDetector and WindowDetector) no longer depends on the scale of the series, and its pen_scale="bic" is the BIC penalty. Three defects are fixed: pen_scale="bic" scaled the penalty by the absolute log-determinant of the whole series, which moves with its scale and is close to 0 on z-normalised channels, so white noise was cut at every admissible point; it is now penalty * log(n) * d(d+3)/2, the d means and d(d+1)/2 covariances of one more segment. The covariance ridge was an absolute 1e-6, so on a series of small amplitude it masked the changes; it is now 1e-6 times the mean channel variance of the series. Segments of at most d samples, whose covariance is singular, were admissible and only the ridge set their cost; the cost’s min_size is now max(2, d + 1), which the searches apply at fit (WindowDetector raises NotEnoughPoints when width // 2 is smaller). The segment covariance is the maximum likelihood one (ddof=0) for every dimension, as it already was for one channel. Outputs change for model="normal" only.

  • EspressoDetector now uses MATLAB’s half-away-from-zero rounding for the matrix-profile exclusion radius and compares chain separation with the unrounded quarter-window threshold, as in the original implementation. Outputs may change for some custom window sizes; the default 64 and windows 32 and 128 are unaffected by these corrections.

  • FLUSSDetector accepts multivariate_strategy="cac_mean": the corrected arc curves of the channels are averaged, then the change points are extracted from that mean curve as on a univariate series (at most n_segments - 1 minima below 1, or the minima below threshold with n_segments=None). This is the multivariate FLUSS of Gharghabi et al. (DMKD 2019, section 3.4). profile holds the mean curve; tolerance and consensus are not used. Opt-in: the default ("ensembling") and the other strategies keep their outputs, and univariate series ignore the strategy.

  • TireDetector now expresses its comparison lag, domain-weight distances and both smoothing half-widths as ceil(window_size / stride) window rows. Outputs change for stride > 1: these scales no longer grow with the stride, and fractional score centers are retained during interpolation. Scores at stride=1 are unchanged for comparable window pairs. When no pair can be compared, postprocessing returns zero scores.

  • TireDetector(domain="FD") no longer trains the time domain autoencoder, whose features it discarded. Its outputs change at equal random_state (that training drew from the torch random stream before the frequency domain autoencoder was initialised, so the time domain settings changed the result) and it runs faster. This fix affects domain="FD" only.

  • TireDetector now follows the paper (De Ryck et al. 2021) on three points, so its outputs change in every domain, including the default domain="both", and earlier TIRE scores need to be recomputed:

    • each channel is rescaled to [-1, 1] on the whole series before the windows are cut (§III-B). The time domain autoencoders received the raw values, out of reach of their tanh output on unnormalised data, and channels of larger amplitude weighed more. A constant channel is set to 0. A constant series still gives zero scores and no change point, even with n_segments, now without training the autoencoders (its frequency features were NaN);

    • on multivariate series the frequency domain input is the Fourier transform of the window of each channel, rescaled channel by channel and concatenated (eq. 3). The concatenated windows were transformed with nfft points, which cut them: with the defaults (window_size=20, nfft=30) only the first channel and ten points of the second were seen. Univariate frequency features are unchanged;

    • the shared features are smoothed by the triangular moving average in the "TD" and "FD" domains too, not only in "both" (eq. 11, as in the original code).

  • TiccDetector now trains on every complete window, including the final observations, and uses every window in assignment costs, log-likelihood and BIC. The reference solver truncated the final window_size - 1 windows, padded them with zeros and omitted their costs, which also assigned arbitrary state 0 to the tail with beta=0. Fitted outputs and selected state counts can change when window_size > 1; earlier TICC scores need to be recomputed. Window-start label alignment, the final-label extension, constructor defaults and the unused threshold are retained.

  • Change the default tolerance of ChangeFinderDetector and BOCDDetector from 0 to 0.01 (1% of the series length), as FLUSSDetector and the default margin of F1Score. The tolerance only acts with multivariate_strategy="ensembling": with 0, only identical indices of different channels were grouped, so a change seen a few samples apart by several channels got one vote per channel and a guided run (n_cps or max_cps) kept the earliest change points (channel change points [100, 600], [104, 603] and [350] on 1000 samples with two change points asked for gave [100, 104], now one change point near 100 and one near 600). Without n_cps, ChangeFinder ensembling used min_distance as the tolerance and now uses 1% of the length. Ensembling outputs change and earlier ensembling scores need to be recomputed; the default strategies ("l2" for ChangeFinder, "native" for BOCD) are not affected. An explicit tolerance=0 keeps the previous outputs, and so does a series shorter than 100 samples, where 1% rounds down to 0 samples.

  • LaplacianDetector retains exact-zero mutual-neighbour links with affinity 1 instead of dropping duplicate frames from the recurrence graph. A zero recurrence or path bandwidth uses its positive-bandwidth limit: zero distances get weight 1 and positive distances get weight 0. A path with median squared distance zero previously gave every edge weight 1, including jumps between distinct plateaus. Graphs can now be disconnected and affected outputs can change. The cosine metric, public parameters, positive-bandwidth formulas and state-count selector are unchanged.

  • Fix the fusion of the per-channel change points of multivariate_strategy="ensembling" (BOCDDetector, BeastDetector, FLUSSDetector, ChangeFinderDetector). The change points of all channels were pooled into one list, so several points of a single channel outvoted channels that agree, and points closer than tolerance to the previous one were chained into one cluster returned as its median, possibly an index detected by no channel ([10, 14, 18, 22] on four channels with tolerance=4 gave [16]). Each observed change point is now supported by the channels with a change point within tolerance; change points are taken by decreasing support, then by closeness of the supporting channels, and one within tolerance of a change point already taken is dropped. The number of change points asked for is an upper bound: fewer are returned when the dropped candidates leave too few. consensus_change_points applies the same rule. With tolerance=0 (the default of BOCD, BEAST and ChangeFinder with n_cps) outputs are unchanged; otherwise ensembling outputs change and earlier scores need to be recomputed. The default strategies ("native", "l2") are not affected, except FLUSS, whose default is "ensembling" with tolerance=0.01. aggregate_change_points is unchanged and no longer used by the detectors.

  • Active detector constructors now expose keyword-only parameters with axis: int = 0 last. Existing positional calls retain their original argument binding and emit FutureWarning; compatibility will remain for at least one released version before removal in a future breaking release. AutoPlaitDetector, EAggloDetector, GreedyGaussianDetector, InformationGainDetector and RandomDetector now accept axis at construction. Other parameter names and defaults are unchanged; deprecated detectors retain their signatures.

0.4.0 (2026-11-18)#

Upgrading from 0.3.2: outputs change for BOCDDetector (new defaults: native multivariate Gaussian likelihood and MAP decoding), for BeastDetector on multivariate series, for SNLDSDetector, and for any detector constructed with axis=1; earlier scores of these detectors need to be recomputed. With the default axis=0, the other detectors keep their outputs, except a refit of TSCP2Detector, which no longer reuses the threshold learned on its first series (now in threshold_). GaussianF1Score pairs change points optimally (scores can only increase) and WeightedAdjustedRandIndex may differ slightly on short series; the metrics accept scored_intervals for partially annotated references. Unused helpers of the TIRE, CLaP and E2USD modules are removed without deprecation. New: LaplacianDetector, CachalotDetector and TrendFilteringDetector (extra tsseg[l1tf]).

  • Fix numerical errors in SNLDSDetector: the complete-data score now associates each emission with the destination state, and ELBO/IWAE use the exact log likelihood marginalized over discrete paths instead of omitting their posterior entropy. Gaussian covariance parameters configured as trainable are now tracked by Keras and receive gradients; rnn_type="lstm" now constructs both initial states on Keras 3. Segmentation outputs change. The detector remains experimental. Its documentation separates historical scores from the corrected implementation and explains computational and modelling limitations; a diagnostic script supports small before/after runs.

  • New TrendFilteringDetector: l1 trend filtering (Kim, Koh, Boyd and Gorinevsky, SIAM Review 2009) as a convex-relaxation baseline. On every channel it estimates the piecewise-linear trend that minimises 1/2||y - x||^2 + lambda ||D x||_1 through the dual box-QP of the paper (section 5.2), by OSQP with an exact active-set polish, and reports the kinks of the trend as change points; lambda_max_ (paper, eq. 7) gives the scale of the penalty, above which the estimate is the best affine fit. Multivariate series use the “sum of l1 norms” extension (section 7.5); the group-penalty variant needs a conic solver and is not implemented. Optional dependency: tsseg[l1tf] (OSQP, Apache-2.0).

  • Standardise the Cachalot README and detector guide: clarify the distinction between its total-variation Lasso candidates and the complete algorithm, document time and memory costs, verify references, and remove benchmark scores and implementation history from the overview. The taxonomy’s convex relaxation category also covers candidate generation followed by post-selection, with Cachalot identified as a Lasso / reduced-DP hybrid.

  • EAggloDetector computes the quadratic initial distance loops and candidate-merge scans inside Numba, skips repeated membership scans for default singleton clusters, and evaluates penalties without retaining a Python list for every partition. The statistic and returned segmentation are unchanged. A local 4,000-point, four-channel example took 1.67 s instead of 18.06 s after initial compilation; time and memory remain quadratic. The detector guide and scripts/diagnostics/eagglo_diagnostics.py explain and illustrate the distinct causes of over-segmentation: the inherited ecp statistic, penalty scale, initial partition and serial dependence. A separate MoCap calibration example recommends per-channel z-normalisation, alpha=0.5, blocks of 200 and no penalty: mean BiCovering 0.718 on the nine original trials, against 0.272 with the defaults; leave-one-trial-out parameter selection gives 0.688. The constructor defaults are unchanged, and the profile limits boundary resolution to 200 observations.

  • Fix native BOCD Gaussian evidence for scatter matrices that are diagonal to rounding precision, with channel variances at very different scales. Direct diagonal evaluation preserves their resolved small variances, including when standardize=False.

  • BOCDDetector now defaults to a native multivariate Gaussian likelihood with full covariance and joint maximum a posteriori (MAP) decoding. The likelihood reduces exactly to Normal-Gamma in one dimension. Channels are standardised by default (standardize=False keeps physical prior units); beta=10 and hazard_lambda=1000 were selected on a 15-series pilot with synthetic sanity checks. max_cps constrains the MAP partition to at most that many changes, and min_distance constrains all segment lengths during inference. A regular grid of at most 2,000 interior candidates bounds the search (max_candidates=None uses every position), while every observation still contributes to segment likelihoods. Unconstrained inference uses linear working memory in the series length and candidate count; a count-constrained MAP also stores scores by candidate and change count. Native covariance evaluation uses stable block moments and Cholesky with an eigenvalue fallback for a very small prior ridge. The L2 and per-channel strategies remain available; the final ensemble also respects the minimum spacing. decoding="marginal" retains a probability-based alternative with a default threshold of 0.5 and no truncation (truncate=None). These parameters do not affect MAP decoding. Detection outputs and defaults change; earlier BOCD benchmark results need to be recomputed.

  • Fix BOCDDetector inference: a constant hazard now defines a geometric segment-duration prior, with right censoring of the final segment. Boundary probabilities are marginal events rather than scores normalised to sum to one; the latter imposed an artificial limit of 20 candidates at the default threshold of 0.05. A forward-backward recursion with stable running moments replaces the cubic-time, quadratic-memory ordinal change-point calculation: the detector now uses quadratic worst-case time and linear inference memory, without new dependencies. The Normal-Gamma evidence also includes its missing factor 2**(-n/2), which cancels between full-series segmentations. truncate uses natural logs (exp(truncate)), as the original comparison did; documentation incorrectly said 10**truncate. max_cps=0 skips inference. Detection outputs change; earlier BOCD benchmark scores need to be recomputed.

  • BeastDetector with multivariate_strategy="native" (the default for multivariate series) no longer returns the union of the candidates of its channels. Each channel gives up to the maximum of tcp_minmax (10 by default) and, on real series, most channels give that many, so the number of change points grew with the number of channels. Candidates are now ranked by their support, the probability (cpPr) of the same change summed over the channels, then by their own probability; without max_cps, as many are returned as the median number of candidates of the channels that have any. With max_cps, the most supported are kept. Outputs change on most multivariate series.

  • BeastDetector: a max_cps above the maximum of tcp_minmax (or of scp_minmax, when the seasonal change points are returned) raises that maximum to max_cps. Rbeast never returns more change points per component and channel, so max_cps could not be reached on a univariate series, with "l2", or on any channel. With both changes, on the first 2,000 points of 435 real series from 47 datasets (z-normalised channels, default parameters), "native" without max_cps rises from F1 0.140 to 0.186 and bidirectional covering 0.326 to 0.511 (15 times the true number of change points in the median multivariate series, now 3), and with max_cps set to the true number from 0.384 to 0.403 and 0.681 to 0.698; "l2" with max_cps returned fewer change points than asked on 29 % of the series, now 5 %.

  • BeastDetector with multivariate_strategy="native" (the default) runs beast123 on one channel at a time. Given the whole array, Rbeast 0.1.25 fits its columns independently, in threads pinned to CPUs 0, 1, … whatever CPUs the process may use. In a process that may not use these CPUs (a job of a cluster scheduler that allots it other CPUs, a container limited to some CPUs), the threads were not created: Rbeast returned unset outputs, hence no change point or wrong ones on every multivariate series, and corrupted the memory, which killed the process later (segmentation fault). Where the threads were created, the change points can differ from before: Rbeast fits a column of a 2D array and a single series with different routines (beastv2_COREV4_mthrd.c and beastv2_COREV4.c), whose outputs differ at the same seed; "native" now uses the routine of univariate series and of "ensembling" everywhere. The channels are now fitted one after the other, not in parallel, and a multivariate series of two points gets no change point without a call to Rbeast.

  • Metrics on partially annotated references: F1Score, Covering, BidirectionalCovering and the six state detection metrics take a keyword-only scored_intervals, the half-open intervals of the points to score, and the new tsseg.metrics.scored_islands derives them from a label sequence (for example the runs that are not -1). The series keeps its length: ARI, AMI and NMI score the scored points; WARI and WNMI measure their distance weights inside each interval, its edges included, before leaving out the other points; SMS fits one mapping on the scored points, stops error segments at the edges of the intervals and divides its losses by the number of scored points (masked SMS); F1 judges only the change points inside an interval and never matches across a gap; Covering and BiC clip segments to the intervals. Without the argument, or with one interval covering the series, the scores are unchanged. The boundary distances of WARI and WNMI are now computed without a loop over the points (same values), which makes them usable on series of a million points.

  • New LaplacianDetector (state detection, unsupervised or guided): the Laplacian structural decomposition of McFee & Ellis (ISMIR 2014) applied to windows of a series. Frames are linked to their mutual nearest neighbours (recurrence) and to their neighbours in time (path), and k-means on the smallest eigenvectors of the normalised Laplacian gives the states. Unlike the librosa example and msaf, the filtered recurrence matrix is symmetrised, so that the matrix decomposed is a graph Laplacian. Without n_states, the number of states is the geometric mean of the number of Louvain communities of the recurrence graph and of the best silhouette. The recurrence, the diagonal median filter and Louvain are ported from librosa (ISC) and NetworkX (BSD-3), which are not dependencies. With the true number of states, mean SMS 0.717 on the 592 series of TSB-SEG, against 0.692 for CLaP.

  • WeightedAdjustedRandIndex uses the weighted pair counts as real numbers, as its definition does, instead of truncating them to integers (a step inherited from the scikit-learn ARI, whose counts are integers). The truncation shifted scores on short series (0.2005 instead of 0.2012 on 20 points, up to about 5e-4 on 50 points) and is invisible at three decimals beyond about 200 points. Labelings that agree up to a renaming of the states score exactly 1.0 at any length, a case now read from the contingency table: on series of a few hundred thousand points, the truncated counts could give 1 ± 2e-16. WARI scores of short series computed with 0.3.2 or earlier may differ slightly from this version.

  • GaussianF1Score pairs predicted and true change points by an optimal assignment, which maximises the total reward (scipy.optimize.linear_sum_assignment), instead of taking the largest rewards first. The greedy pairing could fall short of the best total when change points are less than a few widths apart: with sigma = 4, true [100, 104] and predicted [103, 107] earned 1.19 instead of 1.51. Scores can only increase, since a greedy total never exceeds the optimal one, and they differ noticeably only where several change points lie within a few widths of each other. Gaussian F1 scores computed with 0.3.2 or earlier may be slightly lower than with this version.

  • New CachalotDetector: Lasso-path candidates refined by reduced dynamic programming and selected by relative residual improvement (Harchaoui and Lévy-Leduc, 2007). Multivariate input is handled channel by channel, with the returned change points formed by their union. The structured path costs O(n K) per channel without dense matrices; reduced DP costs O(K^3). Endpoint decisions are invariant to signal units, constant decimal-valued signals produce no candidates, and nu must be finite. Documentation records the limits of the channel union and the unresolved gap with the paper’s Monte Carlo precision.

  • Documentation: new design (PyData Sphinx theme, light and dark modes, copy buttons on code blocks) and a new home page; installation instructions move to their own page. The docs extra now installs pydata-sphinx-theme and sphinx-copybutton instead of sphinx-rtd-theme.

  • Documentation: new interactive taxonomy of the detectors, placed by search procedure and homogeneity criterion as in TSB-SEG, with search, filters (task, guided or unsupervised, multivariate, optional extra, deep learning), a sortable list and a link to each detector page; each detector page links back to its place in the grid. The capabilities shown are read from the estimator tags, and the build fails when a public detector is missing from the taxonomy.

  • Documentation: the evaluation page illustrates each metric with a figure on a small example, whose scores are computed by the metrics at build time. Metric pages and signatures show the class name alone (F1Score, not tsseg.metrics.F1Score).

  • Documentation: ClaSP (change point detection) and CLaP (state detection) get a page each, under their task, and the sidebar of the detector pages groups the detectors by task. Change point detection is shown in blue, in the taxonomy too. The home page shows the overview figure of the README and keeps three highlights. Em dashes are replaced by en dashes.

  • Documentation: new examples section, eight worked examples on public data (Jekyll and Hyde, storm surge at The Battery, a chloroplast genome, expressions in climate research titles, human activities in the bundled motion-capture data, the British generation mix, returning speakers and sleep stages). Each one uses a single detector (PELT, CLaP, TICC or HDP-HSMM), checks the result against a reference never used for fitting, and provides a figure, data and code. The examples run offline from examples/gallery in a source checkout and are not installed with the package.

  • Documentation and README: a new figure for the interactive demo (assets/demo.svg) replaces the screenshot assets/demo.png: the sample dataset of the demo, its ground truth, the change points of BottomUp and the states of Time2State, each scored against the truth.

  • Fix axis=1 given to a detector’s constructor: Foo(axis=1).fit(X) on a series of shape (n_channels, n_timepoints) now segments it as Foo().fit(X.T) does. The base class handed such a detector its series in that layout, which almost every detector reads as (n_timepoints, n_channels): BOCD, BottomUp, ChangeFinder, ChangeForest, ClaSP, CLaP, Dynp, GaussianHMM, ICID, PELT, Prophet, SeededBinSeg, SNLDS and SST returned wrong change points or labels without an error, while FLUSS, RuLSIF, TGLAD, TICC, TS-CP2 and Window raised one; a 1D series became a single time point with n channels. The default axis=0 and fit(X, axis=1) are unchanged. _fit and _predict now always receive (n_timepoints, n_channels): a detector that subclasses BaseSegmenter must not transpose its input itself, and AMOC, BinSeg, E2USD, ESPRESSO, HDP-HSMM, Hidalgo, Time2State and TIRE no longer do.

  • The test of BeastDetector on a 6,000-point series no longer expects a failure on CPUs that support AVX-512: in continuous integration, Rbeast returned NaN for every output on that series in 10 of 177 test jobs, all on such CPUs, and the rerun with its SSE routines found the change point every time. The BEAST page says so.

  • Fix the affiliation of John Paparrizos (The Ohio State University and Aristotle University of Thessaloniki) in the README, CITATION.cff and the home page.

  • Helpers that nothing in the package calls are removed, without deprecation (none is part of tsseg.algorithms): parameters_to_cps, cp_to_timestamps, tpr_fpr and minmaxscale of tsseg.algorithms.tire.utils, with commented-out plotting code; roll_array, normalize_time_series, create_sliding_window, expand_label_sequence, collapse_label_sequence and extract_cps of tsseg.algorithms.clap.utils; and E2USD.online_threshold_cluster of tsseg.algorithms.e2usd.e2usd. Three of them did not work: roll_array returned uninitialised memory, normalize_time_series raised NameError and online_threshold_cluster raised AttributeError. Use tsseg.algorithms.utils.extract_cps instead of the removed extract_cps of CLaP; it gives the same change points. The detectors are unchanged.

  • TSCP2Detector stores the similarity threshold it learns in the new fitted attribute threshold_ instead of writing it into the similarity_threshold parameter. With similarity_threshold=None (the default) and no n_cps, a second fit on another series, a clone of a fitted detector and a refit by refit_on_predict after two fits reused the threshold learned on the first series, so they could return other change points than a new detector. A single fit followed by predict is unchanged.

0.3.2 (2026-11-05)#

Upgrading from 0.3.1: ClaspDetector, ClapDetector and TGLADDetector now segment a series passed to predict that differs from the one given to fit, with a warning, instead of returning the output of the fitted series; results on the fitted series are unchanged. Python 3.13 and 3.14 are supported, and tsseg[tscp2] accepts TensorFlow 2.19 and later. New: SSTDetector.

  • New SSTDetector: singular spectrum transformation (Idé and Inoue, SDM 2005; Idé and Tsuda, SDM 2007), with the fast randomised SVD of Weber and Lenz (IEEE Access, 2025). The score compares the leading future direction of a Hankel matrix with the dominant subspace of the past one, which captures changes of dynamics (frequency, autocorrelation) as well as of level; method="exact" uses a full SVD. Guided only (n_cps highest peaks); multivariate series share one subspace. Default window (200), rank (3) and peak spacing calibrated in guided mode on the change-point datasets of TSB-SEG. Written from the papers.

  • ClaspDetector.predict(X), ClapDetector.predict(X) and TGLADDetector.predict(X) segment or label X when it is not the series given to fit. They returned the output of the fitted series whatever X: its change points or labels on another series of the same length, and on a shorter series change points beyond its end (ClaspDetector, TGLADDetector) or as many labels as the fitted series has time points (ClapDetector). A new series is segmented or labelled with a new fit, with a warning, and the fitted attributes are left unchanged, as in EAggloDetector, HidalgoDetector and TiccDetector; fit_predict and predict on the fitted series are unchanged.

  • Python 3.13 and 3.14 are supported, and tested by the CI. tsseg[tscp2] no longer caps TensorFlow below 2.19, which has no wheel for Python 3.13 or later, so pip install "tsseg[all]" works on Python 3.13 (Google Colab, for instance); TSCP2Detector runs with TensorFlow 2.21 and Keras 3. It excludes keras-tcn 3.5.7, which requires tensorflow-macos on every platform. On Python 3.14, tsseg[all] leaves out tsseg[tscp2] and tsseg[snlds]: TensorFlow has no stable release for it yet, nor tf-keras any release. On Python 3.13 and later, Rbeast 0.1.25 prints Exception ignored in PyObject_HasAttrString() messages at each call of BeastDetector; its change points are unaffected.

0.3.1 (2026-11-02)#

Upgrading from 0.3.0: several fixes change the output of TSCP2Detector, Time2StateDetector and E2USDDetector (last points of the series), ChangeFinderDetector, ClaspDetector and ClapDetector given a number of change points, FLUSSDetector with n_segments, TireDetector with stride > 1, BeastDetector, and GreedyGaussianDetector on multivariate series: results computed with 0.3.0 can differ. New defaults: TGLADDetector trains for 2000 epochs, and TiccDetector chooses its number of states when n_states is not given. AutoPlaitDetector no longer needs a C binary (it uses numba, tsseg[accelerators]); HidalgoDetector takes keyword arguments only; get_fitted_params of six detectors returns their fitted attributes; tsseg.TGLADDetector is deprecated in favour of tsseg.algorithms.TGLADDetector. New: SeededBinSegDetector and the tsseg[fluss] extra.

  • AmocDetector, BeastDetector, BinSegDetector, EspressoDetector, FLUSSDetector and HdpHsmmDetector no longer redefine get_fitted_params: they now use the method of the base class, like every other detector. Their versions did not accept deep (get_fitted_params(deep=False) raised a TypeError), did not raise NotFittedError before fit, and returned something else than the fitted attributes: hyperparameters (BinSegDetector, EspressoDetector, BeastDetector), the change points of the last predict under a change_points key (AmocDetector, EspressoDetector), {"profile": ...} or an AttributeError before predict (FLUSSDetector), and an empty dict (HdpHsmmDetector, which now lists log_likelihood_). The hyperparameters stay available through get_params and the change points as the output of predict. The generic detector tests now check get_fitted_params before and after fit.

  • BeastDetector with multivariate_strategy="native", the default for multivariate series, now passes its prior to beast123: tcp_minmax, torder_minmax and tseg_minlength and, when season is not "none", scp_minmax, sorder_minmax and sseg_minlength. They were ignored, and Rbeast used its own defaults: tcp_minmax=(0, 0) still gave a change point on a two-channel step series, where "l2", "ensembling" and univariate series gave none. With season="none" (the default) and the default trend prior, the output is unchanged (Rbeast’s defaults are the same). With a seasonal component, the seasonal defaults of the detector now apply instead of Rbeast’s (at most 5 seasonal change points, harmonic orders from 1 to period / 2 - 1), which can change the output.

  • BeastDetector with multivariate_strategy="native" (the default for multivariate series) returns once a change found by two channels one or two points apart, and max_cps keeps the most probable change points. Rbeast keeps the change points of one channel a minimum distance apart (tseg_minlength; by default 3 points, or half the period with a seasonal component): two candidates of different channels closer than this distance are now taken as the same change, and the more probable one is returned. Two channels changing at t=500 and t=501 gave [500, 501] and now give one change point. max_cps kept the first candidates by position: on two channels with a weak mean shift at t=150 and a strong one at t=400, max_cps=1 returned [152]. Candidates are now ranked by their probability in Rbeast’s ranked list (cpPr; the largest one for a time step found on several channels), and max_cps=1 returns [400]. tolerance, which applied to "ensembling" only, now also drops a native candidate, of any channel, within tolerance time steps of a more probable one. The default output changes: on 96 random step series of two or three channels, the output changed for 49 series (459 change points returned for 243 true ones, now 383), and the F1 score (margin of 15 points) went from 0.707 to 0.778; with max_cps set to the true number of change points, from 0.670 to 0.953; with tolerance=5, 0.816 and 0.964. Univariate series and the "l2" and "ensembling" strategies are unchanged.

  • HausdorffDistance.compute accepts n_timepoints, and HausdorffDistance(convert_labels_to_segments=True) converts label sequences to change points, like the other change-point metrics. Passing n_timepoints raised a TypeError, and convert_labels_to_segments was stored but ignored: the distance was then computed between the label values themselves (1 instead of 400 for true change points 300 and 700 and a predicted one at 300). With either argument, only the change points inside the series are compared, without the boundaries 0 and n_timepoints, as in ruptures.metrics.hausdorff. Without them, the two lists are compared as they are given, as before.

  • PeltDetector().fit(X).get_fitted_params() no longer raises. Read before predict, change_points_ raised a RuntimeError, which get_fitted_params does not skip, and hasattr(detector, "change_points_") raised it too. The error is now also an AttributeError: until predict, get_fitted_params leaves change_points_ out and hasattr returns False. Code that catches the RuntimeError is unaffected.

  • The tsseg.algorithms.tsfm sub-package is no longer shipped. It only re-exported the detectors of an optional package that is not on PyPI, so it could not be used after installing tsseg: importing it emitted an ImportWarning and exported nothing. It was not documented, not tested and not listed in tsseg.algorithms.__all__. A new test checks that every library the package imports is installed by a dependency or an extra.

  • TSCP2Detector returns one change point per peak of its change score. A change point lowers the similarity of every window pair centred less than one window from it, and the detector returned either the centres of the n_cps most dissimilar pairs, with no minimum spacing, or every centre below the similarity threshold: often several neighbouring centres for one change point. On a series of 1,000 points with change points at 300 and 700, after the default 100 epochs, n_cps=2 gave [333, 348] and found only one of the two for 4 seeds out of 5; the automatic threshold gave 18 to 44 change points. The centres are now taken by decreasing change score, skipping any centre less than one window (window_size, or the shorter window that fit trains on for a short series) from a change point already kept. With n_cps, closer centres still complete the set when the series is too short for n_cps spaced ones. The outputs of both modes change; the encoder and its training do not.

  • Time2StateDetector and E2USDDetector refuse in fit, with a ValueError, the parameters their encoder cannot run: an odd window_size (accepted by fit, it made predict fail after the training), kernel_size=1 for Time2State and a kernel_size above min(window_size, 64) for E2USD (both failed in fit with a RuntimeError from PyTorch).

  • Time2StateDetector and E2USDDetector label a constant series as one state. When the variance of the series was exactly zero, as for np.zeros(n), the z-normalisation divided by zero and predict raised ValueError: Input X contains NaN; a constant series whose variance is a rounding error, as for np.full(n, 0.1), already got one state. A series of zero variance is now only centred. The other series are normalised as before.

  • TGLADDetector now trains uGLAD for 2000 epochs per batch by default, as the authors’ code does, instead of 100. After 100 epochs, the soft threshold that GLAD learns could set every partial correlation to zero, and the detector then found no change point, as on a two-channel series with two clear mean shifts and on the first three MoCap trials with the default window_size; after 2000 epochs it finds 21, 37 and 34 change points on these trials, for 6, 9 and 8 true ones. Training takes about 20 times longer; pass epochs=100 for the previous behaviour. The documentation now also says that the windows around one transition can each give a change point, and that on a univariate series the summary of a window, the precision of its single channel (a fallback that is not in the authors’ code), does not follow the variance of the signal, as the docstring said: uGLAD min-max scales each window first.

  • TGLADDetector prints nothing with verbose=False, its default. The vendored uGLAD solver printed three lines on stdout for each batch of windows (“Running uGLAD in multi-task mode”, “Processing the input table for basic compatibility check”, “Total runtime: …”) whatever verbose said; with verbose=True they are still printed, with the loss every tenth of the epochs. epochs below 10, which the parameter schema accepts, raised ZeroDivisionError at fit: the solver printed the loss every int(epochs / 10) epochs, which is 0 below 10 epochs; it now prints it every epoch there.

  • Importing TGLADDetector no longer issues SyntaxWarning: invalid escape sequence '\T' on Python 3.12 (a DeprecationWarning before 3.12, an error in a future version). The warning came from a docstring of the vendored uGLAD solver and was shown whenever Python compiled that module at import, as on the first import from an editable install (pip precompiles the modules of a regular install and hides the warning); that docstring is now a raw string. A new test compiles every module of the package and fails on any compile-time warning.

  • clone(random_state=k) seeds the clone. The seed was ignored: clone only called a set_random_state method that no detector defines, so the clone kept the random_state of the original. As in aeon, the random_state parameter of the clone is now set to an integer drawn from check_random_state(k), the same for the same k; k may also be a numpy.random.RandomState. clone() without a seed, and detectors without a random_state parameter, are unchanged.

  • clone() copies the parameters, as scikit-learn’s clone (used by aeon) does. The clone received the parameter objects themselves, so a mutable parameter (a list such as ICIDDetector(psi_list=...), a dict, an array, a RandomState) was shared: changing it in place, or drawing from the generator, also changed the original. Estimators passed as parameters, also inside a dict, list or tuple, are now cloned unfitted, and clone(random_state=k) also seeds their random_state, in aeon’s order. A constructor that converts a parameter is still accepted, unlike scikit-learn’s clone.

  • import tsseg no longer puts a fake numpy.core.umath_tests module, with only an inner1d function, in sys.modules. It was left from a dependency that tsseg no longer has, and any other package of the program that imported numpy.core.umath_tests got the fake module.

  • import tsseg no longer imports the detectors: tsseg.algorithms is imported on first access, so import tsseg takes about a fifth of the time it took, and tsseg.algorithms.PeltDetector still works after it. tsseg.np, tsseg.sys, tsseg.types and tsseg.umath_tests, left by the imports of the package, are gone.

  • tsseg.TGLADDetector is deprecated (FutureWarning) and no longer in tsseg.__all__, so from tsseg import * gives load_mocap only. It is the same class as tsseg.algorithms.TGLADDetector, where all the detectors are; import it from there.

  • Time2StateDetector and E2USDDetector change their output at the end of the series. Each window votes for its state on the points it covers, and the last (n_timepoints - window_size) % step points, which no window covers, got state 0 whatever the state around them, as in the code both detectors wrap: 16 of 630 points with window_size=64 and step=50. These points now take the state of the last window. The other points keep their state.

  • Licences: Time2StateDetector and E2USDDetector ship code from projects that their licence files did not name. The causal CNN encoder and the Dataset class of time2state.py come from the code of Franceschi, Dieuleveut and Jaggi (2019), under the Apache License 2.0, and partly from locuslab/TCN, under the MIT License; e2usd.py holds the same Dataset class and the moving_avg and series_decomp blocks of Autoformer, under the MIT License. The LICENSE file of tsseg/algorithms/time2state now holds these licences, the NOTICE of Franceschi et al. and the changes made to their code, and a new LICENSE file in tsseg/algorithms/e2usd does the same for the two parts of E2USD (the rest of E2USD still has no published licence). The code is unchanged.

  • Licences: GreedyGaussianDetector is adapted from aeon (aeon.segmentation._ggs), whose code is adapted from cvxgrp/GGS, but tsseg/algorithms/ggs/LICENSE held only the BSD 2-Clause licence of cvxgrp/GGS, and the README of the directory and of tsseg named only cvxgrp/GGS. The LICENSE file now holds aeon’s BSD 3-Clause licence too, and the READMEs, the detector page and the module docstring name both sources. The code is unchanged.

  • Docs: the Hidalgo page, README and docstring say what the detector does not separate. It tells states apart by their intrinsic dimension only, from distance ratios that location and scale leave unchanged, without the time order: states that differ in mean or variance but have the same dimension are not separated. Spatially separated regions of the same dimension are distinct in the model, but the Gibbs chain is slow to split them; the paper runs \(10^5\) iterations from 10 random starts, the detector 1000 from one by default. The detector is unchanged.

  • Docs: the Time2State page, README and docstring say that window_size sets the time resolution. Each window gets one state, and the encoder does not always embed a window that straddles a change point next to the segment that covers more of it, so the window should be well below the length of the shortest segment (the authors’ experiments use 128 to 512 points). On a 1000-point series of segments of 300 to 400 points, only 5 of the 15 windows of the default 256 points lie inside a single segment, and the adjusted Rand index is 0.22 to 0.40 with the true number of states; labelling each window with the segment that covers most of it would give 0.96, and window_size=32, step=32 gives 0.90 to 0.95. The docstring also says that the encoder is never trained on the last window_size - 3 points, as in the reference implementation. The detector is unchanged.

  • The documentation of TiccDetector now describes what the detector computes: the window of time point t holds the points t to t + window_size - 1, the last window_size - 1 observations enter no window, threshold has no effect and beta is twice the \(\beta\) of the paper. Every public member of tsseg.algorithms.ticc.ticc has a NumPy docstring. The detector is unchanged.

  • TiccDetector with n_states given raises a ValueError that names the cause when a state cannot get the two windows it needs to estimate its covariance: when the series has fewer than 2 * n_states windows (n_timepoints - window_size + 1), or when the initial Gaussian mixture gives a state fewer than two windows, as it can to a few outlying windows. fit raised a bare KeyError such as KeyError: (2, 1), or the ValueError of scikit-learn’s Gaussian mixture when the series had fewer windows than states. With n_states=None, such a number of states still gets an infinite BIC; labels are unchanged.

  • The documentation of Time2StateDetector now describes what the detector computes and where it fails: batch_size has no effect, window_size must be even, kernel_size must be at least 2, random_state does not seed the clustering of predict, and a constant series makes predict raise. Every public member of tsseg.algorithms.time2state.time2state has a docstring; wrong ones are corrected (the final flag of CausalConvolutionBlock adds the last activation, reduced_size of CausalCNNEncoder is a number of channels, the encoder outputs two-dimensional tensors). The README of the detector attributed the method to the wrong authors and venue; it now cites Wang, Wu, Zhou and Cai, Proc. ACM Manag. Data 1(1), 2023.

  • The documentation of E2USDDetector now describes what the detector computes and where it fails: batch_size and depth have no effect, window_size must be even, kernel_size can be at most min(window_size, 64), the convolutions of the encoder keep their random initial weights, random_state does not seed the clustering of predict, a constant series makes predict raise, and y is ignored (the docstring of fit said it set the number of states). Every public member of tsseg.algorithms.e2usd.e2usd has a docstring. The README of the detector credited “Chen, Zhichen and others”; it and the documentation page now cite Lai, Li, Zhang, Zhao, Qian and Jensen, WWW 2024, pp. 3010-3021.

  • Docs: the E2USD page, README and docstring say that window_size sets the time resolution. Each window gets one state, and the encoder can embed a window that straddles a change point next to either of the two segments, so the window should be well below the length of the shortest segment (the authors’ experiments use 128 to 512 points). On a 1000-point series of segments of 300 to 400 points, only 5 of the 15 windows of the default 256 points lie inside a single segment, and the adjusted Rand index is 0.28 to 0.52 with the true number of states; 0.83 to 0.95 with window_size=32, step=32. The detector is unchanged.

  • The documentation of BeastDetector now says that a fixed mcmc_seed reproduces the output on one machine only: Rbeast picks its numerical routines by CPU instruction set, and their rounding differences change the MCMC samples. It also says that, on some machines, Rbeast returned NaN for every output on a 6,000-point series, so that the detector returned no change point. The test of that series, which failed on such machines, now expects this failure on CPUs that support AVX-512.

  • BeastDetector reruns Rbeast once with its SSE routines (cputype="sse") when the median number of change points (ncp_median) of a run is NaN in every component and every channel, and raises a RuntimeWarning. On some machines, Rbeast returned NaN for every output on a 6,000-point series, and the detector returned no change point. Other runs are unchanged; a failed run costs a second, slower one (1.5 to 2 times as long on an AVX2 CPU). If the rerun returns NaN too, the detector still returns no change point.

  • BeastDetector returns no change point for a univariate series of two points, as it already did for a single point. Rbeast refuses an input of fewer than three values, and predict raised SystemError: <built-in function Rbeast> returned a result with an exception set; the "l2" and "ensembling" strategies failed in the same way on a two-point multivariate series.

  • GreedyGaussianDetector no longer depends on the level of a multivariate series. Its split search started the running mean of the left part from the first sample divided by the number of channels, a line taken from the reference implementation of GGS, so every candidate split was scored with a wrong left covariance: on three segments of two channels, k_max=2 found [150, 250], and only [250] once 10 was added to the series. Each split is now scored by the regularised log-likelihood of the paper, the one log_likelihood computes. Multivariate outputs change; univariate outputs, where the two starts agree, do not.

  • GreedyGaussianDetector(lamb=0) is refused by fit on a multivariate series. Without regularisation, the covariance of a segment with no more points than channels is singular, and the split search scores segments of two points: predict raised LinAlgError: Matrix is not positive definite on every multivariate series tried (120 of 120 with two to four channels and the default k_max). The paper assumes \(\lambda > 0\). On a univariate series, lamb=0 still runs; if repeated values make a segment’s variance zero, the LinAlgError now says to use lamb > 0.

  • Every detector can be imported without its optional dependencies, so from tsseg.algorithms import * and hasattr(tsseg.algorithms, name) work after a bare pip install tsseg. Seven detectors (ClapDetector, ClaspDetector, EAggloDetector, E2USDDetector, Time2StateDetector, TireDetector, ProphetDetector) raised ModuleNotFoundError: No module named 'numba' (or 'torch', 'prophet') on import, which made the star import fail. The dependencies listed in a detector’s python_dependencies tag are now checked once, when it is constructed, as in aeon; a missing one raises ModuleNotFoundError with the extra to install, the same way for all fourteen detectors with optional dependencies, e.g. ClapDetector requires numba, aeon: pip install "tsseg[accelerators,aeon]". Before, some failed only at fit (AutoPlaitDetector, SNLDSDetector, BeastDetector, ChangeForestDetector) and some without naming the extra. Accessing tsseg.algorithms.TireDetector (or E2USD, Time2State) no longer imports torch, and import tsseg.algorithms no longer imports stumpy: they are imported when a detector that needs them is constructed or fitted. Outputs do not change.

  • The wheel and the source distribution now include the license of the PaTSS code, tsseg/algorithms/patss/LICENCE, which the package-data patterns (**/LICENSE) left out. MATLAB data files (*.mat) are no longer selected as package data; none is left in the package.

  • New extra tsseg[fluss], which installs stumpy for FLUSSDetector; tsseg[all] now includes it. stumpy was declared nowhere, so pip install "tsseg[all]" left FLUSSDetector unusable. The CI installs the extra, so the tests of FLUSSDetector, which it skipped, now run there; the extras table of the documentation lists it.

  • tsseg no longer depends on future, which nothing imports, and the dev extra no longer installs black: the code is formatted with ruff format.

  • tsseg/algorithms/base.py, whose base classes are adapted from aeon, now opens with aeon’s BSD 3-Clause license, which asks redistributed source code to keep it. The README said that this license covered the file, but neither the file nor its directory held a copy.

  • ChangeFinderDetector(n_cps=k) returns k change points. When fewer than k peaks of the score passed the threshold, it returned only those ([306] for n_cps=2 on a series with two changes): the step meant to relax the threshold went over the same thresholded peaks and added none. The local maxima below the threshold now complete the selection, by decreasing score, min_distance apart; fewer than k change points remain possible only when the score has fewer such maxima. Guided outputs change when the threshold kept fewer than k peaks, including per channel with multivariate_strategy="ensembling"; outputs without n_cps do not change.

  • New SeededBinSegDetector: seeded binary segmentation (Kovács, Bühlmann, Li and Munk, 2023), written from the paper. Best split of every interval of a deterministic, near-linear collection, then greedy or narrowest-over-threshold selection; number of change points from n_cps, a penalty on the gain, or the strengthened Schwarz information criterion. intervals="wild" gives wild binary segmentation (Fryzlewicz, 2014). Any ruptures cost; "l2" is the CUSUM of the papers. For a multivariate series, "l2" with the criterion or n_cps first divides each channel by its noise level (median absolute deviation of its differences), so that the result does not depend on the scale of each channel. augment=True adds the optional augmentation of wild binary segmentation to the greedy selection. With intervals="wild" and no random_state, the detector is tagged non_deterministic.

  • Add a CITATION.cff file, read by GitHub’s Cite this repository button, and the citation of the TSB-SEG benchmark (NeurIPS 2026) to the README.

  • HidalgoDetector takes its arguments by keyword only and has a last parameter axis (default 0): HidalgoDetector(axis=1) reads series of shape (n_channels, n_timepoints). A positional call such as HidalgoDetector("euclidean") now raises a TypeError; fit(X, axis=1) works as before.

  • Installation from source no longer needs conda. make install creates a virtual environment in .venv with the venv module and installs tsseg in it, editable, with the all and dev extras (options EXTRAS, VENV, VENV_PYTHON, and TORCH_INDEX_URL to take torch from another index, such as its CPU build). The conda environment tsseg-env is now created by make install-conda (which installs EXTRAS too, hence dev besides all) and removed by make clean-conda; make clean removes .venv only. The README, the documentation home page and the getting started and contributing guides give the venv + pip steps first, and say that tsseg[all] needs Python 3.10 to 3.12 (the TensorFlow versions pinned by tsseg[tscp2] have no wheel for 3.13 or later).

  • EspressoDetector(random_state=...) seeds the matrix profile: the seed was stored but never passed on, so every call drew a fresh random order of the subsequences. That order decides which nearest neighbour is kept when distances tie, which happens on exactly repeated patterns; there, the change points changed from one run to the next whatever the seed. A fixed seed now gives the same change points at every run.

  • Docs: the ESPRESSO page described the method wrongly. It said that the matrix profile is computed with stumpy (tsseg computes it in NumPy and never imports stumpy for ESPRESSO) and that the peaks of the density curve are the change points (its minima are candidates, among which a greedy information-gain search picks n_segments - 1), and called the code new while it translates the authors’ MATLAB code. It now describes the four steps, the bounds of window_size and the published reference (Proc. ACM IMWUT).

  • ClapDetector accepts the classifiers and merge scores that CLaP implements: classifier in {"rocket", "mrhydra", "weasel", "quant", "rdst", "proximityforest", "freshprince", "inception"} and merge_score in {"cgain", "f1_score", "log_loss", "ami", "hamming_loss", "roc_auc"}. Since 0.1.1 its parameter check refused all of them but "rocket" and "cgain", so classifier="mrhydra" (the Fixed configuration of CLaP in TSB-SEG) raised ValueError; it allowed "knn", "svm" and "score", which failed later, in fit, and are now refused upfront.

  • ClapDetector(change_points=...) (known change points) works: an array was refused by the parameter check and a list failed in fit (AttributeError). Lists, tuples and arrays are accepted.

  • ClaspDetector accepts score="f1", which ClaSP implements and documents; the parameter check refused it.

  • ClaspDetector and ClapDetector in guided mode (n_change_points, or an integer n_segments) return the number of change points they are given, fewer only when the segments are too short to split further. ClaSP validated each candidate in this mode too, as claspy does, so a count could give fewer change points, or none: on a series of mean shifts in noise, n_change_points=2 gave no change point and ClapDetector a single state. The validation now applies only when the number is learned (n_segments="learn", the default), and validation and threshold of ClaspDetector have no effect in guided mode. Guided results change; unsupervised results do not.

  • ClapDetector has a distance parameter, passed to ClaSP: "znormed_euclidean_distance" (default, unchanged), "euclidean_distance" or "cinvariant_euclidean_distance", as in ClaspDetector. The z-normalised default compares the shapes of the windows and misses a change of level alone, such as a mean shift in noise.

  • Docs: ClapDetector(random_state=...) seeds the classifiers of CLaP only; ClaSP keeps the fixed seed of claspy (2357).

  • Guided mode on a series without any change point: TSCP2Detector(n_cps=0), BOCDDetector(max_cps=0), BeastDetector(max_cps=0) and GreedyGaussianDetector(k_max=0) return no change point; their parameter check refused 0 (ValueError). BOCDDetector also checked max_cps only after selecting a change point, so max_cps=0 alone would still have returned one on univariate series and with the "l2" strategy.

  • FLUSSDetector with n_segments set returns its change points sorted, as the change point detection output requires. On one channel or with multivariate_strategy="l2" and three segments or more, they came in the order in which stumpy.fluss extracts them (lowest corrected arc curve first), for example [3278, 1600] on MoCap trial 0. The change points and their scores are unchanged, only their order.

  • FLUSSDetector with n_segments set no longer returns 0 as a change point. Once the corrected arc curve left after the exclusion zones of the change points found is flat (1 everywhere), stumpy.fluss takes its minimum at index 0 for each change point still to find: [0, 681] on 1000 points of white noise (window_size=50, three segments), 0 repeated when n_segments asks for more change points than the exclusion zones leave room for. These are dropped, so fewer than n_segments - 1 change points can come out; on one channel or with multivariate_strategy="l2", the others are unchanged. With "ensembling", the channels no longer vote for 0, and the change points they agree on can change. n_segments=1 returns an empty array instead of an empty list.

  • FLUSSDetector has a new parameter normalize (default True, passed to stumpy.stump). The default keeps the z-normalized matrix profile of the FLUSS paper, to which a change in mean or scale alone is invisible; normalize=False compares the raw subsequences, so shifts in level show ([293, 692] instead of [485, 739] for change points at 300 and 700 of white noise with three means). Without n_segments, it needs a lower threshold than the default 0.5. Outputs with the default are unchanged.

  • BinSegDetector and BottomUpDetector: penalty defaults to None, which means 10 when neither n_cps nor epsilon is given. With the former default of 10, n_cps=k alone always warned that the penalty was ignored, and epsilon alone raised ValueError (it needed penalty=None). The change points are the same in every case that was accepted before; penalty=None alone now means a penalty of 10 instead of raising ValueError.

  • Docs: the BinSeg page listed an "ar" cost model, which the parameter check refuses, and omitted "cosine", which it accepts.

  • Docs: the BottomUp and vendored ruptures pages state that BottomUp has the speed-up of ruptures v1.1.9 (PR #309), which tsseg has shipped since its first release; they said v1.1.8 only. On 100,000 points, the Python backend segments in 2 s instead of 15 s for the v1.1.8 code, with the same change points.

  • Docs: the docstrings of ClaspDetector, EspressoDetector, FLUSSDetector, HMMDetector, InformationGainDetector, RandomDetector, TireDetector and TSCP2Detector document every constructor parameter. EspressoDetector documented subsequence_length instead of window_size, and InformationGainDetector a change_points_ attribute that is never set. The FLUSS, HMM and IGTS examples use tsseg instead of aeon. Now documented: RandomDetector ignores n_change_points and n_states unless semi_supervised=True.

  • TireDetector with stride > 1 returns time point indices. It returned window indices (with stride=4, the three changes of a 600-point series at 150, 300 and 450 came out at 42, 76 and 113), and change_scores_ had one value per window instead of one per time point, so peak_distance_fraction was counted in windows. The scores are now placed midway between the two compared windows and interpolated to every time point; stride=1, the default, gives the same output as before.

  • TireDetector(n_segments=1) returns no change point; it selected the peaks by prominence_threshold, as without n_segments.

  • Docs: the contributing guide names the six modules of the generic detector test suite (it listed four), states the change-point output they check (strictly increasing indices in [1, N - 1]) and the extras the CI installs; tests/README.md describes the current helpers of tests/algorithms/conftest.py.

  • AutoPlaitDetector no longer needs a C binary: the C code of Matsubara et al. (version of June 18, 2014) is translated to Python and compiled with numba (tsseg[accelerators]), random draws included. It returns the segmentation of the binary built with GCC on Linux (same segments, same total cost on the 9 MoCap trials of load_mocap, the 7 demo series of the C code and 38 series of ActRecTut, HAS, PUMP, SKAB, TSSB, USC-HAD and UTSA) and runs 2 to 8 times faster. Series of more than 15 channels, which the binary read as a longer series (ValueError since 0.3.0), are segmented; a constant channel is set to zero instead of yielding NaN values. c/autoplait/, the runner tsseg.algorithms.autoplait.autoplait_c and the AUTOPLAIT_DIR variable are removed. AutoPlaitDetector gains the n_regimes_ and cost_ attributes.

  • TiccDetector runs without n_states: with n_states=None, the new default (it was 5), the number of states is chosen by the Bayesian information criterion among 1, ..., max_states (new parameter, default 8), as the TICC paper recommends. The criterion counts the free entries of each block Toeplitz precision matrix, the means and the switches, and divides the log-likelihood of the overlapping windows by window_size (see the docstring); the attributes n_states_ and bic_ report the choice. The detector is tagged capability:unsupervised. Pass n_states=5 to keep the former behaviour.

  • The TICC solver returns the same labels two to five times faster: it runs in the calling process when num_proc=1 (it always started a process pool), its ADMM Z-update and its assignment step are vectorised, and it no longer computes, at each iteration, a k-means clustering and confusion matrices that it did not use. It no longer reseeds NumPy’s global random generator nor changes the print options of NumPy and pandas.

  • EAggloDetector.predict(X) segments X when it is not the series given to fit. It compared the pandas index only, so on another series of the same length it returned the change points of the fitted series; a shorter series was completed with the end of the fitted series before being segmented. A new series is segmented alone, with a warning as before, and the fitted attributes are left unchanged; fit_predict and predict on the fitted series are unchanged. With member, a series of another length raises a ValueError that says so (a longer one failed in pandas, a shorter one was completed).

  • HidalgoDetector.predict(X) labels X when it is not the series given to fit. It returned the labels of the fitted series whatever X, so as many labels as the fitted series has time points. A new series is labelled with a new fit, with a warning, and the fitted attributes are left unchanged; fit_predict and predict on the fitted series are unchanged. The docstring now says that time points whose most probable state has a posterior probability below 0.8 are labelled -1.

  • The pages of IGTS, TS-CP2, PaTSS and SNLDS give their time complexity, so every detector page now does. The SNLDS page said that a training step costs \(O(B\,L\,K^{2})\); \(K^{2}\) is only the forward-backward recursion, and the discrete transition network costs \(O(K^{4})\) per time step.

  • E2USDDetector.predict and fit_predict write nothing to the standard output. Since 0.1.0 they printed the shape of the array of windows, for example (17, 1, 32), on every call.

  • TSCP2Detector leaves window_size unchanged on a short series. On a series of exactly 2 * window_size points, fit halved window_size in place and printed a warning to the standard output: get_params returned the halved value, and a later fit of the same instance on a longer series kept it. fit now trains on the halved window with a UserWarning; its change points are unchanged. predict on a series shorter than two windows of fit raises a ValueError that says so: it failed inside the encoder and left the detector unusable for every later predict. predict on a series of exactly two windows scores its single window pair instead of failing.

  • PatssDetector(config=...) leaves the dictionary it is given unchanged: predict completed it in place with every missing default, so get_params()["config"] changed after the first predict, and the sections it added were the module-level default dictionaries themselves (editing them changed the defaults of every later run).

  • PatssDetector with config={"segmentation": {"algorithm": "k_means"}} returns one state label per time point; it returned a single integer.

  • The PaTSS page lists the keys that config takes, with their defaults: the keys it cited (pattern_length, min_frequency, max_overlap, n_segments) do not exist, so its custom configuration example had no effect. It describes the three steps as the code runs them and gives the reference of the paper (SDM 2024).

  • PatssDetector writes nothing to the standard output; it printed the temporary directory of every window size it tried.

  • BeastDetector no longer fails with ValueError: cannot convert float NaN to integer when Rbeast returns NaN for the median number of change points (ncp_median), as it did in CI on a 6,000-point series. It warns (RuntimeWarning) and keeps the change points above cp_prob_threshold without capping their number; if every Rbeast output is NaN, it returns no change point.

  • The iCID, tGLAD and TIRE pages said “Origin: new code.” They now say where the code comes from: a translation of the authors’ MATLAB code (iCID, GPLv3), a wrapper around the uGLAD solver vendored from the authors’ repository under a non-commercial licence (tGLAD), and a PyTorch reimplementation of the authors’ TensorFlow code (TIRE). The threshold of TGLADDetector applies to the absolute second difference of the sum of partial correlations, not to a Frobenius distance as the page, the README and the docstring said. The iCID page and README give the right title and authors of the JAIR paper, and the tGLAD README cites the paper of its authors.

  • Docs: the Prophet page, README and docstring said that a level shift shows as two opposite rate changes on consecutive candidates. Prophet fits it as a steep ramp, a run of rate changes of one sign before the shift and a run of the opposite sign after it, which can be wider than tolerance: one shift can then give two change points and leave a smaller shift out of the n_changepoints returned. The detector is unchanged.

  • SNLDSDetector seeds its initial weights with random_state. Keras 3 draws the seed of an initializer created without one from Python’s random module, which the detector did not seed: two fits with the same random_state started from different weights, and fit consumed the caller’s random stream. On a series of three segments with clear mean shifts, two runs with the default parameters gave adjusted Rand indices of 0.52 and 0.92. Training still differs from run to run, even with tf.config.experimental.enable_op_determinism(): the documentation now says so, with what it does to the result on that series, where it said that only a few labels could differ between two calls.

  • BeastDetector with max_cps and component="season" or "both" keeps the most probable change points of the returned components. On a univariate series (and with the "l2" and "ensembling" strategies), it ranked every candidate, seasonal ones included, by the occurrence probability of the trend: on a periodic series whose amplitude changes three times, the last change being the largest, max_cps=1 kept another candidate than this change for 6 of 8 seeds with "season" and for all 8 with "both". Each candidate is now ranked by the occurrence probability of component at its time step (the larger of the trend and seasonal ones with "both"), and the largest change is kept, within 2 points, for the 8 seeds. Outputs with component="trend" (the default), without max_cps, or with the "native" strategy are unchanged.

  • Docs: the BEAST page and the docstring of season say that, with a seasonal model ("harmonic", "dummy" or "svd"), Rbeast 0.1.25 can kill the Python process (abort on a double free, or segmentation fault) instead of raising an error, as a direct call to Rbeast does. Whether a call crashes depends on the length of the series, the period and the values: for instance "dummy" with period=2 on 3 to 5 points, or with period=12 on 200 points of white noise. The page shows how to run each call in a child process so that a crash does not stop the caller. The detector is unchanged.

  • TiccDetector.predict(X) labels X when it is not the series given to fit. It returned the labels of the fitted series whatever X: the labels of another series on a series of the same length, and as many labels as the fitted series has time points on a series of another length. A new series is labelled with a new fit, with a warning, and the fitted attributes are left unchanged, as in EAggloDetector and HidalgoDetector; fit_predict and predict on the fitted series are unchanged.

0.3.0 (2026-10-14)#

Upgrading from 0.2.0: VQTSSDetector, VSAXDetector and the HDP-HSMM aliases are removed; GreedyGaussianDetector returns change points instead of labels; the arguments of SNLDSDetector are keyword-only; ProphetDetector, and ChangeFinderDetector without n_cps, select change points differently by default; BeastDetector needs Rbeast from PyPI (tsseg[beast]); the supervision and dependency tags of several detectors change. KCPDDetector, HMMDetector, PatssDetector and the n_cps parameter of AutoPlaitDetector are deprecated. Several fixes change the output of AutoPlait, BEAST, IGTS, Window and the vendored ruptures solvers (ties): results computed with 0.2.0 can differ.

  • New detector ChangeForestDetector: classifier-based nonparametric change point detection with random forests (Londschien, Bühlmann and Kovács, JMLR 2023). It wraps the official changeforest package, installed with the new extra pip install tsseg[changeforest]. With n_cps it runs best-first binary segmentation on the package’s gains, a semi-supervised mode that is not part of the paper.

  • New RuLSIFDetector (Liu, Yamada, Collier and Sugiyama, Neural Networks 2013): change points are peaks of the symmetrised relative Pearson divergence between the subsequences before and after each point, estimated by RuLSIF with cross-validated kernel width and regularisation. NumPy port of the authors’ MATLAB code (MIT); guided (n_cps) or thresholded.

  • TSCP2Detector takes a random_state seed (None by default, as before): with an integer, every fit initialises the encoder, shuffles the training windows and draws the dropout masks identically, so two fits on the same series return the same change points. Without a seed, the weights and the shuffling changed at every fit, and nothing declared the detector non-deterministic. The seed goes through tf.keras.utils.set_random_seed, which also reseeds the global Python, NumPy and TensorFlow generators.

  • Dependencies: tqdm and joblib are no longer required. No module of tsseg imports them since the unfinished Python port of AutoPlait was removed (joblib remains installed with scikit-learn). fetch_dataset shows a download progress bar only when tqdm is installed.

  • Tags: the undocumented semi_supervised tag of AmocDetector, EspressoDetector and RandomDetector is removed: capability:semi_supervised is the tag (the semi_supervised parameter of RandomDetector is unchanged). The deprecated HMMDetector, neither unsupervised nor semi-supervised, declares capability:semi_supervised: its number of states is the length of emission_funcs. A contract test rejects unknown tags and checks that every detector declares both supervision tags, at least one of them True.

  • Tags: python_dependencies is None or a list of the optional modules a detector imports. ProphetDetector, TGLADDetector and TireDetector declared a string ("torch,networkx"), and eight detectors declared nothing; they now declare ["numba", "aeon"] (ClapDetector), ["numba"] (ClaspDetector, EAggloDetector), ["torch"] (E2USDDetector, Time2StateDetector), ["stumpy"] (FLUSSDetector), ["npbad"] (PatssDetector) and ["Rbeast"] (BeastDetector). A contract test checks the format and that the tag lists the modules the test suite skips a detector on.

  • make test and make docs run the test and documentation jobs of the CI (pytest --tb=short -q; sphinx -W -E -b html docs docs/_build/html). PYTEST_ARGS selects tests, DOCS_BUILD_DIR changes the output directory, PYTHON the interpreter.

  • Reproduction tests: tests that reproduce a published result on a dataset downloaded on demand (pinned by its SHA-256 digest) go to tests/reproduction/ and are marked reproduction. The marker is deselected by default (pytest -m reproduction runs them); the protocol is in tests/reproduction/README.md.

  • GreedyGaussianDetector returns the change point indices, as its returns_dense=True tag and its documentation announce: it returned one segment label per time point (0, ..., 0, 1, ..., 1, ...) since 0.2.0, which code reading the output as change point indices misinterpreted.

  • EAggloDetector returns a numpy integer array instead of a Python list, and the deprecated HMMDetector returns integer labels instead of floats.

  • InformationGainDetector stops its search when every candidate position (the multiples of step) is already a change point, and then returns fewer than k_max change points: when k_max exceeded the number of candidates (ceil(n / step) - 1), it returned -1 and 0 among the change points, for instance [-1, 0, 5, 10, 15, 20, 25] for k_max=10, step=5 on 30 points. The other change points are unchanged.

  • Code that no module of the package imports is removed: an unfinished Python port of AutoPlait, older BOCD and TIRE scripts, the former IGTS implementation, a MATLAB-engine wrapper of ESPRESSO, PaTSS scripts that import a baselines package foreign to tsseg, and the MATLAB reference sources of ESPRESSO and iCID. The wheel no longer ships these modules nor the four data files of the MATLAB sources (two .mat files of the iCID demo, two .txt notes of ESPRESSO). The deprecated aliases HdpHsmmDetectorV1, HdpHsmmLegacyDetector and LegacyHdpHsmmDetector of tsseg.algorithms.hdp_hsmm are removed: use HdpHsmmDetector.

  • AutoPlaitDetector returns the segmentation that the AutoPlait binary writes: each time point gets the number of its regime, so that segments of the same regime share a label, and change points are the first index of a segment. The wrapper read the change points one index early (the last index of the previous segment), took the labels of segment.labels (one row per regime, whose second column is the regime’s path in the split tree) and applied them to the segments in time order, padding with the last one: on regimes A-B-A it returned 1 | 0 | 0 with a single change point. It now raises RuntimeError when the binary’s segments do not cover each time point exactly once.

  • AutoPlaitDetector is tagged unsupervised (capability:unsupervised True, capability:semi_supervised False), as the AutoPlait binary always ran: it chooses the number of segments itself and has no guided mode. It runs without n_cps and without y; it raised ValueError when both were missing. n_cps is deprecated and ignored: passing it, 0 included, emits a FutureWarning at fit and no longer launches the binary once with a number of segments that it rejected. The output does not change.

  • AutoPlaitDetector hands the AutoPlait binary a series that it reads with the right length. The binary counts the time points of its input with a line buffer of 254 bytes, and the wrapper wrote 25 characters per value (%.18e): rows of 10 channels or more were counted twice or more, and the binary segmented a longer series padded with rows of zeros (62,442 time points instead of 31,392 on ActRecTut subject 1), whose last segment ended past the series. Values are now written as float32 with 9 significant digits, the precision at which the binary reads them, so that series of up to 15 channels always fit. A series whose rows still do not fit (the 76 channels of JIGSAWS) raises ValueError before the binary runs, and a binary that reports another length than the series’ raises RuntimeError. Series of fewer than 10 channels were not affected.

  • The AutoPlait runner (AutoPlait._run_autoplait in tsseg.algorithms.autoplait.autoplait_c) runs the binary once, with the command line of the bundled binary (autoplait d list_file out_dir), and raises RuntimeError if it fails. It no longer takes n_cps, nor tries a command line with n_cps + 1 or with the length of the series: the only binary that takes a second argument, the modified version of the FLOSS project page, reads it as a minimum number of regimes, not of segments. The documentation now points to the original C code of Matsubara et al., which c/autoplait/ holds, instead of the FLOSS page. AutoPlaitDetector returns the same output.

  • The output contract tests check what the documentation states: change points are a 1-D integer numpy array, strictly increasing, within [1, n - 1]; state labels are a 1-D integer numpy array of length n. They accepted 0, duplicates and float labels.

  • Guided mode on a series without any change point: ClaspDetector (n_change_points=0 or n_segments=1), ClapDetector (n_change_points=0), EspressoDetector (n_segments=1), Time2StateDetector, E2USDDetector and TiccDetector (n_states=1) accept the value and return no change point (a single state); their parameter validation rejected it.

  • AmocDetector computes the error of every split from cumulative sums, in linear time: it recomputed both means at every split (quadratic time). The detected change point is the same.

  • fit and fit_predict reject a y given as a pandas.DataFrame that does not have exactly one column, as the error message states: a frame with two columns (or none) was accepted.

  • ChangeFinderDetector without n_cps: the data-driven threshold is mean + threshold_factor * std of the scores (threshold_factor, 2.0 by default as before), the minimum distance between change points can be a fraction of the length (min_distance_fraction), and the ensembling strategy merges the detections of the channels that lie within the tolerance (by default the minimum distance) and can require a share of the channels to agree (consensus, 0 by default); it returned every distinct peak of every channel. The l2 strategy and the behaviour with n_cps are unchanged by default.

  • FLUSSDetector accepts n_segments=None (number of segments unknown): the regime extraction keeps the minima of the corrected arc curve below threshold (0.5), and the ensembling strategy merges the detections of the channels within tolerance (consensus, the share of the channels that must agree, is 0 by default). A known n_segments behaves as before.

  • New helper tsseg.algorithms.utils.consensus_change_points: change points detected by enough channels, without a target count.

  • Documentation matches the code: the tag list of the detectors page (returns_dense is True for change point indices; guided mode is the capability:semi_supervised tag), the getting-started guide (examples that run without optional dependencies, guided mode through constructor parameters, real test commands), the datasets page (one bundled dataset, no test fixture to import), the extras table, change point examples that named their output labels, and the citation (Springer proceedings).

  • Docstrings: PeltDetector, BottomUpDetector, WindowDetector, DynpDetector and KCPDDetector document their parameters; BinSegDetector states its actual penalty default (10; pass penalty=None to stop on epsilon); the HidalgoDetector example runs with tsseg instead of aeon, and its K_states default is 1; the ICIDDetector psi_list default is None. The compute methods of the state detection metrics and the validate methods of the parameter constraints are documented. A test checks that each detector documents exactly its constructor parameters, with their actual defaults.

  • EAggloDetector: penalty="mean_diff_penalty" no longer raises (the penalty was compiled with numba, which rejects the list of segment boundaries it receives). The documentation now describes the goodness-of-fit statistic, the V-statistics and the merge of the first and last clusters inherited from ecp, and the over-segmentation obtained from one cluster per time point.

  • ClaspDetector runs when NUMBA_NUM_THREADS is below the number of cores (as set by users or by SLURM jobs): n_jobs=-1 meant os.cpu_count() threads, more than numba accepts, which raised ValueError: The number of threads must be between 1 and .... n_jobs=-1 now means all the threads numba may use, and a larger n_jobs is capped at that number.

  • TireDetector: the minimum distance between two change points is peak_distance_fraction times the series length, as documented; the default is 0 (no constraint). The prominence threshold of the unsupervised mode is the prominence_threshold parameter, 0.5 by default.

  • Removed VQTSSDetector and VSAXDetector, two methods developed for tsseg without a publication. On a 54-series sample of TSB-SEG, VSAX scored below a random segmentation (bidirectional covering 0.351 against 0.377, ARI 0.163 against 0.208), and VQTSS returned one vector-quantisation code per time step rather than a segmentation (ARI 0.001), with more than 10 minutes per series beyond 2,500 points. Both labelled local patterns rather than regimes. Code that imports them must drop them; they remain in the history of the repository and in tsseg 0.2.0.

  • ProphetDetector now places n_candidates evenly spaced candidates, fits Prophet’s rate changes delta and returns the n_changepoints largest |delta| relative to their median, or, when n_changepoints is None (the new default), those above delta_threshold (a relative form of TCPDBench’s rule), at least tolerance apart. New parameters n_candidates, changepoint_prior_scale (500 by default, calibrated on TSB-SEG), delta_threshold, seasonality (off by default) and max_points (longer series are reduced to block means before the fit); n_changepoints now accepts 0; multivariate_strategy defaults to "l2", and "ensembling" averages the per-channel scores instead of voting.

  • The vendored ruptures solvers have a numba backend for the l1, l2, rbf and cosine costs, with the same segmentation as the Python path: backend="auto" (the default) picks it when numba is installed, "numba" and "python" force either path, in PeltDetector, DynpDetector, BinSegDetector, BottomUpDetector, WindowDetector and KCPDDetector. The kernel costs no longer build the n x n Gram matrix (for PELT and DynP, a transcription of the C solvers of ruptures’ KernelCPD); DynP no longer memoises O((n / jump)^2) sub-problems; BinSeg finds the best split of a segment in one sweep from each end.

  • SNLDSDetector is now shipped with the package. It was listed in tsseg.algorithms without its module, so from tsseg.algorithms import * failed on the 0.2.0 wheel. The authors’ TensorFlow code (Google Research, Apache-2.0) is vendored in tsseg/algorithms/snlds/vendor; install the dependencies with pip install tsseg[snlds]. Its constructor is now keyword-only, and its tags declare it semi-supervised (n_states is the number of regimes) rather than unsupervised. The wheel now also ships the LICENSE files of the vendored code.

  • CostRbf: the median heuristic no longer counts the distance of a sample to itself, whose rounding residues shifted gamma by about 1e-4, and no longer builds the Gram matrix.

  • Ties: every vendored solver treats values closer than 1e-9 of the costs involved (at least of the signal’s cost per sample, tie_unit) as equal, and decides between them by position as upstream decides between exactly equal values: earliest change point (PELT, DynP), last change point of a segment and first segment (BinSeg), leftmost merge (BottomUp), no peak on a plateau and latest tied peak first (Window); a value tied with pen or epsilon stops, and PELT keeps a start tied with its pruning bound (pruning less never loses the optimum).

  • PatssDetector is deprecated (FutureWarning) and will be removed in a future release: it needs npbad, which is not on PyPI, and over-segments (17 times more change points than the ground truth on a 54-series sample of TSB-SEG). The authors maintain PaTSEmb, which needs Java.

  • WindowDetector searches its peaks as ruptures does (argrelmax(mode="wrap")): the vendored peak search cut the neighbourhood of a score at the ends of the signal, and could add a change point next to the first or last window.

  • The vendored ruptures costs convert the signal to float64 in fit: float32 signals were costed in float32, and CostCosine failed on integers.

  • BeastDetector uses the Rbeast package from PyPI, version 0.1.25 or later (new extra tsseg[beast]), instead of the copy of Rbeast 0.1.15 vendored in c/Rbeast, which never returned on univariate series longer than about 4,600 points. Change points were one sample late (Rbeast counts time from 1); they are now the index of the first sample of the new segment. mcmc_seed defaults to 1: with 0, Rbeast draws a random seed and the output changed from one call to the next.

  • Third-party licenses: bocd/, ticc/, time2state/ and the aeon-derived eagglo/, hidalgo/, hmm/ and igts/ now ship a copy of their upstream license, in the source tree and the wheel. The code adapted in bocd/ is under the MIT license, not Apache-2.0 as documented. The README lists BeastDetector’s dependency Rbeast, under the license of its R package (GPL >= 2), and no longer claims that every vendored directory contains a license file.

  • pen_scale="bic" in PeltDetector, BinSegDetector, BottomUpDetector and WindowDetector: the penalty is a coefficient on log(n) * u, u the cost of one sample of the whole signal (d for l2 on unit-variance channels, where it is the BIC penalty; the mean absolute deviation for l1; 1 for the kernel costs), so that one value applies across lengths, dimensions and costs.

  • New GaussianHMMDetector: a hidden Markov model with diagonal Gaussian emissions, fitted by Baum-Welch (EM) from k-means initialisations and decoded by Viterbi. The number of states is given (n_states) or chosen by BIC. HMMDetector, which only decoded with user-supplied parameters, is deprecated (FutureWarning).

  • BinSegDetector, BottomUpDetector and WindowDetector accept n_cps=0 again (no change point), as DynpDetector and KCPDDetector do: the parameter schema required n_cps >= 1, which failed the semi-supervised runs on series without change points.

  • SNLDSDetector follows the training schedules of the paper: the temperature of the discrete transitions and the weight of the cross-entropy regulariser start at 1,000 (temperature_init, xent_init) and decay as in the Reacher experiment, scaled to n_train_steps. Before, both stayed inactive (temperature 1, weight 1e-10). Training draws batch_size windows of train_window points per step (new parameter, default 256; None for the whole series), so a step no longer runs over the whole series, and the defaults are batch_size=8 and n_train_steps=2000. Prediction is compiled, about 100 times faster on MoCap. The detector declares a parameter schema and the non_deterministic tag, and no longer reseeds NumPy’s global generator. SNLDS is documented as experimental: on a sample of TSB-SEG it scores below a random segmentation.

  • KCPDDetector is deprecated (FutureWarning): it is PeltDetector or DynpDetector with a kernel cost (model="rbf", "cosine", or "l2" for the linear kernel).

  • PatssDetector runs with scikit-learn 1.8, which removed LogisticRegression(multi_class=...) and raised a TypeError: the one-vs-rest elastic-net logistic regression of PaTSS is now OneVsRestClassifier(LogisticRegression(...)), the same model (predicted probabilities equal to 1e-15 under scikit-learn 1.6).

  • F1Score gives 1.0 when neither the ground truth nor the prediction has a change point and the series length is read from y_true: F1Score().compute([n], []) gave 0.0, because the empty prediction was rejected before the boundaries were set aside (compute([n], [n]) and compute([n], [], n_timepoints=n) already gave 1.0). Scores computed from labels (convert_labels_to_segments=True) are unchanged. The warning about a margin rounded to 0 samples is only emitted when change points are matched.

  • F1Score, Covering, BidirectionalCovering and GaussianF1Score accept the series length in compute(y_true, y_pred, n_timepoints=n); the change points may then include or omit 0 and n, so the raw output of a detector can be scored directly. Without n_timepoints (and without convert_labels_to_segments=True), the length is still read from the change points, scores are unchanged, and a UserWarning now says so: a y_true that does not end with the series length silently lost its last change point (F1Score(margin=5).compute([300, 700], [300]) gives 1.0; with n_timepoints=1000, 0.667).

  • Detector pages give the time complexity of 18 more detectors, as implemented with their default settings. Two values were wrong: PELT is \(O(C\,n)\) expected and \(O(C\,n^{2})\) at worst, with no factor in the number of change points (the page said \(O(C\,K\,n)\)), and ChangeFinder solves one \(k \times k\) system per sample, so \(O(d\,n + n\,k^{3})\) (the page said \(O(n\,k^{2})\)).

  • The tGLAD page gives the default of epochs (100; it said 2000) and explains why the paper reports \(O(n)\) where the page states \(O(d^{3}\,n)\) per epoch. The TGLADDetector docstring links to the authors’ repository (Harshs27/tGLAD).

0.2.0 (2026-09-26)#

  • Replaced the NumPy HdpHsmmDetector with a corrected sampler equivalent to pyhsmm’s WeakLimitHDPHSMM (auxiliary self-transitions of Johnson & Willsky, right-censored last segment, chain started from the prior, numba forward messages) and calibrated defaults.

  • numba is optional again, as tsseg[accelerators] announces: ClapDetector, ClaspDetector and EAggloDetector are imported lazily (they need numba), and HdpHsmmDetector falls back to interpreted code without it.

  • EAggloDetector and GreedyGaussianDetector declare returns_dense=True, consistent with their change point output.

  • KCPDDetector: decimation parameter, pen_scale="bic" (penalty as a coefficient on log(n) * d), and n_cps=0 accepted.

0.1.1 (2026-04-20)#

  • Added BeastDetector and ChangeFinderDetector.

  • InformationGainDetector (IGTS) extended to univariate series, with the optimisation of the paper.

  • Parameter schemas for all detectors; GF1 score exposed.

  • Fixes to GLAD, Hidalgo and VSAX; continuous integration (lint, tests, docs).

0.1.0 (2026-02-10)#

Initial public release.

  • Vendored a lightweight subset of ruptures v1.1.8 – BinSeg, BottomUp, DynP, KCPD, PELT and Window detectors no longer need an external dependency.

  • Added BottomUpDetector and DynpDetector wrappers with aeon-compatible interfaces.

  • Replaced the surrogate PyTorch TSCP2Detector with a faithful TensorFlow + TCN implementation matching the original baseline.

  • Replaced the pyhsmm-backed HdpHsmmDetector with a native NumPy/SciPy sticky HDP implementation. pyhsmm and pybasicbayes are no longer installed by default.

  • Improved ClaspDetector axis handling.

  • Added Sphinx documentation with GitHub Pages deployment.

  • Documented test suite layout and fixtures.