Struct gtensor::graph::var::Var

source ·
pub struct Var<'t> {
    pub tape: &'t TapeBuilder,
    pub shape: Shape,
    pub index: usize,
    pub is_batched: bool,
}

Fields§

§tape: &'t TapeBuilder§shape: Shape§index: usize§is_batched: bool

Implementations§

source§

impl<'t> Var<'t>

source

pub fn extend(&self, builder: NodeBuilder) -> Var<'t>

source

pub fn shape(&self) -> Shape

source

pub fn shape2(&self) -> [usize; 2]

source

pub fn shape4(&self) -> [usize; 4]

Auto Trait Implementations§

§

impl<'t> !RefUnwindSafe for Var<'t>

§

impl<'t> !Send for Var<'t>

§

impl<'t> !Sync for Var<'t>

§

impl<'t> Unpin for Var<'t>

§

impl<'t> !UnwindSafe for Var<'t>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere 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 Twhere 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.

§

impl<T> Pointable for T

§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

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

§

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 Twhere U: TryFrom<T>,

§

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.
source§

impl<T> Type for T

source§

const METATYPE: MetaType = MetaType::Concrete

Enum describing whether a type is TraitObject, Slice or Concrete.
§

type Meta = Concrete

Type of metadata for type.
source§

fn meta(self: *const T) -> <T as Type>::Meta

Retrieve TraitObject, Slice or Concrete meta data respectively for a type
source§

fn data(self: *const T) -> *const ()

Retrieve pointer to the data
source§

fn data_mut(self: *mut T) -> *mut ()

Retrieve mut pointer to the data
source§

fn dangling(_t: <T as Type>::Meta) -> NonNull<T>

Create a dangling non-null *const Self with the provided Self::Meta.
source§

fn fatten(thin: *mut (), _t: <T as Type>::Meta) -> *mut T

Create a *mut Self with the provided Self::Meta.
source§

fn meta_type(self: *const Self) -> MetaType

Helper method describing whether a type is TraitObject, Slice or Concrete.
source§

impl<T> Type for Twhere T: ?Sized,

source§

default fn meta(self: *const T) -> <T as Type>::Meta

Retrieve TraitObject, Slice or Concrete meta data respectively for a type
source§

default fn data(self: *const T) -> *const ()

Retrieve pointer to the data
source§

default fn data_mut(self: *mut T) -> *mut ()

Retrieve mut pointer to the data
source§

default fn dangling(t: <T as Type>::Meta) -> NonNull<T>

Create a dangling non-null *const Self with the provided Self::Meta.
source§

default fn fatten(thin: *mut (), t: <T as Type>::Meta) -> *mut T

Create a *mut Self with the provided Self::Meta.
source§

const METATYPE: MetaType

Enum describing whether a type is TraitObject, Slice or Concrete.
§

type Meta: 'static

Type of metadata for type.
source§

fn meta_type(self: *const Self) -> MetaType

Helper method describing whether a type is TraitObject, Slice or Concrete.
§

impl<V, T> VZip<V> for Twhere V: MultiLane<T>,

§

fn vzip(self) -> V