TransformerBlock class

Constructors

TransformerBlock(int dModel, int nHeads, {int ffnMult = 4, bool rope = false})

Properties

ffn FeedForward
final
hashCode int
The hash code for this object.
no setterinherited
ln1 LayerNorm
final
ln2 LayerNorm
final
mha MultiHeadAttention
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

forward(Tensor2D x, {KVCache? cache}) Tensor2D
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited