Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Layer ¶
type Layer struct { nn.BaseModel Config bartconfig.Config SelfAttention *multiheadattention.Model SelfAttentionLayerNorm *layernorm.Model EncoderAttention *multiheadattention.Model EncoderAttentionLayerNorm *layernorm.Model FFN *stack.Model LayerNorm *layernorm.Model }
Layer implements a BART decoder layer.
func NewLayer ¶
func NewLayer(config bartconfig.Config) *Layer
NewLayer returns a new BART decoder Layer.
type Model ¶
type Model struct { nn.BaseModel Config bartconfig.Config LearnedPositionalEmbeddings *posembeddings.LearnedPositionalEmbeddings Layers []*Layer EmbeddingLayerNorm *layernorm.Model LayerNorm *layernorm.Model }
Model implements a BART decoder.
Click to show internal directories.
Click to hide internal directories.