pub struct OneApiExecutable { /* private fields */ }Implementations§
Source§impl OneApiExecutable
impl OneApiExecutable
pub fn compile(graph: Graph) -> Self
Sourcepub fn compile_rng(graph: Graph, rng: RngOptions) -> Self
pub fn compile_rng(graph: Graph, rng: RngOptions) -> Self
Legalize the graph to the native primitive set, then capture I/O maps.
pub fn set_param(&mut self, name: &str, data: &[f32])
pub fn set_param_bytes(&mut self, name: &str, data: &[u8])
pub fn output_dtypes(&self) -> Vec<DType>
pub fn set_active_extent(&mut self, extent: Option<(usize, usize)>)
pub fn set_rng(&mut self, rng: RngOptions)
pub fn rng(&self) -> RngOptions
pub fn run(&mut self, inputs: &[(&str, &[f32])]) -> Vec<Vec<f32>>
pub fn run_read_outputs( &mut self, inputs: &[(&str, &[f32])], read_indices: Option<&[usize]>, ) -> Vec<Vec<f32>>
Sourcepub fn clone_for_cache(&self) -> Self
pub fn clone_for_cache(&self) -> Self
Deep copy for the runtime’s executable cache: fresh state with the same legalized graph + uploaded params.
Trait Implementations§
impl Send for OneApiExecutable
Auto Trait Implementations§
impl Freeze for OneApiExecutable
impl RefUnwindSafe for OneApiExecutable
impl Sync for OneApiExecutable
impl Unpin for OneApiExecutable
impl UnsafeUnpin for OneApiExecutable
impl UnwindSafe for OneApiExecutable
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