Enum tc_tensor::DenseAccessor 
source · [−]pub enum DenseAccessor<FD, FS, D, T> {
Show 13 variants
    Broadcast(Box<BlockListBroadcast<FD, FS, D, T, Self>>),
    Cast(Box<BlockListCast<FD, FS, D, T, Self>>),
    Combine(Box<BlockListCombine<FD, FS, D, T, Self, Self>>),
    Const(Box<BlockListConst<FD, FS, D, T, Self>>),
    Expand(Box<BlockListExpand<FD, FS, D, T, Self>>),
    Flip(Box<BlockListFlip<FD, FS, D, T, Self>>),
    File(BlockListFile<FD, FS, D, T>),
    Reduce(Box<BlockListReduce<FD, FS, D, T, Self>>),
    Reshape(Box<BlockListReshape<FD, FS, D, T, Self>>),
    Slice(BlockListFileSlice<FD, FS, D, T>),
    Sparse(BlockListSparse<FD, FS, D, T, SparseAccessor<FD, FS, D, T>>),
    Transpose(Box<BlockListTranspose<FD, FS, D, T, Self>>),
    Unary(Box<BlockListUnary<FD, FS, D, T, Self>>),
}Expand description
A generic enum which can contain any DenseAccess impl
Variants
Broadcast(Box<BlockListBroadcast<FD, FS, D, T, Self>>)
Cast(Box<BlockListCast<FD, FS, D, T, Self>>)
Combine(Box<BlockListCombine<FD, FS, D, T, Self, Self>>)
Const(Box<BlockListConst<FD, FS, D, T, Self>>)
Expand(Box<BlockListExpand<FD, FS, D, T, Self>>)
Flip(Box<BlockListFlip<FD, FS, D, T, Self>>)
File(BlockListFile<FD, FS, D, T>)
Reduce(Box<BlockListReduce<FD, FS, D, T, Self>>)
Reshape(Box<BlockListReshape<FD, FS, D, T, Self>>)
Slice(BlockListFileSlice<FD, FS, D, T>)
Sparse(BlockListSparse<FD, FS, D, T, SparseAccessor<FD, FS, D, T>>)
Transpose(Box<BlockListTranspose<FD, FS, D, T, Self>>)
Unary(Box<BlockListUnary<FD, FS, D, T, Self>>)
Trait Implementations
sourceimpl<FD: Clone, FS: Clone, D: Clone, T: Clone> Clone for DenseAccessor<FD, FS, D, T>
 
impl<FD: Clone, FS: Clone, D: Clone, T: Clone> Clone for DenseAccessor<FD, FS, D, T>
sourcefn clone(&self) -> DenseAccessor<FD, FS, D, T>
 
fn clone(&self) -> DenseAccessor<FD, FS, D, T>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl<FD, FS, D, T> DenseAccess<FD, FS, D, T> for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
 
impl<FD, FS, D, T> DenseAccess<FD, FS, D, T> for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
type Slice = DenseAccessor<FD, FS, D, T>
type Slice = DenseAccessor<FD, FS, D, T>
The type returned by slice
type Transpose = DenseAccessor<FD, FS, D, T>
type Transpose = DenseAccessor<FD, FS, D, T>
The type returned by transpose
sourcefn accessor(self) -> Self
 
fn accessor(self) -> Self
Return a DenseAccessor enum which contains this accessor.
sourcefn block_stream<'a>(
    self,
    txn: T
) -> TCBoxTryFuture<'a, TCBoxTryStream<'a, Array>>
 
fn block_stream<'a>(
    self,
    txn: T
) -> TCBoxTryFuture<'a, TCBoxTryStream<'a, Array>>
Return a stream of the Arrays which this DenseTensor comprises.
sourcefn value_stream<'a>(
    self,
    txn: T
) -> TCBoxTryFuture<'a, TCBoxTryStream<'a, Number>>
 
fn value_stream<'a>(
    self,
    txn: T
) -> TCBoxTryFuture<'a, TCBoxTryStream<'a, Number>>
Return a stream of the elements of this DenseTensor.
sourcefn slice(self, bounds: Bounds) -> TCResult<Self>
 
fn slice(self, bounds: Bounds) -> TCResult<Self>
Return a slice of this DenseTensor.
sourceimpl<FD, FS, D, T> DenseWrite<FD, FS, D, T> for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
 
