# Image Dehazing and Enhancement Using Principal Component Analysis and Modified Haze Features
## 3 Haze Removal Using PCA and Haze-Relevant Features
### Transmission Estimation Using Random Forest  
In this sub-section, we describe the haze-relevant features to accurately estimate the transmission. [PERSON] et al. estimated the haze-relevant features from thirteen differently scaled spaces at the cost of a high computational overhead [4]. On the other hand, the proposed method extracts the haze-relevant features of the dark channel and local contrast in a single in-scale haze image. The haze components decrease the contrast of an input image by scattering the light in the atmosphere. For that reason, the proposed method uses the local maximum contrast to train the random forest, which estimates the contrast enhanced transmission. The local maximum contrast is defined as  
\[L(x)=\max_{y\in\{\Omega(x)\}}(\|g(x)-g(y)\|_{2}^{2}), \tag{8}\]  
where \(\Omega\) represents the neighborhood region with center \(x\). The local maximum contrast feature represents the variance between the center and the surrounding pixels in the patch. The haze-relevant features to train the random forest are extracted from the synthesized haze patches based on (1) [4]. The model to synthesize a haze patch is defined as  
\[p_{g}=tp_{f}+A(1-t), \tag{9}\]  
Figure 3: Comparative results of the atmospheric light estimation to remove haze. The top row shows the estimated atmospheric light using existing and proposed methods. The second row shows dehazed images using (3) and estimated atmospheric light of the top row: (**a**) input haze image [16], reproduced with permission from [16], IEEE, 1969 (**b**) [PERSON]’s method [11], (**c**) [PERSON]’s method [15], and (**d**) the proposed method. where \(p_{g}\) represents the synthesized hazy patch; \(p_{f}\) is the haze-free patch; and \(t\in[0.1,0.9]\) is the range of transmission. The haze-relevant features of dark channel and local maximum contrast extracted from synthesized haze patches are used as the training data in the random forest. However, if an object is close to the camera, the light ray travels through less particles which results in a high transmission value. In addition, since a very high transmission value results in over-dehazing, the correspondingly dehazed region looks unnatural [1]. For that reason, we constrained the range of transmission from 0.1 to 0.9 to synthesize the haze patch. The color vector of the atmospheric light in a synthesized patch is supposed to be \([1,1,1]\), since the synthesized patch cannot adaptively estimate \(A\) for each patch. To solve this problem, the proposed method performs normalization by estimating the atmospheric light on the haze image to prevent brightness saturation. Moreover, the estimated transmission tends to result in a blocking artifact, because the transmission is estimated using the random forest with the haze-relevant features in a patch-wise manner. For that reason, the proposed method uses weighted guided filtering to refine the initial transmission [17]. Figure 4 shows the transmission estimation using the proposed haze-relevant features and random forest and the training of random forest using the haze-relevant features extracted from the synthesized haze patches. In this work, we used 100 decision trees for the random forest. In the random forest regression process, selection of good features can reduce the training time [18]. Figure 5 shows that the number of haze-relevant features used in the proposed method is related to the prediction of the transmission compared with existing method. We used the quantity 'importance' as a measure of each feature based on the variation of out-of-bag (OOB) error, which means that it is averaged and divided by the standard deviation over the all trees [4]. The multiscale dark channel and local contrast features, denoted by \(D(x)\) and \(L(x)\) in Figure 4, respectively, have significantly different importance values, as shown in Figure 5. It can be seen from the feature importance that the features on a certain scale do not have a significant effect on the learning-based prediction results.