pub struct SimdDataLayout { /* private fields */ }Expand description
Cache-friendly data layouts for SIMD operations
Implementations§
Source§impl SimdDataLayout
impl SimdDataLayout
Sourcepub fn new(config: SimdConfig) -> Self
pub fn new(config: SimdConfig) -> Self
Create new SIMD data layout optimizer
Sourcepub fn transpose_for_simd(&self, data: &ArrayView2<'_, Float>) -> Array2<Float>
pub fn transpose_for_simd(&self, data: &ArrayView2<'_, Float>) -> Array2<Float>
Transpose matrix for better cache locality
Sourcepub fn optimize_layout(&self, data: &ArrayView2<'_, Float>) -> Array2<Float>
pub fn optimize_layout(&self, data: &ArrayView2<'_, Float>) -> Array2<Float>
Reshape data for optimal SIMD processing
Sourcepub fn create_chunks(
&self,
data: &ArrayView2<'_, Float>,
chunk_size: Option<usize>,
) -> Vec<Array2<Float>> ⓘ
pub fn create_chunks( &self, data: &ArrayView2<'_, Float>, chunk_size: Option<usize>, ) -> Vec<Array2<Float>> ⓘ
Create memory-efficient chunks for parallel processing
Auto Trait Implementations§
impl Freeze for SimdDataLayout
impl RefUnwindSafe for SimdDataLayout
impl Send for SimdDataLayout
impl Sync for SimdDataLayout
impl Unpin for SimdDataLayout
impl UnwindSafe for SimdDataLayout
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> 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