Exercise:Convolution and Pooling

From Ufldl

Jump to: navigation, search
Line 1: Line 1:
== Convolution and Pooling ==
== Convolution and Pooling ==
-
This problem set is divided into two parts. In the first part, you will implement a [[Linear Decoders | linear decoder]] to learn features on color images from the STL10 dataset. In the second part, you will use these learned features in convolution and pooling for classifying STL10 images.
+
In this problem set, you will use the features you learned on 8x8 patches sampled from images from the STL10 dataset in [[Exercise:Exercise:Learning color features with Sparse Autoencoders | the earlier exercise on linear decoders]] for classifying 64x64 STL10 images by applying [[Feature extraction using convolution | convolution]] and [[Pooling | pooling]].
In the file <tt>[http://ufldl.stanford.edu/wiki/resources/cnn_exercise.zip cnn_exercise.zip]</tt> we have provided some starter code. You should write your code at the places indicated "YOUR CODE HERE" in the files.
In the file <tt>[http://ufldl.stanford.edu/wiki/resources/cnn_exercise.zip cnn_exercise.zip]</tt> we have provided some starter code. You should write your code at the places indicated "YOUR CODE HERE" in the files.
-
For this exercise, you will need to copy and modify '''<tt>sparseAutoencoderCost.m</tt>''' from your earlier exercise. You will also need to modify '''<tt>cnnConvolve.m</tt>''' and '''<tt>cnnPool.m</tt>''' from this exercise.
+
For this exercise, you will need to modify'''<tt>cnnConvolve.m</tt>''' and '''<tt>cnnPool.m</tt>'''.
=== Dependencies ===
=== Dependencies ===
Line 13: Line 13:
You will also need:
You will also need:
-
* <tt>sparseAutoencoderLinearCost.m</tt> (and related functions) from [[Exercise:Learning_color_features_with_Sparse_Autoencoders]]
+
* <tt>STL10Features.mat</tt> - saved features from [[Exercise:Learning_color_features_with_Sparse_Autoencoders]]
* <tt>softmaxTrain.m</tt> (and related functions) from [[Exercise:Softmax Regression]]
* <tt>softmaxTrain.m</tt> (and related functions) from [[Exercise:Softmax Regression]]
Line 20: Line 20:
=== Step 1: Learn color features ===
=== Step 1: Learn color features ===
-
Learn a set of color features by working through [[Exercise:Learning_color_features_with_Sparse_Autoencoders]], we will be using these features in the next steps. You should learn 400 features and they should look like this:
+
In this step, we will load the color features you learned in [[Exercise:Learning_color_features_with_Sparse_Autoencoders]].
-
[[File:cnn_Features_Good.png|480px]]
+
[[File:CNN_Features_Good.png|480px]]

Revision as of 05:27, 22 May 2011

Personal tools