pub struct Graph {
pub vals: Vec<Shape>,
pub ops: Vec<Op>,
pub logits: Option<Val>,
pub act: Option<Val>,
}Expand description
A model’s forward pass as ops over values.
Fields§
§vals: Vec<Shape>The shape of every value.
ops: Vec<Op>The ops, in the order they run.
logits: Option<Val>Marker rows, one wide, one logit per option.
act: Option<Val>Sequence rows, two wide, the act head.
Implementations§
Trait Implementations§
impl StructuralPartialEq for Graph
Auto Trait Implementations§
impl Freeze for Graph
impl RefUnwindSafe for Graph
impl Send for Graph
impl Sync for Graph
impl Unpin for Graph
impl UnsafeUnpin for Graph
impl UnwindSafe for Graph
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