CS231n Lecture 0–1 Notes
Original Chinese title: cs213n Lecture 0-1
cs213n
- CS231n: Convolutional Neural Networks for Visual Recognition
- A computer vision course taught by Fei-Fei Li. I’ve been writing a related paper recently using these kinds of models. The experiments are done, but a lot of the foundational concepts still feel fuzzy. Since the pacing of this course fits well, I’m going back through the key CNN parts again.
Data Driven Approach
- Collect the Data
- Use Machine Learning to train a classifier
- Evaluate the classifier on the new data
- If you’re still unsure about the difference between Machine Learning and Deep Learning, you can check out 00’s blog post.
KNN
- Training complexity is O(1), whereas prediction is O(n), meaning it takes longer to classify a new example than it did to learn. That’s why it’s rarely used for images.
- My own take: if you form an abstract concept of a cat in your mind, you can recognize a cat flashing past in an instant. If recognizing takes longer than learning, what’s the point of learning? So it just doesn’t make sense.
Cross-Validation
- I only noticed this parameter after seeing it in a TensorFlow model I trained myself. Reading through these slides finally made it click what it’s actually doing.

- Building a model on already-tagged data:
- Use all the data for training.
- Use most of the data for training, and a small portion (usually 8:2) for testing.
- Use most of the data for training, a small portion for validation, and a small portion for testing.
- Use most of the data for training, split a small portion into multiple folds for validation, and take the average across those folds to represent the model’s validation score—this is cross-validation—then evaluate on the test split.
cs213n
- CS231n: Convolutional Neural Networks for Visual Recognition
- 大神FeiFei Li 开的一门关于计算机视觉的课。因为最近一直在写一篇相关的paper,用了相关的模型。实验做完了,有很多基础的概念还是模糊,刚好这个课时时间比较合适,把重点的CNN再重新过一边。
Data Driven Approach
- Collect the Data
- Use Machine Learning to train a classifier
- Evaluate the classifier on the new data
- 如果还有疑问对与Machine Learning 和 Deep learning,可以参照00的这篇blog
KNN
- train 的复杂度是O(1),而prediction则是O(n),意味着对一个新的事物作出判断的时候需要比学习更久的时间。所以很少用于images
- 个人理解,如果脑海中抽象了一只猫的概念,那么人才可能对于瞬间闪过的猫能判断。如果判断的速度比学习还慢,学习了有啥用?所以不合理。
Cross-Validation
- 看到这次参数还是因为看到自己用tensorflow train的一个模型才发现这个参数。看了这个ppt才大概明白具体在讲什么。

- 对一个已经tag好的数据建立模型
- 用所有的数据做train
- 用大部分数据做train,然后小部分数据(通常8:2)来做test
- 用大部分数据做train,在用小部分数据validation,在小部分数据做test。
- 用大部分数据做train,结合小部分1数据分割成一个一个folds 做validation,取这些folds的均值来代表整个model的validation,成为cross-validation,然后小部分数据做test。