#[non_exhaustive]pub struct ShapeletTransformFit {
pub shapelets: ShapeletSet,
pub features: FdMatrix,
}Expand description
A fitted shapelet transform: the discovered ShapeletSet plus the training
feature matrix produced by applying it to the training curves.
Stores the already-z-normalized shapelets so that out-of-sample
transform reuses the exact same shapelets and
normalization as the fit — never re-discovering or re-normalizing against
test-set statistics.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.shapelets: ShapeletSetThe discovered, already-z-normalized shapelet set.
features: FdMatrixThe training n×K distance feature matrix (columns = shapelet distances).
Implementations§
Source§impl ShapeletTransformFit
impl ShapeletTransformFit
Sourcepub fn shapelets(&self) -> &ShapeletSet
pub fn shapelets(&self) -> &ShapeletSet
The fitted shapelet set (already z-normalized, ordered by quality).
Sourcepub fn features(&self) -> &FdMatrix
pub fn features(&self) -> &FdMatrix
The training n×K feature matrix (columns are shapelet distances).
Sourcepub fn transform(&self, new_data: &FdMatrix) -> Result<FdMatrix, FdarError>
pub fn transform(&self, new_data: &FdMatrix) -> Result<FdMatrix, FdarError>
Transform out-of-sample curves using the stored shapelets.
Applies the exact fitted shapelets (same sequences, same stored
z-normalization) to new_data, yielding an n_new×K feature matrix.
This is shapelet_transform against the stored set — no re-discovery,
no re-normalization against new_data.
§Errors
Same as shapelet_transform: FdarError::InvalidDimension if a
series is shorter than a shapelet, FdarError::InvalidParameter if the
stored set is empty.
Trait Implementations§
Source§impl Clone for ShapeletTransformFit
impl Clone for ShapeletTransformFit
Source§fn clone(&self) -> ShapeletTransformFit
fn clone(&self) -> ShapeletTransformFit
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for ShapeletTransformFit
impl Debug for ShapeletTransformFit
Source§impl PartialEq for ShapeletTransformFit
impl PartialEq for ShapeletTransformFit
impl StructuralPartialEq for ShapeletTransformFit
Auto Trait Implementations§
impl Freeze for ShapeletTransformFit
impl RefUnwindSafe for ShapeletTransformFit
impl Send for ShapeletTransformFit
impl Sync for ShapeletTransformFit
impl Unpin for ShapeletTransformFit
impl UnsafeUnpin for ShapeletTransformFit
impl UnwindSafe for ShapeletTransformFit
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
impl<T> Scalar for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
self to the equivalent element of its superset.