English
Building a Tiny CIFAR-10 CNN in C: Convolution, Pooling, and Backpropagation
After the handwritten digit softmax classifier, the next practical step is a convolutional neural network. This project does not use PyTorch, TensorFlow, or OpenCV. Instead, one C file reads CIFAR-10 binary data, runs convolution, ReLU, max pooling, a fully connected layer, softmax, and manual backpropagation.
This article is based on the local cifar10_tiny_cnn.c project. The goal is not to reach state-of-the-art CIFAR-10 accuracy. The goal is to make each part of a CNN visible as code you can inspect, compile, and modify.
1. What The CIFAR-10 Input Looks Like
Each CIFAR-10 image is a 32 x 32 color image with red, green, and blue channels. The input shape in the program is therefore 3 x 32 x 32. Each sample has one label from 10 classes.
The source fixes that shape with a few constants:
#define IMG_C 3
#define IMG_H 32
#define IMG_W 32
#define NCLASS 10
This is different from the handwritten digit softmax project. The digit project flattens a grayscale image into one vector. The CNN keeps the spatial layout first, so convolution filters can scan local regions and detect color, edge, and texture patterns.
2. The Tiny CNN Architecture
The current code uses 16 filters of size 3 x 3. Because the convolution is valid convolution, a 32 x 32 input becomes 30 x 30 after convolution. Then 2 x 2 max pooling reduces it to 15 x 15.
#define NF 16
#define K 3
#define CONV_H (IMG_H - K + 1)
#define CONV_W (IMG_W - K + 1)
#define POOL_H (CONV_H / 2)
#define POOL_W (CONV_W / 2)
#define FEAT (NF * POOL_H * POOL_W)
The full path is:
- Input: 3 x 32 x 32
- Convolution: 16 filters, 3 x 3, output 16 x 30 x 30
- ReLU: clips negative activations to 0
- Max pooling: 2 x 2, output 16 x 15 x 15
- Fully connected layer: maps pooled features to 10 logits
- Softmax: converts logits into class probabilities
3. Convolution Written Directly In C
The convolution layer is nested loops. Each filter scans every output location, then multiplies and accumulates over the 3 input channels and the 3 x 3 local window.
float sum = net->conv_b[f];
for (int c = 0; c < IMG_C; c++) {
for (int r = 0; r < K; r++) {
for (int t = 0; t < K; t++) {
sum += net->conv_w[f][c][r][t] *
get_pixel(s->x, c, i + r, j + t);
}
}
}
conv[f][i][j] = sum > 0.0f ? sum : 0.0f;
The last line also applies ReLU. This plain implementation is useful because it exposes the relationship between filters, channels, local windows, and output positions.
4. Max Pooling Keeps The Strongest Local Response
The pooling layer compresses every 2 x 2 window into one value by keeping the maximum activation. The code also records where the maximum came from, because backpropagation only sends the gradient back to that winning position.
float best = conv[f][base_i][base_j];
int best_idx = 0;
for (int di = 0; di < 2; di++) {
for (int dj = 0; dj < 2; dj++) {
float v = conv[f][base_i + di][base_j + dj];
if (v > best) {
best = v;
best_idx = di * 2 + dj;
}
}
}
This reduces the feature map size and gives the model a small amount of local translation tolerance.
5. Fully Connected Layer And Softmax
The pooled features are flattened into one vector and passed into a fully connected layer. Each class has its own weights, producing 10 logits.
for (int k = 0; k < NCLASS; k++) {
float z = net->fc_b[k];
for (int p = 0; p < FEAT; p++) {
z += net->fc_w[k][p] * feat[p];
}
logits[k] = z;
}
Softmax normalizes these raw scores into probabilities. Training uses cross-entropy loss, and prediction selects the class with the highest probability.
6. What Backpropagation Updates
This program does not hide backpropagation inside a framework. It explicitly does four things:
- subtracts the true label from the softmax probabilities to get output gradients
- updates fully connected weights and biases
- sends gradients back through max pooling and ReLU
- updates every convolution filter from the matching input window
net->fc_w[k][p] -= LR * dlogits[k] * feat[p];
net->fc_b[k] -= LR * dlogits[k];
...
net->conv_w[f][c][r][t] -= LR * dw;
net->conv_b[f] -= LR * db;
This is the most valuable part of the project. CNN training is not magic: each layer computes its gradients and moves its parameters in a direction that lowers the loss.
7. Compile And Run Locally
The site publishes the source file, sample weights, sample predictions, and explanation notes. It does not publish the full CIFAR-10 dataset. Download the CIFAR-10 binary version from the official source, extract cifar-10-batches-bin, and run the program against that folder.
gcc -O2 -std=c11 cifar10_tiny_cnn.c -lm -o cifar10_tiny_cnn
./cifar10_tiny_cnn ./cifar-10-batches-bin 1 2000 1000
The four command-line arguments are:
- data directory
- number of epochs
- training sample limit
- test sample limit
Start with a small sample limit first. After the full flow works, increase the training sample count and epoch count gradually.
8. Reading The Output Files
The program writes two output files after a run:
model_weights.bin: saved model parameters from one local runtest_predictions.csv: prediction output for checking format and class distribution
The resource library only hosts small companion materials. The full training data stays with the official CIFAR-10 source instead of being duplicated on this site.
9. Project Boundaries
This tiny CNN is an educational implementation, not a production image classifier. Its limits are clear:
- pure C single-sample training is much slower than modern deep learning frameworks
- there is no mini-batching, data augmentation, regularization, or learning-rate schedule
- the network is intentionally small, so accuracy will not match modern CIFAR-10 models
- the main goal is to understand CNN forward propagation and backpropagation
If you have already read the handwritten digit softmax project, this article is the next step: moving from a linear classifier into an image model with local receptive fields.
10. Companion Resources
The resource library includes the C source, sample model weights, sample predictions, and CNN explanation PDF. Download the full CIFAR-10 dataset from its official source when running the project locally.
Chinese
用 C 从零实现 CIFAR-10 Tiny CNN:卷积、池化和反向传播
Open as a full page手写数字 softmax 分类器跑通以后,下一步最自然的升级就是卷积神经网络。这个项目没有使用 PyTorch、TensorFlow 或 OpenCV,而是用一个单文件 C 程序把 CIFAR-10 图像分类的核心流程写出来:读取二进制数据、做卷积、ReLU、最大池化、全连接、softmax,再手写反向传播更新参数。
这篇文章基于本地项目里的 cifar10_tiny_cnn.c。它不是为了追求高准确率,而是为了把 CNN 的每一层变成能直接阅读和修改的 C 代码。
一、CIFAR-10 输入是什么样
CIFAR-10 的每张图片是 32 x 32 的彩色图像,有红、绿、蓝 3 个通道,所以程序里的输入形状是 3 x 32 x 32。每条样本对应一个类别标签,类别总数是 10。
源码里用几个常量把这个结构固定下来:
#define IMG_C 3
#define IMG_H 32
#define IMG_W 32
#define NCLASS 10
这里最值得注意的是:图像不再像手写数字项目那样拉平成一条 784 维向量后直接分类。CNN 会先保留二维空间结构,让卷积核在局部区域上滑动,提取边缘、颜色块和纹理模式。
二、这个 tiny CNN 的网络结构
当前代码实际使用 16 个 3 x 3 卷积核。因为是 valid convolution,32 x 32 输入经过 3 x 3 卷积后会变成 30 x 30;再经过 2 x 2 最大池化后,空间大小变成 15 x 15。
#define NF 16
#define K 3
#define CONV_H (IMG_H - K + 1)
#define CONV_W (IMG_W - K + 1)
#define POOL_H (CONV_H / 2)
#define POOL_W (CONV_W / 2)
#define FEAT (NF * POOL_H * POOL_W)
所以完整路径是:
- 输入:3 x 32 x 32
- 卷积:16 个 3 x 3 卷积核,输出 16 x 30 x 30
- ReLU:把负数激活压到 0
- 最大池化:2 x 2,输出 16 x 15 x 15
- 全连接:把池化结果映射到 10 个类别 logit
- softmax:把 logit 转成类别概率
三、卷积层在 C 里怎么写
卷积层的核心就是多层循环。每个卷积核都会扫过输出网格中的每个位置,再对 3 个颜色通道和 3 x 3 局部窗口做乘加。
float sum = net->conv_b[f];
for (int c = 0; c < IMG_C; c++) {
for (int r = 0; r < K; r++) {
for (int t = 0; t < K; t++) {
sum += net->conv_w[f][c][r][t] *
get_pixel(s->x, c, i + r, j + t);
}
}
}
conv[f][i][j] = sum > 0.0f ? sum : 0.0f;
最后一行同时完成了 ReLU。这样写很朴素,但能清楚看到卷积核、通道、局部窗口和输出位置之间的关系。
四、最大池化保留局部最强响应
池化层把每个 2 x 2 小窗口压成一个值,只保留最大激活。代码还记录了最大值的位置,因为反向传播时梯度只会传回当时胜出的那个位置。
float best = conv[f][base_i][base_j];
int best_idx = 0;
for (int di = 0; di < 2; di++) {
for (int dj = 0; dj < 2; dj++) {
float v = conv[f][base_i + di][base_j + dj];
if (v > best) {
best = v;
best_idx = di * 2 + dj;
}
}
}
这一步会降低特征图尺寸,也让模型对小范围平移更稳一点。
五、全连接层和 softmax
池化后的特征会被展开成一维数组,再进入全连接层。每个类别有一组权重,输出 10 个 logit。
for (int k = 0; k < NCLASS; k++) {
float z = net->fc_b[k];
for (int p = 0; p < FEAT; p++) {
z += net->fc_w[k][p] * feat[p];
}
logits[k] = z;
}
softmax 会把这 10 个原始分数归一化成概率。训练时用交叉熵损失,预测时选择概率最大的类别。
六、反向传播更新了哪些参数
这个 C 程序没有把反向传播藏进框架里。它显式做了四件事:
- 从 softmax 概率减去真实标签,得到输出层梯度
- 更新全连接层权重和偏置
- 把梯度通过最大池化和 ReLU 传回卷积输出
- 用输入局部窗口更新每个卷积核权重
net->fc_w[k][p] -= LR * dlogits[k] * feat[p];
net->fc_b[k] -= LR * dlogits[k];
...
net->conv_w[f][c][r][t] -= LR * dw;
net->conv_b[f] -= LR * db;
这也是这份代码最有学习价值的部分:你能看到 CNN 训练不是“神秘自动完成”,而是每一层都把自己的梯度算清楚,再把参数往降低损失的方向挪一步。
七、如何本地编译运行
站点只发布源码、权重样例、预测样例和说明文件,不上传完整 CIFAR-10 数据包。你需要从 CIFAR-10 官方页面下载 binary version,解压出 cifar-10-batches-bin 后再运行。
gcc -O2 -std=c11 cifar10_tiny_cnn.c -lm -o cifar10_tiny_cnn
./cifar10_tiny_cnn ./cifar-10-batches-bin 1 2000 1000
这四个命令行参数分别表示:
- 数据目录
- 训练轮数
- 训练样本上限
- 测试样本上限
用小样本先跑通更适合学习和调试。确认流程没问题后,再逐步提高训练样本数量和轮数。
八、输出文件怎么看
程序结束后会写出两个文件:
model_weights.bin:当前模型参数,方便保留一次训练结果test_predictions.csv:测试样本预测结果,可用来检查输出格式和类别分布
站点资源库里放的是小型公开配套资源,不包含完整训练数据。这样可以让文章、下载资源和实验记录保持可访问,同时避免把大型公开数据集重复托管到网站上。
九、这个项目的边界
这份 tiny CNN 更像教学实现,不是生产级图像分类器。它的边界很明确:
- 纯 C 单样本训练,速度明显慢于现代深度学习框架
- 没有 mini-batch、数据增强、正则化和学习率调度
- 网络很小,准确率不会接近现代 CIFAR-10 模型
- 主要目标是理解卷积网络的前向传播和反向传播
如果你已经读过手写数字 softmax 项目,可以把这篇看成下一层台阶:从线性分类器进入有局部感受野的图像模型。
十、配套资源
可以在资源库中下载 C 源码、模型权重样例、预测样例 和 CNN 说明 PDF。完整 CIFAR-10 数据请从官方来源获取。
After the handwritten digit softmax classifier, the next practical step is a convolutional neural network. This project does not use PyTorch, TensorFlow, or OpenCV. Instead, one C file reads CIFAR-10 binary data, runs convolution, ReLU, max pooling, a fully connected layer, softmax, and manual backpropagation.
This article is based on the local cifar10_tiny_cnn.c project. The goal is not to reach state-of-the-art CIFAR-10 accuracy. The goal is to make each part of a CNN visible as code you can inspect, compile, and modify.
1. What The CIFAR-10 Input Looks Like
Each CIFAR-10 image is a 32 x 32 color image with red, green, and blue channels. The input shape in the program is therefore 3 x 32 x 32. Each sample has one label from 10 classes.
The source fixes that shape with a few constants:
#define IMG_C 3
#define IMG_H 32
#define IMG_W 32
#define NCLASS 10
This is different from the handwritten digit softmax project. The digit project flattens a grayscale image into one vector. The CNN keeps the spatial layout first, so convolution filters can scan local regions and detect color, edge, and texture patterns.
2. The Tiny CNN Architecture
The current code uses 16 filters of size 3 x 3. Because the convolution is valid convolution, a 32 x 32 input becomes 30 x 30 after convolution. Then 2 x 2 max pooling reduces it to 15 x 15.
#define NF 16
#define K 3
#define CONV_H (IMG_H - K + 1)
#define CONV_W (IMG_W - K + 1)
#define POOL_H (CONV_H / 2)
#define POOL_W (CONV_W / 2)
#define FEAT (NF * POOL_H * POOL_W)
The full path is:
- Input: 3 x 32 x 32
- Convolution: 16 filters, 3 x 3, output 16 x 30 x 30
- ReLU: clips negative activations to 0
- Max pooling: 2 x 2, output 16 x 15 x 15
- Fully connected layer: maps pooled features to 10 logits
- Softmax: converts logits into class probabilities
3. Convolution Written Directly In C
The convolution layer is nested loops. Each filter scans every output location, then multiplies and accumulates over the 3 input channels and the 3 x 3 local window.
float sum = net->conv_b[f];
for (int c = 0; c < IMG_C; c++) {
for (int r = 0; r < K; r++) {
for (int t = 0; t < K; t++) {
sum += net->conv_w[f][c][r][t] *
get_pixel(s->x, c, i + r, j + t);
}
}
}
conv[f][i][j] = sum > 0.0f ? sum : 0.0f;
The last line also applies ReLU. This plain implementation is useful because it exposes the relationship between filters, channels, local windows, and output positions.
4. Max Pooling Keeps The Strongest Local Response
The pooling layer compresses every 2 x 2 window into one value by keeping the maximum activation. The code also records where the maximum came from, because backpropagation only sends the gradient back to that winning position.
float best = conv[f][base_i][base_j];
int best_idx = 0;
for (int di = 0; di < 2; di++) {
for (int dj = 0; dj < 2; dj++) {
float v = conv[f][base_i + di][base_j + dj];
if (v > best) {
best = v;
best_idx = di * 2 + dj;
}
}
}
This reduces the feature map size and gives the model a small amount of local translation tolerance.
5. Fully Connected Layer And Softmax
The pooled features are flattened into one vector and passed into a fully connected layer. Each class has its own weights, producing 10 logits.
for (int k = 0; k < NCLASS; k++) {
float z = net->fc_b[k];
for (int p = 0; p < FEAT; p++) {
z += net->fc_w[k][p] * feat[p];
}
logits[k] = z;
}
Softmax normalizes these raw scores into probabilities. Training uses cross-entropy loss, and prediction selects the class with the highest probability.
6. What Backpropagation Updates
This program does not hide backpropagation inside a framework. It explicitly does four things:
- subtracts the true label from the softmax probabilities to get output gradients
- updates fully connected weights and biases
- sends gradients back through max pooling and ReLU
- updates every convolution filter from the matching input window
net->fc_w[k][p] -= LR * dlogits[k] * feat[p];
net->fc_b[k] -= LR * dlogits[k];
...
net->conv_w[f][c][r][t] -= LR * dw;
net->conv_b[f] -= LR * db;
This is the most valuable part of the project. CNN training is not magic: each layer computes its gradients and moves its parameters in a direction that lowers the loss.
7. Compile And Run Locally
The site publishes the source file, sample weights, sample predictions, and explanation notes. It does not publish the full CIFAR-10 dataset. Download the CIFAR-10 binary version from the official source, extract cifar-10-batches-bin, and run the program against that folder.
gcc -O2 -std=c11 cifar10_tiny_cnn.c -lm -o cifar10_tiny_cnn
./cifar10_tiny_cnn ./cifar-10-batches-bin 1 2000 1000
The four command-line arguments are:
- data directory
- number of epochs
- training sample limit
- test sample limit
Start with a small sample limit first. After the full flow works, increase the training sample count and epoch count gradually.
8. Reading The Output Files
The program writes two output files after a run:
model_weights.bin: saved model parameters from one local runtest_predictions.csv: prediction output for checking format and class distribution
The resource library only hosts small companion materials. The full training data stays with the official CIFAR-10 source instead of being duplicated on this site.
9. Project Boundaries
This tiny CNN is an educational implementation, not a production image classifier. Its limits are clear:
- pure C single-sample training is much slower than modern deep learning frameworks
- there is no mini-batching, data augmentation, regularization, or learning-rate schedule
- the network is intentionally small, so accuracy will not match modern CIFAR-10 models
- the main goal is to understand CNN forward propagation and backpropagation
If you have already read the handwritten digit softmax project, this article is the next step: moving from a linear classifier into an image model with local receptive fields.
10. Companion Resources
The resource library includes the C source, sample model weights, sample predictions, and CNN explanation PDF. Download the full CIFAR-10 dataset from its official source when running the project locally.
Search questions
FAQ
Who is this article for?
This article is for readers who want an intermediate-level guide to Building a Tiny CIFAR-10 CNN in C: Convolution, Pooling, and Backpropagation. It takes about 12 min and focuses on C, CNN, CIFAR-10, Backpropagation.
What should I read next?
The recommended next step is High-Entropy Traffic Defense Notes, so the article connects into a longer learning route instead of ending as an isolated note.
Does this article include runnable code or companion resources?
Yes. Use the run notes, resource cards, and download links on the page to reproduce the example or inspect the companion files.
How does this article fit into the larger site?
It is connected to the article context block, learning routes, resources, and project timeline so readers can move from concept to implementation.
Article context
AI Learning Project
A practical route from AI concepts to machine learning workflow, evaluation, neural networks, Python practice, handwritten digits, a CIFAR-10 CNN, adversarial traffic-defense notes, and AI security.
A source-based walkthrough of cifar10_tiny_cnn.c, covering CIFAR-10 binary input, 3x3 convolution, ReLU, max pooling, fully connected logits, softmax, backpropagation, and local commands.
Open share centerCompanion resources
AI Learning Project / CODE
cifar10_tiny_cnn.c source
Single-file C tiny CNN with CIFAR-10 loading, convolution, pooling, softmax, and backpropagation.
AI Learning Project / DATASET
model_weights.bin sample weights
Model weights generated by one local small-sample run.
AI Learning Project / DATASET
test_predictions.csv sample predictions
Sample test prediction output from the CIFAR-10 tiny CNN.
AI Learning Project / DIAGRAM
CNN project explanation PDF
Companion explanation material for the CNN project.
Project timeline
Published posts
- AI Basics Learning Roadmap Separate AI, machine learning, and deep learning before going into implementation details.
- Machine Learning Workflow Follow the practical path from data and features to training, prediction, and evaluation.
- Model Training and Evaluation Understand loss, overfitting, train/test splits, accuracy, recall, and F1.
- Neural Network Basics Move from perceptrons to activation, forward propagation, backpropagation, and training loops.
- NLP Basics: Understanding Bag of Words and TF-IDF An introduction to the most fundamental text representation methods in NLP: Bag of Words (BoW) and TF-IDF.
- RNN Basics: Handling Sequential Data with Memory Understand the core concepts of Recurrent Neural Networks (RNN), the role of hidden states, and their application in NLP.
- Transformer Self-Attention Read Q/K/V, scaled dot-product attention, multi-head attention, and positional encoding before exploring LLM internals.
- Python AI Mini Practice Run a small scikit-learn classification task and read the experiment output.
- Handwritten Digit Dataset Basics Read train.csv, test.csv, labels, and the flattened 28 by 28 pixel layout before training the classifier.
- Handwritten Digit Softmax in C Follow the C implementation from logits and softmax probabilities to confusion matrices and submission export.
- Handwritten Digit Playground Notes See how the offline classifier was adapted into a browser demo with drawing input and probability output.
- CIFAR-10 Tiny CNN Tutorial in C Build and train a small convolutional neural network for CIFAR-10 image classification, then read its loss and accuracy output.
- Building a Tiny CIFAR-10 CNN in C: Convolution, Pooling, and Backpropagation A source-based walkthrough of cifar10_tiny_cnn.c, covering CIFAR-10 binary input, 3x3 convolution, ReLU, max pooling, fully connected logits, softmax, backpropagation, and local commands.
- High-Entropy Traffic Defense Notes Study encrypted metadata leaks, entropy, traffic classifiers, and a defensive Python chaffing prototype.
- AI Security Threat Modeling Build a defense map with NIST adversarial ML, MITRE ATLAS, and OWASP LLM risks.
- Adversarial Examples and Robust Evaluation Evaluate clean and perturbed accuracy with an FGSM-style digits experiment.
- Data Poisoning and Backdoor Defense Study poison rate, trigger behavior, attack success rate, and training pipeline controls.
- Model Privacy and Extraction Defense Measure membership inference signal and surrogate fidelity against a local toy model.
- LLM, RAG, and Agent Security Separate instructions from data and enforce tool permissions against indirect prompt injection.
Published resources
- Python AI practice code guide The article includes a runnable scikit-learn classification script.
- digit_softmax_classifier.c The C source for the handwritten digit softmax classifier.
- train.csv.zip Compressed handwritten digit training set with 42000 labeled samples.
- test.csv.zip Compressed handwritten digit test set with 28000 unlabeled samples.
- sample_submission.csv The official submission format example for checking the final output columns.
- submission.csv The prediction file generated by the current C project.
- digit-playground-model.json The compact softmax demo model and sample set used by the browser playground.
- digit-sample-grid.svg A small handwritten digit preview grid extracted from the training set.
- Handwritten digit project bundle Contains the source file, compressed datasets, submission files, browser model, and preview grid.
- cifar10_tiny_cnn.c source Single-file C tiny CNN with CIFAR-10 loading, convolution, pooling, softmax, and backpropagation.
- model_weights.bin sample weights Model weights generated by one local small-sample run.
- test_predictions.csv sample predictions Sample test prediction output from the CIFAR-10 tiny CNN.
- CNN project explanation PDF Companion explanation material for the CNN project.
- Virtual Mirror redacted code skeleton A redacted mld_chaffing_v2.py control-flow skeleton with secrets, node topology, and target lists removed.
- Virtual Mirror stress-test template A redacted CSV template for CPU, memory, peak threads, pulse rate, latency, and error measurements.
- Virtual Mirror classifier-evaluation template A CSV template for TP, FN, FP, TN, accuracy, precision, recall, F1, ROC-AUC, entropy, and JS divergence.
- Virtual Mirror resource notes Notes explaining why the public resources include only redacted code, test templates, and architecture context.
- AI Security Lab README Setup, safety boundaries, and quick-run commands for the AI Security series.
- AI Security Lab full bundle Includes safe toy scripts, result CSVs, risk register, attack-defense matrix, and architecture diagram.
- AI security risk register CSV risk register template for AI threat modeling and release review.
- AI attack-defense matrix Maps attack surface, toy demo, metric, and defensive control into one CSV table.
- AI Security Lab architecture diagram Shows threat modeling, robustness, data integrity, model privacy, and RAG guardrails.
- FGSM digits robustness script FGSM-style perturbation and accuracy-drop experiment for a local digits classifier.
- Data poisoning and backdoor toy script Demonstrates poison rate, trigger behavior, and attack success rate on digits.
- Model privacy and extraction toy script Outputs membership AUC, target accuracy, surrogate fidelity, and surrogate accuracy.
- RAG prompt injection guard toy script Uses a deterministic toy agent to demonstrate external-data demotion and tool-policy blocking.
- Deep Learning topic share card A 1200x630 SVG card for sharing the Deep Learning / CNN topic hub.
- Machine Learning From Scratch share card A 1200x630 SVG card for the K-means, Iris, and ML workflow topic hub.
- Student AI Projects share card A 1200x630 SVG card for handwritten digits, C classifiers, and browser demos.
- CNN convolution scan animation An 8-second Remotion animation showing how a 3x3 convolution kernel scans an input and builds a feature map.
Current route
- AI Basics Learning Roadmap Learning path step
- Machine Learning Workflow Learning path step
- Model Training and Evaluation Learning path step
- Neural Network Basics Learning path step
- Transformer Self-Attention Learning path step
- LLM Visualizer Learning path step
- Python AI Mini Practice Learning path step
- Handwritten Digit Dataset Basics Learning path step
- Handwritten Digit Softmax in C Learning path step
- Handwritten Digit Playground Notes Learning path step
- CIFAR-10 Tiny CNN Tutorial in C Learning path step
- High-Entropy Traffic Defense Notes Learning path step
- AI Security Threat Modeling Learning path step
- Adversarial Examples and Robust Evaluation Learning path step
- Data Poisoning and Backdoor Defense Learning path step
- Model Privacy and Extraction Defense Learning path step
- LLM, RAG, and Agent Security Learning path step
Next notes
- Add more image-classification and error-analysis cases
- Turn common metrics into a quick reference
- Add more AI security defense experiment notes
