pub struct GPUConstraintChecker<C> { /* private fields */ }Expand description
GPU-accelerated constraint checker
Evaluates constraints in parallel on GPU hardware
Implementations§
Source§impl<C: ViolationComputable + Clone> GPUConstraintChecker<C>
impl<C: ViolationComputable + Clone> GPUConstraintChecker<C>
Sourcepub fn with_gpu_threshold(self, threshold: usize) -> Self
pub fn with_gpu_threshold(self, threshold: usize) -> Self
Set the batch size threshold for GPU usage
Sourcepub fn check_batch(&self, points: &Array2<f32>) -> Vec<bool>
pub fn check_batch(&self, points: &Array2<f32>) -> Vec<bool>
Check constraints for a batch of points
Automatically selects CPU or GPU based on batch size and availability
Sourcepub fn violation_batch(&self, points: &Array2<f32>) -> Vec<f32>
pub fn violation_batch(&self, points: &Array2<f32>) -> Vec<f32>
Compute violations for batch of points (GPU-accelerated)
Sourcepub fn is_gpu_available(&self) -> bool
pub fn is_gpu_available(&self) -> bool
Get GPU availability status
Sourcepub fn num_constraints(&self) -> usize
pub fn num_constraints(&self) -> usize
Get number of constraints
Auto Trait Implementations§
impl<C> Freeze for GPUConstraintChecker<C>
impl<C> RefUnwindSafe for GPUConstraintChecker<C>where
C: RefUnwindSafe,
impl<C> Send for GPUConstraintChecker<C>where
C: Send,
impl<C> Sync for GPUConstraintChecker<C>where
C: Sync,
impl<C> Unpin for GPUConstraintChecker<C>where
C: Unpin,
impl<C> UnwindSafe for GPUConstraintChecker<C>where
C: UnwindSafe,
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> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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