[][src]Struct tch::CModule

pub struct CModule { /* fields omitted */ }

Methods

impl CModule[src]

pub fn load(path: &Path) -> Fallible<CModule>[src]

Loads a PyTorch saved JIT model from a file.

pub fn forward(&self, ts: &[&Tensor]) -> Fallible<Tensor>[src]

Performs the forward pass for a model on some specified tensor input.

pub fn forward_(&self, ts: &[&IValue]) -> Fallible<IValue>[src]

Performs the forward pass for a model on some specified ivalue input.

Trait Implementations

impl Drop for CModule[src]

Auto Trait Implementations

impl !Send for CModule

impl !Sync for CModule

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]