Struct executorch_sys::torch::executor::Method
source · #[repr(C, align(8))]pub struct Method {
pub _bindgen_opaque_blob: [u64; 13],
}Expand description
An executable method of an executorch program. Maps to a python method like
forward() on the original nn.Module.
Fields§
§_bindgen_opaque_blob: [u64; 13]Implementations§
source§impl Method
impl Method
pub unsafe fn set_input( &mut self, input_evalue: *const EValue, input_idx: usize, ) -> Error
pub unsafe fn set_inputs( &mut self, input_evalues: *const ArrayRef<EValue>, ) -> Error
pub unsafe fn set_output_data_ptr( &mut self, buffer: *mut c_void, size: usize, output_idx: usize, ) -> Error
pub unsafe fn get_outputs( &mut self, output_evalues: *mut EValue, length: usize, ) -> Error
pub unsafe fn execute(&mut self) -> Error
pub unsafe fn experimental_step(&mut self) -> Error
pub unsafe fn experimental_reset_execution(&mut self) -> Error
pub unsafe fn method_meta(&self) -> MethodMeta
pub unsafe fn inputs_size(&self) -> usize
pub unsafe fn outputs_size(&self) -> usize
pub unsafe fn get_output(&self, i: usize) -> *const EValue
pub unsafe fn get_event_tracer(&mut self) -> *mut EventTracer
pub unsafe fn get_input(&self, i: usize) -> *const EValue
pub unsafe fn mutable_input(&mut self, i: usize) -> *mut EValue
pub unsafe fn mutable_output(&mut self, i: usize) -> *mut EValue
pub unsafe fn destruct(&mut self)
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Method
impl RefUnwindSafe for Method
impl Send for Method
impl Sync for Method
impl Unpin for Method
impl UnwindSafe for Method
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