Struct burn_core::nn::transformer::TransformerDecoderLayerRecord
source · pub struct TransformerDecoderLayerRecord<B: Backend> {
pub cross_attn: <MultiHeadAttention<B> as Module<B>>::Record,
pub self_attn: <MultiHeadAttention<B> as Module<B>>::Record,
pub pwff: <PositionWiseFeedForward<B> as Module<B>>::Record,
pub norm_1: <LayerNorm<B> as Module<B>>::Record,
pub norm_2: <LayerNorm<B> as Module<B>>::Record,
pub norm_3: <LayerNorm<B> as Module<B>>::Record,
pub dropout: <Dropout as Module<B>>::Record,
pub norm_first: <bool as Module<B>>::Record,
}Expand description
The record type for the module.
Fields§
§cross_attn: <MultiHeadAttention<B> as Module<B>>::RecordThe module record associative type.
self_attn: <MultiHeadAttention<B> as Module<B>>::RecordThe module record associative type.
pwff: <PositionWiseFeedForward<B> as Module<B>>::RecordThe module record associative type.
norm_1: <LayerNorm<B> as Module<B>>::RecordThe module record associative type.
norm_2: <LayerNorm<B> as Module<B>>::RecordThe module record associative type.
norm_3: <LayerNorm<B> as Module<B>>::RecordThe module record associative type.
dropout: <Dropout as Module<B>>::RecordThe module record associative type.
norm_first: <bool as Module<B>>::RecordThe module record associative type.
Trait Implementations§
source§impl<B: Clone + Backend> Clone for TransformerDecoderLayerRecord<B>
impl<B: Clone + Backend> Clone for TransformerDecoderLayerRecord<B>
source§fn clone(&self) -> TransformerDecoderLayerRecord<B>
fn clone(&self) -> TransformerDecoderLayerRecord<B>
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl<B: Backend> Record for TransformerDecoderLayerRecord<B>
impl<B: Backend> Record for TransformerDecoderLayerRecord<B>
§type Item<S: PrecisionSettings> = TransformerDecoderLayerRecordItem<B, S>
type Item<S: PrecisionSettings> = TransformerDecoderLayerRecordItem<B, S>
Type of the item that can be serialized and deserialized.
source§fn into_item<S: PrecisionSettings>(self) -> Self::Item<S>
fn into_item<S: PrecisionSettings>(self) -> Self::Item<S>
Convert the current record into the corresponding item that follows the given settings.
source§fn from_item<S: PrecisionSettings>(item: Self::Item<S>) -> Self
fn from_item<S: PrecisionSettings>(item: Self::Item<S>) -> Self
Convert the given item into a record.
Auto Trait Implementations§
impl<B> RefUnwindSafe for TransformerDecoderLayerRecord<B>where <B as Backend>::TensorPrimitive<1>: RefUnwindSafe, <B as Backend>::TensorPrimitive<2>: RefUnwindSafe,
impl<B> Send for TransformerDecoderLayerRecord<B>
impl<B> Sync for TransformerDecoderLayerRecord<B>
impl<B> Unpin for TransformerDecoderLayerRecord<B>where <B as Backend>::TensorPrimitive<1>: Unpin, <B as Backend>::TensorPrimitive<2>: Unpin,
impl<B> UnwindSafe for TransformerDecoderLayerRecord<B>where <B as Backend>::TensorPrimitive<1>: UnwindSafe, <B as Backend>::TensorPrimitive<2>: UnwindSafe,
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