Forward pass: Difference between revisions
Appearance
Evaluation of a network on an input: layer recurrence, composition, cost, and its relation to backpropagation — AI-assisted (RonzzWikiCowriter) (via create-page on MediaWiki MCP Server) |
No edit summary |
||
| (13 intermediate revisions by 2 users not shown) | |||
| Line 1: | Line 1: | ||
[[Category:Artificial neural network]] | [[Category:Artificial neural network| 1]] | ||
A '''forward pass''' | [[File:Deepseek chat.png|thumbnail|When one chats with an [[LLM]], the LLM repeatedly executes [[forward pass]] to generate a response, often token by token.]] | ||
A '''forward pass''' of an [[artificial neural network (ANN)]], also called '''inference''', is the process of obtaining an output $f_\theta(X)$ based on input $X$. | |||
== | == Stages == | ||
Common stages of a '''forward pass''' include: | |||
* '''[[tokenisation (machine learning)|Tokenisation]]''' and '''[[token embedding (machine learning)|Token embedding]]''', to convert raw input into real vectors. | |||
* '''Computation''' | |||
** in a simple [[ANN]]: via [[feedforward algorithm]]; | |||
** in a [[Transformer]]: via multiple layers of [[self-attention]], [[Feed-Forward Network (FFN) Sub-Layer (Transformer)|FFN sub-layer]], and [[residual connection (Transformer)|residual connection + layer normalisation]]. | |||
* '''Output head''': converts the model output back into token(s), often via [[Softmax|softmax]]. | |||
Latest revision as of 10:43, 16 November 2026

Image: Rong Martin-Siebler ZHOU · CC BY-SA 4.0
A forward pass of an artificial neural network (ANN), also called inference, is the process of obtaining an output $f_\theta(X)$ based on input $X$.
Stages
Common stages of a forward pass include:
- Tokenisation and Token embedding, to convert raw input into real vectors.
- Computation
- in a simple ANN: via feedforward algorithm;
- in a Transformer: via multiple layers of self-attention, FFN sub-layer, and residual connection + layer normalisation.
- Output head: converts the model output back into token(s), often via softmax.