# Contrast Sensitivity Based Multiscale Base-Detail Separation for Enhanced HDR Imaging
## 4 Base-Detail Processing Using CSF Property  
The human visual system has the feature of the variable low pass filter and band pass filter to perceive contours of objects. In the case of low adapting luminance, the sharpness sensitivity of the eyes is more decreased than at a high adapting luminance. The FBF in the iCAM06 accelerates the HDR image rendering by using a piecewise-linear approximation and appropriate sub-sampling. However, this causes a blur phenomenon similar to the sharpness reduction at the low adapting luminance region in HDR images. For this reason, we designed a layer separation filter using the visual CSF property in the iCAM06. This filter is applied to the base-detail separation and detail enhancement. The filter is conducted as a discrete finite impulse response (FIR) filter by sampling the 1-dimensional spectral CSF curve in the 2-dimensional discrete Fourier transform (DFT) domain. The proposed separation filter has been established using the bilateral filter and the Barten's CSF. The equations are given in Equations (4) and (5):  
\[CSF_{L}(f,L_{a})=1.22\exp\Bigl{(}-(f-f_{s}(L_{a}))^{2}/f_{1}(L_{a})\Bigr{)}-a_{ 0}(L_{a})\exp\left(-f^{2}/f_{0}(L_{a})^{2}\right) \tag{4}\]  
\[a_{0}(L_{a})=2.53+2.02/(1+(L_{a}/21.97)^{-0.79}) \tag{5}\]  
\[f_{0}(L_{a})=1.03+1.11/(1+(L_{a}/15.34)^{-0.76}) \tag{6}\]  
\[f_{1}(L_{a})=13.64+17.17/(1+(L_{a}/19.03)^{-0.78}) \tag{7}\]  
\[f_{s}(L_{a})=-33.11+22.37/(1+(L_{a}/22.67)^{0.79}) \tag{8}\]  
Figure 3: Luminance contrast sensitivity function (CSF) predicted by [PERSON]’s model (Equations (1)–(3)) for stimulus of size 10 degree and different means. where \(f\) is the spatial frequency. \(L_{n}\) is adaptation luminance level. \(f_{0}(\cdot)\) and \(f_{1}(\cdot)\) are low and high standard deviation functions to control width of filter. \(f_{s}(\cdot)\) is the frequency shift function that controls enhancement frequency in accordance with the luminance level. \(a_{0}(\cdot)\) is the weighting function. The proposed CSF are fitted to [PERSON]'s CSF corresponding to luminance level. Because HDR images have wide luminance ranged surround, the sharpness compensation of the HDR images should be accomplished based on local average luminance. Signal intensity is linearly segmented into 'NB_SEGMENTS' steps for the range from \(L_{min}\) to \(L_{max}\), the predefined range of local adaptation luminance. The whole processing steps of a proposed method is shown below from Equation (9) to Equation (16). For image \(I\), \(L_{n}\) is the weighted intensity layer, \(I(L_{n})\) is obtained by the edge-stopping function, \(g_{\sigma_{n}}(\cdot)\). \(g_{\sigma}(x)=exp(-\frac{x^{2}}{2\sigma^{2}})\) is a Gaussian kernel with the standard deviation \(\sigma\). \(I(L_{n})\) is blurred by the spatial kernel function \(g_{\sigma_{m}}(\cdot)\) in the 2-dimensional DFT domain considering the sensitivity frequency shift effect of the visual CSF. Here, the spatial kernel deviation value of \(g_{\sigma_{m}}(\cdot)\) is scaled by the maximum sensitive frequencies between \(L_{n}\) and \(L_{min}\). Next, the detail layer from which the base layer of \(L_{n}\) level is removed from the intensity image is compensated according to the CSF sensitivity gain, \(Dg_{L_{n}}(\cdot)\) between CSFs for \(L_{n}\) and \(L_{min}\) of each \(L_{n}\) layer in a frequency domain. The minimum value of CSF sensitivity gain, \(Dg_{L_{n}}(\cdot)\) is set 1.0 to prevent detail reduction. Figure 4 represents proposed relative CSF curves and CSF sensitivity gain (\(Dg_{L_{n}}\)) graphs. In Equation (15) and Equation (16), the final base and detail layer are composed through a linear interpolation between the two closest values \(L_{n}\) of image \(I\). This is based on a piecewise linear approximation of the previous fast bilateral filter. \(\sigma_{r}\) is same as that of FBF for the same NB_SEGMENTS and \(\sigma_{s}\) is set at a value of 2% of the image size. The CSF filter function can be designed for dim surround (\(<5\) cd/m\({}^{2}\)).