From 7a521debc53facb8f4e00e829c357e087b103b3a Mon Sep 17 00:00:00 2001 From: Kaustbh Date: Sun, 9 Mar 2025 18:08:48 +0530 Subject: [PATCH] Clarify documentation regarding unequal length series limitation --- aeon/transformations/collection/base.py | 44 ++++++++++++++++--------- 1 file changed, 28 insertions(+), 16 deletions(-) diff --git a/aeon/transformations/collection/base.py b/aeon/transformations/collection/base.py index 013001d80e..ddf8c46a7d 100644 --- a/aeon/transformations/collection/base.py +++ b/aeon/transformations/collection/base.py @@ -64,10 +64,13 @@ def fit(self, X, y=None): X : np.ndarray or list Data to fit transform to, of valid collection type. Input data, any number of channels, equal length series of shape ``( - n_cases, n_channels, n_timepoints)`` or list of numpy arrays (any number - of channels, unequal length series) of shape ``[n_cases]``, 2D np.array - ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` is length of - series ``i``. Other types are allowed and converted into one of the above. + n_cases, n_channels, n_timepoints)``. + A list of numpy arrays of shape ``[n_cases]``, where each element is a + 2D array ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` + represents the length of series ``i``. This format is primarily used + for handling unequal-length series, but support for it depends on the + estimator's capabilities. Other input types are allowed and converted + into one of the above. Different estimators have different capabilities to handle different types of input. If ``self.get_tag("capability:multivariate")`` is False, @@ -118,10 +121,13 @@ def transform(self, X, y=None): X : np.ndarray or list Data to fit transform to, of valid collection type. Input data, any number of channels, equal length series of shape ``( - n_cases, n_channels, n_timepoints)`` or list of numpy arrays (any number - of channels, unequal length series) of shape ``[n_cases]``, 2D np.array - ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` is length of - series ``i``. Other types are allowed and converted into one of the above. + n_cases, n_channels, n_timepoints)``. + A list of numpy arrays of shape ``[n_cases]``, where each element is a + 2D array ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` + represents the length of series ``i``. This format is primarily used + for handling unequal-length series, but support for it depends on the + estimator's capabilities. Other input types are allowed and converted + into one of the above. Different estimators have different capabilities to handle different types of input. If ``self.get_tag("capability:multivariate")`` is False, @@ -172,10 +178,13 @@ def fit_transform(self, X, y=None): X : np.ndarray or list Data to fit transform to, of valid collection type. Input data, any number of channels, equal length series of shape ``(n_cases, - n_channels, n_timepoints)`` or list of numpy arrays (any number of - channels, unequal length series) of shape ``[n_cases]``, 2D np.array ``( - n_channels, n_timepoints_i)``, where ``n_timepoints_i`` is length of - series ``i``. Other types are allowed and converted into one of the above. + n_channels, n_timepoints)``. + A list of numpy arrays of shape ``[n_cases]``, where each element is a + 2D array ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` + represents the length of series ``i``. This format is primarily used + for handling unequal-length series, but support for it depends on the + estimator's capabilities. Other input types are allowed and converted + into one of the above. Different estimators have different capabilities to handle different types of input. If ``self.get_tag("capability:multivariate")`` is False, @@ -222,10 +231,13 @@ def inverse_transform(self, X, y=None): X : np.ndarray or list Data to fit transform to, of valid collection type. Input data, any number of channels, equal length series of shape ``( - n_cases, n_channels, n_timepoints)`` or list of numpy arrays (any number - of channels, unequal length series) of shape ``[n_cases]``, 2D np.array - ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` is length of - series ``i``. Other types are allowed and converted into one of the above. + n_cases, n_channels, n_timepoints)``. + A list of numpy arrays of shape ``[n_cases]``, where each element is a + 2D array ``(n_channels, n_timepoints_i)``, where ``n_timepoints_i`` + represents the length of series ``i``. This format is primarily used + for handling unequal-length series, but support for it depends on the + estimator's capabilities. Other input types are allowed and converted + into one of the above. Different estimators have different capabilities to handle different types of input. If ``self.get_tag("capability:multivariate")`` is False,