# Retinex Based Image Enhancement via General Dictionary Convolutional Sparse Coding
## 2 Related Work
### Convolutional Sparse Coding (CSC)  
An alternative to patch-based approaches is CSC, which is based on an image decomposition into spatially-invariant convolutional features, as explained in the following paragraphs. Compared to the atoms of a dictionary, the learned filters of our CSC scheme (Figure 1c) show a much richer variance (e.g., they span a larger range of orientations), which leads to better reconstructions.  
CSC models the signal of interest \(\alpha\) as a sum of sparsely-distributed convolutional features [19; 20; 21], that is \(\alpha\) is modeled as:  
\[\alpha=\sum_{k=1}^{K}d_{k}*z_{k}, \tag{4}\]  
The CSC problems are expressed in the form  
\[\begin{split}\operatorname*{arg\,min}_{d,z}&\sum_{w =1}^{W}\frac{1}{2}||x^{w}-\sum_{k=1}^{K}d_{k}*z_{k}^{w}||_{2}^{2}+\beta\sum_{ k=1}^{K}||z_{k}^{w}||_{1}\\ &\text{subject to }||d_{k}||_{2}^{2}\leq 1\quad\forall k\in\{1, \dots,K\}\end{split} \tag{5}\]  
where each example image \(x^{w}\) is represented as the sum of sparse coefficient feature maps \(z_{k}^{w}\) convolved with filters \(d_{k}\) of fixed spatial support. The superscripts indicate the example index \(w=1,\dots,W\), and the subscripts indicate the coefficient/filter map index \(k=1,\dots,K\). The variables \(x^{w}\in\mathbb{R}^{D}\) and \(z_{k}^{w}\in\mathbb{R}^{D}\) are vectorized images and feature maps, respectively, \(d_{k}\in\mathbb{R}^{S}\) represents the vectorized \(s\)-dimensional filters, and \(*\) is the \(s\)-dimensional convolution operator defined on the vectorized inputs. The constraint on \(d_{k}\) ensures the dictionary does not absorb all of the system's energy.  
As shown in [21], Equation (5) is reformulated as an unconstrained optimization problem. The constraint is then absorbed in an additional penalty indicator \(\text{ind}_{c}(\cdot)\) for each filter, defined on the convex set of constraints \(C=\{x\ |\ ||Mx||_{2}^{2}\leq 1\}\), where \(M\) is the \(\mathbb{R}^{S\times D}\) Fourier sub-matrix that computes the inverse Fourier transform and projects the result onto the spatial support of each filter.  
\[\operatorname*{arg\,min}_{d,z}\frac{1}{2}\sum_{w=1}^{W}\left(||x^{w}-d*Z^{w}|| _{2}^{2}+\beta||Z^{w}||_{1}+\text{ind}_{c}(d)\right) \tag{6}\]  
where, \(d=[d_{1}^{T}\ \dots\ d_{K}^{T}]^{T}\), \(d\in\mathbb{R}^{D\times 1}\), \(Z^{w}=[Z_{1}^{w}\ \dots\ Z_{K}^{W}]\) is a concatenation of Toeplitz matrices, each one expressing the convolution with the respective sparse coefficient map \(z_{k}^{w}(Z^{w}\in\mathbb{R}^{D\times DK})\). Accordingly, eliminating the sum over the examples (index \(W\)) by stacking the vectorized images in \(x^{\prime}=[x^{1T}\ \dots\ x^{W}]^{T}\) and coefficient maps \(Z^{\prime}=[Z^{1T}\ \dots\ Z^{W}]^{T}\) result in  
\[\operatorname*{arg\,min}_{d,z}\frac{1}{2}||x^{\prime}-d*Z^{\prime}||_{2}^{2}+ \beta||Z^{\prime}||_{1}+\text{ind}_{C}(d) \tag{7}\]  
Equation (7) derives a consensus optimization method for CSC, allowing the splitting of large-scale and high-dimensional CSC into smaller sub-problems [21]. The individual sub-problems can be solved efficiently using the distributed Fourier-domain formulation, with parallel workers. Consensus optimization makes CSC tractable to large problem sizes.