Skip to main content

IlpMask

Enum IlpMask 

Source
pub enum IlpMask {
    Dense {
        hard: CudaBuffer,
        soft: CudaBuffer,
        schema_size: usize,
    },
    Sparse {
        active_entries: Vec<(u32, u32, u32)>,
        schema_size: usize,
    },
    SparseDevice {
        candidate_order: Vec<(u32, u32, u32)>,
        active_flags: CudaBuffer,
        selected_count: usize,
        schema_size: usize,
    },
}
Expand description

A registered ILP mask — Dense (imported via DLPack) or Sparse (candidate entries only).

Variants§

§

Dense

Dense mask with hard and soft weight buffers.

Fields

§hard: CudaBuffer

Hard mask (binary on/off).

§soft: CudaBuffer

Soft mask (continuous weights).

§schema_size: usize

Number of body relations in the schema.

§

Sparse

Sparse mask listing active (i,j,k) entries on host.

Fields

§active_entries: Vec<(u32, u32, u32)>

Active rule entries.

§schema_size: usize

Number of body relations in the schema.

§

SparseDevice

Sparse mask with device-resident active flags.

Fields

§candidate_order: Vec<(u32, u32, u32)>

Candidate (i,j,k) entries in evaluation order.

§active_flags: CudaBuffer

Device-resident boolean flags per candidate.

§selected_count: usize

Number of currently selected candidates.

§schema_size: usize

Number of body relations in the schema.

Implementations§

Source§

impl IlpMask

Source

pub fn schema_size(&self) -> usize

Return the schema size (number of body relations).

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<T> Allocation for T
where T: RefUnwindSafe + Send + Sync,