impl<FD, FS, D, T> DenseWrite<FD, FS, D, T> for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
sourcefn write<'life0, 'async_trait, V>(
    &'life0 self,
    txn: Self::Txn,
    bounds: Bounds,
    value: V
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>>where
    V: 'async_trait + DenseAccess<FD, FS, D, T>,
    'life0: 'async_trait,
    Self: 'async_trait,
 
fn write<'life0, 'async_trait, V>(
    &'life0 self,
    txn: Self::Txn,
    bounds: Bounds,
    value: V
) -> Pin<Box<dyn Future<Output = TCResult<()>> + Send + 'async_trait>>where
    V: 'async_trait + DenseAccess<FD, FS, D, T>,
    'life0: 'async_trait,
    Self: 'async_trait,
Overwrite this accessor’s contents with those of the given accessor.
sourceimpl<FD, FS, D, T> Display for DenseAccessor<FD, FS, D, T>
 
impl<FD, FS, D, T> Display for DenseAccessor<FD, FS, D, T>
sourceimpl<FD, FS, D, T> From<BlockListFile<FD, FS, D, T>> for DenseAccessor<FD, FS, D, T>where
    FD: File<Array>,
    FS: File<Node>,
    D: Dir,
    T: Transaction<D>,
 
impl<FD, FS, D, T> From<BlockListFile<FD, FS, D, T>> for DenseAccessor<FD, FS, D, T>where
    FD: File<Array>,
    FS: File<Node>,
    D: Dir,
    T: Transaction<D>,
sourcefn from(file: BlockListFile<FD, FS, D, T>) -> Self
 
fn from(file: BlockListFile<FD, FS, D, T>) -> Self
Converts to this type from the input type.
sourceimpl<FD, FS, D, T> TensorAccess for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
 
impl<FD, FS, D, T> TensorAccess for DenseAccessor<FD, FS, D, T>where
    D: Dir,
    T: Transaction<D>,
    FD: File<Array>,
    FS: File<Node>,
    <D::Read as DirRead>::FileEntry: AsType<FD> + AsType<FS>,
    <D::Write as DirWrite>::FileClass: From<BTreeType> + From<TensorType>,
Auto Trait Implementations
impl<FD, FS, D, T> !RefUnwindSafe for DenseAccessor<FD, FS, D, T>
impl<FD, FS, D, T> Send for DenseAccessor<FD, FS, D, T>where
    D: Send + Sync,
    FD: Send,
    FS: Send + Sync,
    T: Send + Sync,
impl<FD, FS, D, T> Sync for DenseAccessor<FD, FS, D, T>where
    D: Send + Sync,
    FD: Sync,
    FS: Send + Sync,
    T: Send + Sync,
impl<FD, FS, D, T> Unpin for DenseAccessor<FD, FS, D, T>where
    D: Unpin,
    FD: Unpin,
    FS: Unpin,
    T: Unpin,
impl<FD, FS, D, T> !UnwindSafe for DenseAccessor<FD, FS, D, T>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
    T: ?Sized,
 
impl<T> BorrowMut<T> for Twhere
    T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
 
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<F> Match for F
 
impl<F> Match for F
sourcefn matches<T>(&self) -> boolwhere
    T: TryCastFrom<Self>,
 
fn matches<T>(&self) -> boolwhere
    T: TryCastFrom<Self>,
Returns true if self can be cast into the target type T.
sourceimpl<F, T> TryCastFrom<F> for Twhere
    T: CastFrom<F>,
 
impl<F, T> TryCastFrom<F> for Twhere
    T: CastFrom<F>,
sourcefn can_cast_from(&F) -> bool
 
fn can_cast_from(&F) -> bool
Test if value can be cast into Self.
sourcefn opt_cast_from(f: F) -> Option<T>
 
fn opt_cast_from(f: F) -> Option<T>
Returns Some(Self) if the source value can be cast into Self, otherwise None.
sourcefn try_cast_from<Err, OnErr>(value: T, on_err: OnErr) -> Result<Self, Err>where
    OnErr: FnOnce(&T) -> Err,
 
fn try_cast_from<Err, OnErr>(value: T, on_err: OnErr) -> Result<Self, Err>where
    OnErr: FnOnce(&T) -> Err,
Returns Ok(Self) if the source value can be cast into Self, otherwise calls on_err.
sourceimpl<F, T> TryCastInto<T> for Fwhere
    T: TryCastFrom<F>,
 
impl<F, T> TryCastInto<T> for Fwhere
    T: TryCastFrom<F>,
sourcefn can_cast_into(&self) -> bool
 
fn can_cast_into(&self) -> bool
Test if self can be cast into T.
sourcefn opt_cast_into(self) -> Option<T>
 
fn opt_cast_into(self) -> Option<T>
Returns Some(T) if self can be cast into T, otherwise None.
sourcefn try_cast_into<Err, OnErr>(self, on_err: OnErr) -> Result<T, Err>where
    OnErr: FnOnce(&Self) -> Err,
 
fn try_cast_into<Err, OnErr>(self, on_err: OnErr) -> Result<T, Err>where
    OnErr: FnOnce(&Self) -> Err,
Returns Ok(T) if self can be cast into T, otherwise calls on_err.