Abstract
We consider the problem of using a factor model we call spike-and-slab sparse coding (S3C) to learn features for a classification task. The S3C model resembles both the spike-and-slab RBM and sparse coding. Since exact inference in this model is intractable, we derive a structured variational inference procedure and employ a variational EM training algorithm. Prior work on approximate inference for this model has not prioritized the ability to exploit parallel architectures and scale to enormous problem sizes. We present an inference procedure appropriate for use with GPUs which allows us to dramatically increase both the training set size and the amount of latent factors. We demonstrate that this approach improves upon the supervised learning capabilities of both sparse coding and the ssRBM on the CIFAR-10 dataset. We evaluate our approach's potential for semi-supervised learning on subsets of CIFAR-10. We demonstrate state-of-the art self-taught learning performance on the STL-10 dataset and use our method to win the NIPS 2011 Workshop on Challenges In Learning Hierarchical Models' Transfer Learning Challenge.
Introduction
In the early 2010s, researchers sought to bridge the gap between two dominant paradigms in unsupervised feature discovery: Sparse Coding and Restricted Boltzmann Machines (RBMs). Sparse Coding is effective but often couples sparsity with magnitude, while RBMs suffer from redundant "factorial posteriors" and intractable partition functions. This paper introduces Spike-and-Slab Sparse Coding (S3C), a directed generative model designed to combine the "explaining away" property of directed models with a flexible prior that decouples sparsity from feature magnitude.
The S3C Model and Inference
The S3C model defines a visible vector $v$ generated by two latent variables: a binary "spike" $h \in \{0, 1\}$ and a real-valued "slab" $s$. The reconstruction is modeled as $v \approx W(h \circ s)$. This structure allows the model to control how often a feature is active (via the spike) independently of its intensity (via the slab). Unlike standard sparse coding, S3C uses a bias parameter $b$ to control activity and separate parameters ($\mu$ and $\alpha$) to govern the distribution of active values.
To make this model scalable, the authors developed a parallel variational inference scheme suitable for GPUs. Unlike traditional sequential updates, S3C uses damped parallel updates with a clipping mechanism to maintain stability and prevent oscillations during the E-step.
Experimental Results
The S3C model was evaluated on several benchmarks, including CIFAR-10, STL-10, and the NIPS 2011 Transfer Learning Challenge. On CIFAR-10, S3C achieved a test accuracy of 78.3%, outperforming the spike-and-slab RBM (76.7%) and matching highly-tuned sparse coding systems. The model's "explaining away" property leads to cleaner, less redundant features compared to undirected models.
S3C demonstrated exceptional performance in semi-supervised and transfer learning settings, winning the NIPS 2011 Transfer Learning Challenge with 48.6% accuracy. Visualizations of the inference process confirm that the "explaining away" effect incrementally drives the representation to become sparser over successive iterations, a process critical for high-quality feature extraction.
Conclusion
S3C bridges the gap between directed and undirected feature learning models. By decoupling sparsity from magnitude and introducing a GPU-friendly inference algorithm, it provides a scalable and effective tool for unsupervised feature discovery. While the variational EM process is more computationally intensive than simple feed-forward networks, its superior performance in low-data and transfer learning regimes highlights the value of structured generative priors.
Summary updated