Exercise:Learning color features with Sparse Autoencoders

From Ufldl

Jump to: navigation, search
(Step 1: Modify your sparse autoencoder to use a linear decoder)
(Step 1: Modify your sparse autoencoder to use a linear decoder)
 
Line 9: Line 9:
=== Dependencies ===
=== Dependencies ===
-
The following additional files are required for this exercise:
+
You will need:
-
* [http://ufldl.stanford.edu/wiki/resources/stl10_patches_100k.zip Sampled 8x8 patches from the STL-10 dataset (stl10_patches_100k.zip)]
+
-
* [http://ufldl.stanford.edu/wiki/resources/linear_decoder_exercise.zip Starter Code (linear_decoder_exercise.zip)]
+
-
 
+
-
You will also need:
+
* <tt>sparseAutoencoderCost.m</tt> (and related functions) from [[Exercise:Sparse Autoencoder]]
* <tt>sparseAutoencoderCost.m</tt> (and related functions) from [[Exercise:Sparse Autoencoder]]
 +
 +
The following additional file is also required for this exercise:
 +
* [http://ufldl.stanford.edu/wiki/resources/stl10_patches_100k.zip Sampled 8x8 patches from the STL-10 dataset (stl10_patches_100k.zip)]
''If you have not completed the exercise listed above, we strongly suggest you complete it first.''
''If you have not completed the exercise listed above, we strongly suggest you complete it first.''
Line 30: Line 29:
=== Step 1: Modify your sparse autoencoder to use a linear decoder ===
=== Step 1: Modify your sparse autoencoder to use a linear decoder ===
-
Copy <tt>sparseAutoencoderCost.m</tt> to the directory for this exercise and rename it to <tt>sparseAutoencoderLinear.m</tt>. Rename the function <tt>sparseAutoencoderCost</tt> in the file to <tt>sparseAutoencoderLinearCost</tt>, and modify it to use a [[Linear Decoders | linear decoder]]. In particular, you should change the cost and gradients returned to reflect the change from a sigmoid to a linear decoder. After making this change, check your gradients to ensure that they are correct.
+
Copy <tt>sparseAutoencoderCost.m</tt> to the directory for this exercise and rename it to <tt>sparseAutoencoderLinearCost.m</tt>. Rename the function <tt>sparseAutoencoderCost</tt> in the file to <tt>sparseAutoencoderLinearCost</tt>, and modify it to use a [[Linear Decoders | linear decoder]]. In particular, you should change the cost and gradients returned to reflect the change from a sigmoid to a linear decoder. After making this change, check your gradients to ensure that they are correct.
=== Step 2: Learn features on small patches ===
=== Step 2: Learn features on small patches ===

Latest revision as of 21:00, 21 June 2011

Personal tools