class

MicroGPT::OutputHead

Inherits MicroGPT::MathUtils < Reference < Object

Constructors

new(d_model : Int32, vocab_size : Int32)
Source

Instance methods

forward(x : Mat) : Mat
Source
loss_and_backward(logits : Mat, targets : Array(Int32)) : Tuple(Float64, Mat)
Source
proj
Source
update(lr : Float64)
Source