#[repr(i32)]pub enum AttentionIOForm {
kPADDED_BHND = 0,
kPACKED_NHD = 1,
}Expand description
! ! \enum AttentionIOForm ! ! \brief Enumerates the layout of the input/output tensors in an Attention layer. !
Variants§
kPADDED_BHND = 0
! All batches padded to maximum length. ! Shape: [batch_size, num_heads, num_tokens, head_dim]
kPACKED_NHD = 1
! All batches concatenated without padding. ! Shape: [total_tokens, num_heads, head_dim]
Trait Implementations§
Source§impl Clone for AttentionIOForm
impl Clone for AttentionIOForm
Source§fn clone(&self) -> AttentionIOForm
fn clone(&self) -> AttentionIOForm
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for AttentionIOForm
impl Debug for AttentionIOForm
Source§impl From<AttentionIOForm> for AttentionIOForm
impl From<AttentionIOForm> for AttentionIOForm
Source§fn from(value: AttentionIOForm) -> Self
fn from(value: AttentionIOForm) -> Self
Converts to this type from the input type.
Source§impl Hash for AttentionIOForm
impl Hash for AttentionIOForm
Source§impl Into<AttentionIOForm> for AttentionIOForm
impl Into<AttentionIOForm> for AttentionIOForm
Source§fn into(self) -> AttentionIOForm
fn into(self) -> AttentionIOForm
Converts this type into the (usually inferred) input type.
Source§impl Ord for AttentionIOForm
impl Ord for AttentionIOForm
Source§fn cmp(&self, other: &AttentionIOForm) -> Ordering
fn cmp(&self, other: &AttentionIOForm) -> Ordering
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for AttentionIOForm
impl PartialEq for AttentionIOForm
Source§fn eq(&self, other: &AttentionIOForm) -> bool
fn eq(&self, other: &AttentionIOForm) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl PartialOrd for AttentionIOForm
impl PartialOrd for AttentionIOForm
impl Copy for AttentionIOForm
impl Eq for AttentionIOForm
impl StructuralPartialEq for AttentionIOForm
Auto Trait Implementations§
impl Freeze for AttentionIOForm
impl RefUnwindSafe for AttentionIOForm
impl Send for AttentionIOForm
impl Sync for AttentionIOForm
impl Unpin for AttentionIOForm
impl UnsafeUnpin for AttentionIOForm
impl UnwindSafe for AttentionIOForm
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