pub struct StreamWindow {
pub data_points: Vec<StreamDataPoint>,
pub start_time: SystemTime,
pub end_time: SystemTime,
pub metadata: HashMap<String, String>,
}Expand description
Window of stream data points
Fields§
§data_points: Vec<StreamDataPoint>Data points in the window
start_time: SystemTimeWindow start time
end_time: SystemTimeWindow end time
metadata: HashMap<String, String>Window metadata
Implementations§
Source§impl StreamWindow
impl StreamWindow
Sourcepub fn new(start_time: SystemTime, end_time: SystemTime) -> Self
pub fn new(start_time: SystemTime, end_time: SystemTime) -> Self
Create a new stream window
Sourcepub fn add_point(&mut self, point: StreamDataPoint)
pub fn add_point(&mut self, point: StreamDataPoint)
Add a data point to the window
Sourcepub fn features_matrix(&self) -> SklResult<Array2<f64>>
pub fn features_matrix(&self) -> SklResult<Array2<f64>>
Get features matrix
Sourcepub fn targets_array(&self) -> Option<Array1<f64>>
pub fn targets_array(&self) -> Option<Array1<f64>>
Get targets array
Trait Implementations§
Source§impl Clone for StreamWindow
impl Clone for StreamWindow
Source§fn clone(&self) -> StreamWindow
fn clone(&self) -> StreamWindow
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for StreamWindow
impl RefUnwindSafe for StreamWindow
impl Send for StreamWindow
impl Sync for StreamWindow
impl Unpin for StreamWindow
impl UnwindSafe for StreamWindow
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
Mutably borrows from an owned value. Read more
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>
Converts
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>
Converts
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 more