logo

Trait neuronika::Data[][src]

pub trait Data {
    type Dim: Dimension;
    fn data(&self) -> Ref<'_, Array<f32, Self::Dim>>;
fn data_mut(&self) -> RefMut<'_, Array<f32, Self::Dim>>; }
Expand description

Data representation.

This trait is implemented by all the internal forward components of Var and VarDiff.

It provides the .data() method that is used to retrieve a Ref to the data stored inside the node.

Associated Types

The data’s dimensionality.

Required methods

Returns an immutable reference to the data inside self.

Returns a mutable reference to the data inside self.

Implementors