Neural Modeling Foundations

  1. Tensor Axes and Shapes

    A tensor shape records how many positions lie along each axis. Name axes separately so equal lengths do not hide different roles.

    Undergraduate
  2. A Single Weighted Unit with a Bias

    A unit can compute a weighted sum plus a bias, then apply an activation according to the layer definition.

    Undergraduate
  3. The Rectified Linear Unit at Its Boundary

    A rectified linear unit outputs zero for negative inputs and preserves nonnegative inputs.

    Undergraduate
  4. Shapes in a Dense Layer

    A dense layer computes several weighted output scores per example. Its weight matrix pairs input features with those output units.

    Undergraduate
  5. Tracing a Forward Pass Through Two Layers

    A forward pass composes layer calculations to produce a prediction from one input and a fixed set of parameters.

    Undergraduate
  6. Logits Before Normalization

    A multiclass prediction can begin with real-valued scores called logits. Softmax converts them to nonnegative probabilities with total one.

    Undergraduate
  7. Softmax on Two Scores

    Softmax assigns probabilities proportional to exponentiated scores. The common denominator normalizes them across the chosen class axis.

    Undergraduate
  8. Negative Log Probability as a Classification Loss

    For a known correct class, negative log loss increases as the assigned probability falls. The logarithm base should be consistent with the stated metric.

    Undergraduate
  9. The Chain Rule Through Two Scalar Operations

    When one differentiable operation feeds another, the chain rule multiplies their relevant local derivatives along the composition.

    Undergraduate
  10. Adding Gradient Contributions Along Two Paths

    When an intermediate quantity contributes to a result through several paths, its derivative includes a contribution from each path.

    Undergraduate
  11. One Gradient Descent Update

    A gradient descent step subtracts a positive step size times the gradient at the current parameters.

    Undergraduate
  12. A Step Size Can Overshoot a Minimum

    A learning rate sets how far a gradient update moves. The curvature of the loss helps determine a useful range.

    Undergraduate
  13. Examples, Batches, and Training Epochs

    A batch groups examples for one update under the training loop. An epoch commonly refers to one complete pass over a training set.

    Undergraduate
  14. Mean and Sum Reductions of Training Loss

    A training objective can sum or average losses across examples. The reduction changes gradient scale and batch-size dependence.

    Undergraduate
  15. Training and Evaluation Modes of a Model

    Some neural layers use different rules during fitting and scoring. Evaluation should apply the intended inference behavior explicitly.

    Undergraduate
  16. Dropping Activations During Training

    Dropout randomly masks selected activations during training. An implementation can adjust retained values so the expected activation under that rule is preserved.

    Undergraduate
  17. Choosing an Axis for Normalization

    Normalization estimates a center and scale over a selected set of positions. The axis choice changes which values share those statistics.

    Undergraduate
  18. A Skip Connection Adds an Earlier Representation

    A residual block can add its input representation to a calculated change when dimensions and semantics permit.

    Undergraduate
  19. A One-Dimensional Convolution-Style Layer

    A neural layer can reuse the same small weights across positions, operating on a moving window under its stride and boundary conventions.

    Undergraduate
  20. Max Pooling over Two Windows

    Max pooling outputs the largest value from each window. The window shape, stride, and padding determine which input values are considered.

    Undergraduate
  21. A Receptive Field Through Stacked Windows

    A unit's receptive field comprises positions in the input that can influence its computed value under the layer layout.

    Undergraduate
  22. Embedding Vectors as Row Lookups

    An embedding table assigns a learned vector to each supported ID. Looking up a sequence preserves the number and order of those IDs.

    Undergraduate
  23. Padding and Masks for Different Sequence Lengths

    Batching sequences of different lengths can add padding positions. A mask can tell operations which positions count as actual input.

    Undergraduate
  24. An Attention Output as a Weighted Sum

    An attention operation can combine value vectors using weights computed from query and key relationships.

    Undergraduate
  25. A Causal Mask Limits Which Positions Can Contribute

    An autoregressive sequence position can use earlier positions under a causal visibility rule. A mask enforces that dependency before attention weights are chosen.

    Undergraduate
  26. Producing a Sequence One Element at a Time

    An autoregressive model predicts a next element from the available prefix and can reuse the chosen result as part of the next prefix.

    Undergraduate
  27. Temperature Changes a Softmax Distribution

    A positive temperature can divide logits before softmax, controlling how strongly score differences affect the resulting probabilities.

    Undergraduate
  28. Loading a Model Checkpoint with Its Configuration

    A checkpoint can record parameters or a fuller training state. The required configuration depends on whether the next operation is scoring or resuming training.

    Undergraduate
  29. Checking Shapes Through a Small Neural Model

    A shape trace states which axis each layer transforms, preserves, or aggregates, allowing errors to be found before comparing results.

    Undergraduate
  30. Checking a Gradient with a Finite Difference

    An independent finite difference can estimate how a small change in one parameter affects loss and can be compared with the computed gradient.

    Undergraduate