# Development of Fog Detection Algorithm Using GK2A/AMI and Ground Data
## 2 Materials and Methods
### Methods
We used 30 days for generating Vis_Comp as the Korean Peninsula is affected by the monsoon system, with frequent occurrence of clouds for more than 15 days, especially during summer. It is difficult to distinguish between fog and clouds, such as low cloud or ice cloud, with only \(\Delta\)VIS and DCD. Therefore, the difference (\(\Delta\)FTs) between the brightness temperatures of the top of the fog and surface temperature, local standard deviation (LSD), and normalized LSD (NLSD) were used. As the top height of the fog was lower than that of the clouds (low, middle, and high clouds), the \(\Delta\)FTs was used to distinguish the fog from low clouds. In general, the top of the fog is relatively smoother than that of the cloud because fog mainly occurs when the boundary layer of the atmosphere is stable. Thus, we used the LSD of the brightness temperature (LSD_BT11.2) and NLSD of the reflectance (NLSD_vis). NLSD implies the division of standard deviation by the average of 3 \(\times\) 3 pixels [2]. Clear pixels misclassified as fog in the first step were reclassified using CO\({}_{2}\) channel (13.3 \(\upmu\)m) and 8.6 \(\upmu\)m [29; 30]. BTD between 13.3 and 11.2 \(\upmu\)m was only used during daytime. BTD between 8.6 and 10.5 \(\upmu\)m was mainly used to distinguish between ice and water clouds [31; 32]. To distinguish fog from clear pixels or ice cloud (e.g., cirrus), a brightness temperature of 8.6 \(\upmu\)m was used as it can be used regardless of day and night. In addition, remaining pixels with optically thin middle-high clouds or partly clouded were removed using BTD between 10.5 and 12.3 \(\upmu\)m [13; 17]. Figure 3: Differentiation of fog detection algorithms, according to the solar zenith angle (SZA) and geographic location. In South Korea, various types of fog, such as radiation fog, occur, and although there are differences depending on geographic location, about 26.5 days of fog occur on average. According to [PERSON] and [PERSON] [33], radiation fog occurs frequently at a rate of 58.5% (especially, 71.3% in inland) for annual total fog events occurring in South Korea from 2015 to 2017. Even for thick fog with visibility less than 100 m, 62.4% is radiation fog (especially, 86.2% in inland). Most radiation fog dissipates rapidly after sunrise [34]. Thus, we applied a fog life cycle and strict threshold tests to remove the falsely detected fog after sunrise (SZA \(<\) 60\({}^{\circ}\)) assuming the non-occurrence of new radiation fog during the day. The life cycle test reclassified the newly detected fog after sunrise into non-fog pixels as fog disappeared after sunrise. NDSI was used to reclassify the fog pixels with vague properties into non-fog pixels. NDSI, which is usually used to detect snow, can be used for separating clear pixels from falsely detected fog pixels due to their different characteristics on the spectrum, compared to soil and fog [35]. As the algorithms were developed differently according to SZA and geographic location, a spatio-temporal discontinuity in the fog detection results was inevitable. Therefore, we applied the blending method to minimize the discontinuity at dawn and in the coastal area. Fog detection using satellite data during dawn/twilight and in coastal areas has been significantly difficult because of the unavailability of visible channel and DCD and complex background [36]. In order to mitigate the temporal discontinuity that occurs during dawn, the night fog detection results and the dawn fog detection results were blended under the assumption that the fog generated at night persists even during the dawn period. Additionally, in order to mitigate the spatial discontinuity occurring at the coast, the fog detection algorithm of land and sea was applied at the same time, and the two detection results were blended. In this case, if the results of both algorithms were the same, the final result remained the same as shown in Figure 4. Whereas, if the two detection results were different from each other, they were adjusted using the results of the surrounding detection.