• Buch, K. A., Sun J. C.-H. , and Thorne L. R. , 1995: Cloud classification using whole-sky imager data. Proc. Fifth Atmospheric Radiation Measurement Science Team Meeting, San Diego, CA, ARM, 35–39.

    • Search Google Scholar
    • Export Citation
  • Calbo, J., and Sabburg J. , 2008: Feature extraction from whole-sky ground-based images for cloud-type recognition. J. Atmos. Oceanic Technol., 25, 314.

    • Search Google Scholar
    • Export Citation
  • Carslaw, K. S., Harrison R. G. , and Kirkby J. , 2002: Cosmic rays, clouds, and climate. Science, 298, 17321737.

  • Cazorla, A., Olmo J. , and Alados-Arboledas L. , 2008: Development of a sky imager for cloud cover assessment. J. Opt. Soc. Amer. A, 25, 2939.

    • Search Google Scholar
    • Export Citation
  • Estrada, F. J., and Jepson A. D. , 2009: Benchmarking image segmentation algorithms. Int. J. Comput. Vision, 85, 167181.

  • Fawcett, T., 2006: An introduction to ROC analysis. Pattern Recognit. Lett., 27, 861874.

  • Heinle, A., Macke A. , and Srivastav A. , 2010: Automatic cloud classification of whole sky images. Atmos. Meas. Tech., 3, 557567.

  • Hoyt, D. V., 1978: Interannual cloud-cover variations in the contiguous United States. J. Appl. Meteor., 17, 354357.

  • Huo, J., and Lu D. R. , 2009: Cloud determination of all-sky images under low-visibility conditions. J. Atmos. Oceanic Technol., 26, 21722181.

    • Search Google Scholar
    • Export Citation
  • Kassianov, E., Long C. N. , and Ovtchinnikov M. , 2005: Cloud sky cover versus cloud fraction: Whole-sky simulations and observations. J. Appl. Meteor., 44, 8698.

    • Search Google Scholar
    • Export Citation
  • Kohavi, R., and Provost F. , 1998: Glossary of terms: Special issue on applications of machine learning and the knowledge discovery process. Mach. Learn., 30, 271274.

    • Search Google Scholar
    • Export Citation
  • Lee, S. U., Chung S. Y. , and Park R. H. , 1990: A comparative performance study of several global thresholding techniques for segmentation. Comput. Vision Graphics Image Process., 52, 171190.

    • Search Google Scholar
    • Export Citation
  • Li, C. H., and Lee C. K. , 1993: Minimum cross entropy thresholding. Pattern Recognit., 26, 617625.

  • Li, C. H., and Tam P. K. S. , 1998: An iterative algorithm for minimum cross entropy thresholding. Pattern Recognit. Lett., 18, 771776.

    • Search Google Scholar
    • Export Citation
  • Li, Z., Cribb M. C. , Chang F. L. , and Trishchenko A. P. , 2004: Validation of MODIS-retrieved cloud fractions using whole sky imager measurements at the three arm sites. Proc. 14th ARM Science Team Meeting, Albuquerque, NM, ARM, 1–6.

    • Search Google Scholar
    • Export Citation
  • Long, C. N., Sabburg J. M. , Calbo J. , and Pages D. , 2006: Retrieving cloud characteristics from ground-based daytime color all-sky images. J. Atmos. Oceanic Technol., 23, 633652.

    • Search Google Scholar
    • Export Citation
  • Otsu, N., 1979: A threshold selection method from gray level histograms. IEEE Trans. Syst. Man Cybern., 9, 6266.

  • Rossow, W. B., and Schiffer R. A. , 1991: ISCCP cloud data products. Bull. Amer. Meteor. Soc., 72, 220.

  • Sezgin, M., and Sanku B. , 2004: Survey over image thresholding techniques and quantitative performance evaluation. J. Electron. Imaging, 131, 146165.

    • Search Google Scholar
    • Export Citation
  • Shields, J. E., Johnson R. W. , Karr M. E. , and Wertz J. L. , 1998: Automated day/night whole sky imagers for field assessment of cloud cover distribution and radiances distributions. Proc. 10th Symp. on Meteorological Observation and Instrumentation, Phoenix, AZ, Amer. Meteor. Soc., 165–170.

    • Search Google Scholar
    • Export Citation
  • Slater, D. W., Long C. N. , and Tooman T. P. , 2001: Total sky imager/whole sky imager cloud fraction comparison. Proc. 11th ARM Science Team Meeting Proc., Atlanta, GA, ARM, 1–11.

    • Search Google Scholar
    • Export Citation
  • Souza-Echer, M. P., Pereira E. B. , Bins L. S. , and Andrade M. A. R. , 2006: A simple method for the assessment of the cloud cover state in high-latitude regions by a ground-based digital camera. J. Atmos. Oceanic Technol., 23, 437447.

    • Search Google Scholar
    • Export Citation
  • Stephens, G. L., 2005: Cloud feedbacks in the climate system: A critical review. J. Climate, 18, 237273.

  • Sylvio, L. M. N., Wangenheim A. V. , Pereira E. B. , and Comunello E. , 2010: The use of Euclidean geometric distance on RGB color space for the classification of sky and cloud patterns. J. Atmos. Oceanic Technol., 27, 15041517.

    • Search Google Scholar
    • Export Citation
  • Voss, J. K., and Zibordi G. , 1989: Radiometric and geometric calibration of a visible spectral electro-optic “fisheye” camera radiance distribution system. J. Atmos. Oceanic Technol., 6, 652662.

    • Search Google Scholar
    • Export Citation
  • Yang, J., Weitao L. , Ying M. , Wen Y. , and Qingyong L. , 2009: An automatic ground-based cloud detection method based on adaptive threshold (in Chinese). J. Appl. Meteor. Sci., 20, 713721.

    • Search Google Scholar
    • Export Citation
  • View in gallery

    The histograms of (top) cloud and (bottom) sky elements according to (left to right) the B/R ratio, EGD, and saturation features.

  • View in gallery

    (top to bottom) Typical bimodal and two unimodal images and their histograms.

  • View in gallery

    The framework of the hybrid thresholding algorithm.

  • View in gallery

    (top to bottom) Examples of ratio images. (a) Original images, (b) B/R ratio, (c) B − R, and (d) normalized B/R ratio. (top) The original image with noise, (middle) pixels with high pure blue, and (bottom) a randomly selected image.

  • View in gallery

    (top to bottom) Examples of the detection results. (a) Original images, (b) the ground truth for detection, (c) fixed thresholding of normalized B/R ratio with Tf = 0.250, (d) MCE, (e) HYTA, (f) EGD with Tf = 55.43, (g) saturation with Tf = 0.2512, and (h) R2B with Tf = 0.5755. Clouds are marked in white and skies are black except that clouds are colored in white and skies in blue for (e).

  • View in gallery

    The distributions of thresholds and deviations of accuracy for HYTA and MCE compared with the fixed thresholding. (a) Thresholds of MCE, (b) deviations of accuracy of MCE, (c) thresholds of HYTA, and (d) deviations of accuracy of HYTA.

  • View in gallery

    (left to right) Some detection results by HYTA on the UTILITY set: labeled as (a) good, (b) medium, or (c) bad. Top rows in each set contain the original images and bottom rows denote the detection results, in which clouds are colored in white and skies in blue.

All Time Past Year Past 30 Days
Abstract Views 0 0 0
Full Text Views 576 555 67
PDF Downloads 528 505 53

A Hybrid Thresholding Algorithm for Cloud Detection on Ground-Based Color Images

View More View Less
  • 1 School of Computer and Information Technology, Beijing Jiaotong University, Beijing, China
  • | 2 Institute of Atmospheric Sounding, Chinese Academy of Meteorological Sciences, Beijing, China
© Get Permissions
Full access

Abstract

Cloud detection is the precondition for deriving other information (e.g., cloud cover) in ground-based sky imager applications. This paper puts forward an effective cloud detection approach, the Hybrid Thresholding Algorithm (HYTA) that fully exploits the benefits of the combination of fixed and adaptive thresholding methods. First, HYTA transforms an input color cloud image into a normalized blue/red channel ratio image that can keep a distinct contrast, even with noise and outliers. Then, HYTA identifies the ratio image as either unimodal or bimodal according to its standard deviation, and the unimodal and bimodal images are handled by fixed and minimum cross entropy (MCE) thresholding algorithms, respectively. The experimental results demonstrate that HYTA shows an accuracy of 88.53%, which is far higher than those of either fixed or MCE thresholding alone. Moreover, HYTA is also verified to outperform other state-of-the-art cloud detection approaches.

Corresponding author address: Qingyong Li, School of Computer and Information Technology, Beijing Jiaotong University, Beijing 100044, China. E-mail: liqy@bjtu.edu.cn

Abstract

Cloud detection is the precondition for deriving other information (e.g., cloud cover) in ground-based sky imager applications. This paper puts forward an effective cloud detection approach, the Hybrid Thresholding Algorithm (HYTA) that fully exploits the benefits of the combination of fixed and adaptive thresholding methods. First, HYTA transforms an input color cloud image into a normalized blue/red channel ratio image that can keep a distinct contrast, even with noise and outliers. Then, HYTA identifies the ratio image as either unimodal or bimodal according to its standard deviation, and the unimodal and bimodal images are handled by fixed and minimum cross entropy (MCE) thresholding algorithms, respectively. The experimental results demonstrate that HYTA shows an accuracy of 88.53%, which is far higher than those of either fixed or MCE thresholding alone. Moreover, HYTA is also verified to outperform other state-of-the-art cloud detection approaches.

Corresponding author address: Qingyong Li, School of Computer and Information Technology, Beijing Jiaotong University, Beijing 100044, China. E-mail: liqy@bjtu.edu.cn

1. Introduction

Clouds, which cover more than 50% of the globe’s surface, play an important role in the hydrological cycle and the energy balance of the atmosphere–earth surface system because of the interaction of solar and terrestrial radiation (Rossow and Schiffer 1991; Carslaw et al. 2002; Stephens 2005). Most cloud-related research requires some sort of cloud observation, such as the amount and type of clouds in sky. These macroscopic parameters are observed traditionally by human observers. Human observation, however, is somewhat subjective and inconsistent. For instance, inconsistency with regards to cloud amount can be found when a same sky condition is evaluated by distinct observers (Hoyt 1978). The shortcomings of human observation, therefore, led to automatic cloud observation systems, which are applied to capture sky conditions and to analyze cloud parameters with digital images.

Sky-imaging systems are applied in automatic cloud observation using new hardware technologies, for example, charge-coupled devices (CCDs) and digital image processing techniques. Currently, there are two types of frequently referred imager systems: one is the whole-sky imager (WSI) series developed by the Scripps Institute of Oceanography, University of California, San Diego. WSIs measure radiances at distinct wavelength bands across the hemisphere and retrieve cloud characteristics (Voss and Zibordi 1989; Shields et al. 1998; Li et al. 2004; Kassianov et al. 2005). The other imager system is the total-sky imager (TSI) series, which are manufactured by Yankee Environmental Systems, Inc. (YES). TSIs provide color images for the daytime hemispheric sky conditions and derive fractional sky cover and other useful meteorological information (Long et al. 2006; Calbo and Sabburg 2008; Sylvio et al. 2010). In addition, a number of other ground-based sky imagers have also been developed in some other countries and institutes, such as the whole-sky camera (WSC; see Long et al. 2006; Calbo and Sabburg 2008; Heinle et al. 2010) and the all-sky imager (ASI; see Huo and Lu 2009; Cazorla et al. 2008). All of these sky imagers capture sky conditions with red–green–blue (RGB) color images. Therefore, cloud detection, which means the classification of each pixel in a cloud image into either “cloud” or “sky” elements, becomes a fundamental task for further application of sky imagers, because it is the precondition for deriving other information, such as cloud cover, cloud type, and cloud brokenness (Long et al. 2006).

At present, cloud detection is mainly based on thresholding techniques, in which a RGB cloud image is transformed into a single channel feature image, and then each pixel in the feature image is classified by a fixed threshold. There are three reputable features for cloud detection. First, the ratio of the red channel to the blue channel is commonly applied in most WSIs, TSIs, and WSCs (Buch et al. 1995; Slater et al. 2001; Long et al. 2006; Calbo and Sabburg 2008). In these approaches, the pixels whose red/blue ratios are less than a fixed threshold are labeled as sky; on the contrary, the pixels with greater ratios are labeled as cloud. Note that most TSI algorithms use different thresholds depending upon the relative position between pixels and the sun (Long et al. 2006). As a variation, Heinle et al. (2010) used the difference between the red (R) and blue (B) channel instead of the R/B ratio. Second, saturation that is one dimension in hue, saturation, and luminance (HSL) color space was proposed to assess the cloud cover (Souza-Echer et al. 2006). This approach characterized three classes (sky, cloud, and the third class obtained by exclusion) based on the respective saturation thresholds. Finally, Euclidean geometric distance (EGD) was recently put forward for the classification of sky and cloud patterns (Sylvio et al. 2010). Sylvio et al. (2010) observed that sky and cloud patterns occupied separated loci on the RGB color space; hence, they made use of the EGD and Bayesian methods to distinguish cloud from sky pattern. Because all of these methods detect clouds using fixed thresholds, we group them into a category with the name fixed thresholding methods.

There are some challenges for fixed thresholding methods. First, the cloud threshold, in the strict sense, is climate and camera dependent (Long et al. 2006). For example, if we simultaneously take an image of a sky with two digital cameras that are the same make and model, we can discern color differences between the two images. Second, white always tints the blue of the sky; furthermore, this process is complex and relates to many factors, such as typical aerosol loading and pressure depth of the atmosphere at a given location. As a result, cloud elements and sky elements interweave with each other in feature spaces (e.g., R/B ratio, saturation, and EGD).

Statistically, there is always considerable overlap between the distribution of cloud elements and that of sky elements in most feature spaces. We manually sampled cloud patches and sky patches from the UTILITY image set (more details about the UTILITY set are found in section 2), and computed the histograms of the B/R ratio, saturation, and EGD for cloud and sky elements separately. Figure 1 illustrates the distributions of cloud and sky in the three feature spaces. Overlap between the distributions of cloud and sky can be discerned in Fig. 1 for all three feature spaces.

Fig. 1.
Fig. 1.

The histograms of (top) cloud and (bottom) sky elements according to (left to right) the B/R ratio, EGD, and saturation features.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

The overlap implies that the above-mentioned fixed thresholding methods inevitably misclassify some pixels. In practice, the fixed thresholding methods are not capable of correctly detecting thin clouds (Sylvio et al. 2010). Alternatively, the adaptive thresholding method based on the Otsu algorithm (Otsu 1979) was investigated in our previous work and achieved better performance than the fixed B/R ratio thresholding for cumuliform and cirriform cloud images (Yang et al. 2009). The adaptive approach, however, does not perform well on other types of cloud genera, such as stratiform and clear sky images.

This paper puts forward the Hybrid Thresholding Algorithm (HYTA) for cloud detection. This algorithm combines fixed and adaptive thresholding methods to achieve better accuracy for all cloud genera. HYTA first transforms a RGB image into a normalized blue/red (B/R) ratio image, which can keep distinct contrast even with noise and outliers. Subsequently, a hybrid thresholding strategy, integrating fixed and the adaptive minimum cross entropy (Li and Lee 1993; Li and Tam 1998) thresholding algorithms is applied.

The HYTA methodology is presented in the next section. In section 3, we demonstrate the experimental results. Finally, we provide the conclusions of this research and suggest possible future investigations.

2. Data and methods

a. Experiment setup and image sets

Images used for development and evaluation of HYTA were collected from two sources: a specific and a general source. Images from the specific source were obtained from the WSCs, which were located in Beijing (39.80°N, 116.47°E) and Conghua (23.57°N, 113.62°E), China. The WSCs, developed by the Institute of Atmospheric Sounding at the Chinese Academy of Meteorological Sciences, are based on commercially available components. The basic component is a digital camera, which is equipped with a fisheye lens to provide a field of view larger than 180° and is enclosed by a weather protection box. The WSCs are programmed to acquire images at fixed intervals, and all images are stored in RGB color JPEG format with a resolution of 1392 × 1040 pixels. At present, we focus on cloud detection in the normal region of the WSC images, avoiding areas near the sun and the horizon, because these regions are too complicated to be automatically handled (Long et al. 2006; Heinle et al. 2010; Sylvio et al. 2010). Therefore, we manually cropped proper sections of a whole image.

The images from the general source are manually acquired by several photographers with common digital cameras. These images were taken from different locations and different cameras, whereas the specific source has fixed locations and devices. These general images can be regarded as possessing reasonable diversity and generalization. In addition, a number of images, downloaded from the Internet, are added in order to further increase the diversity of the image set.

Two different sets of images were constructed for analysis and evaluation. First, 1000 images—680 from the specific source and 320 from the general source—were selected by visual screening. Each image is chosen to be a typical sample of certain cloud genus, and the whole image set covers the following four categories: cumuliform, cirriform, stratiform, and clear sky. This image set, called UTILITY, is used to analyze the statistical characteristics of cloud and sky elements, and also is used to estimate the parameters of HYTA and other approaches. Second, 32 images are chosen from UTILITY and manually converted to binary mask images using a Voronoi polygonal region generator. In the mask images, cloud and sky elements are marked with 1 and 0, respectively. These images compose the BENCHMARK that is regarded as the ground truth, which is used to evaluate the detection performance. Note that BENCHMARK covers both specific and general sources and divides into the following four subsets: cumuliform, cirriform, stratiform, and clear sky (with 14, 9, 6, and 3 images, respectively).

b. The hybrid thresholding algorithm

1) Overview

Cloud images, according to their statistical characteristics, can be roughly divided into two groups: unimodal and bimodal. Unimodal images are generally made up of single elements (i.e., cloud or sky), while bimodal images are composed of both cloud and sky elements; for example, clear sky and most stratiform images can be regarded as unimodal, and cumuliform and most cirriform images are bimodal. Statistically, if we transform color images into certain feature images (e.g., B/R ratio) and investigate their histograms, the difference between unimodal and bimodal distributions is more readily observed. That is, the histogram of a unimodal image always has a single peak and a small variance, while the histogram of a bimodal image may have two or more peaks and a large variance. Figure 2 illustrates some typical unimodal and bimodal cloud images and their histograms.

Fig. 2.
Fig. 2.

(top to bottom) Typical bimodal and two unimodal images and their histograms.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

Unimodal and bimodal images show big differences in both their physical and statistical characteristics. Accordingly, it is reasonable to treat them with different algorithms. Bimodal images, from the view of image processing, are more accurately processed with adaptive thresholding algorithms, although these algorithms are not applicable to process unimodal images (Sezgin and Sanku 2004; Yang et al. 2009). Unimodal images, however, can be treated well with fixed thresholding because of the purity of sky conditions (Long et al. 2006), whereas fixed thresholding is not accurate for thin clouds and most cirriform images. HYTA applies separate thresholding schemes to unimodal and bimodal cloud images.

HYTA, illustrated in Fig. 3, includes two main subprocedures: normalization of B/R ratios and hybrid thresholding. First, the normalized B/R ratio is used to transform color images into ratio images to improve visual contrast and robustness to noise. Then, the hybrid thresholding procedure is carried out to distinguish clouds from sky. In this procedure, an input ratio image is identified as either unimodal or bimodal according to the standard deviation of the ratio image. Subsequently, fixed and minimum cross entropy (MCE) thresholding are applied to unimodal and bimodal images, respectively.

Fig. 3.
Fig. 3.

The framework of the hybrid thresholding algorithm.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

In terms of computation cost, HYTA has a linear computation complexity because it scans an input image twice. It is a kind of extremely fast algorithm, as fixed and MCE thresholding algorithms are.

2) The normalization of B/R ratio

Normalization of the B/R ratio is necessary to improve visual contrast and robustness to noise. Mathematically, the B/R ratio, denoted by λ (λ = b/r), ranges from [0, 255] where 0 ≤ b, r ≤ 255. Note that the value of r is increased by one unit if it equals zero to avoid dividing by zero. Statistical analysis results, however, show that the majority of pixels in cloud images fall in the range of [0, 5] (seen in the first column of Fig. 1). Pixels with large ratio λ can be regarded as outliers or noise. We find that these pixels always dramatically decline the contrast of ratio images and lead to difficulty in cloud detection. For example, a ratio image will be visually black if there is even one noise pixel with λ = 255 and the other pixels with λ < 5. Figure 4 shows some examples whose B/R ratio images are indistinct because of noise and pixels with large λ.

Fig. 4.
Fig. 4.

(top to bottom) Examples of ratio images. (a) Original images, (b) B/R ratio, (c) B − R, and (d) normalized B/R ratio. (top) The original image with noise, (middle) pixels with high pure blue, and (bottom) a randomly selected image.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

We propose the normalized B/R ratio
e1
where λ = b/r. The λN is a nonlinear monotonically increasing function of λ, which ranges from [−1, 254/256]. The range of λN is evidently narrower than that of λ. For instance, the interval (5, 255] for λ is compressed into the very small interval (2/3, 254/256] for λN. As a consequence, the normalized ratio image has distinct contrast and robustness to noise. Figure 4 shows comparisons between B/R ratio images and normalized ratio images.
Equation (1) can be rewritten as
e2
where b and r refer to the values of the blue and the red channel, respectively. Equation (2) can be taken as a normalization of the difference between the blue and red channel that is applied by Heinle et al. (2010). However, λN is invariant to additive lightness variations; in other words, λN will be constant if the values of b and r are changed by a same additive constant.

3) Hybrid thresholding procedure

An input ratio image is first identified as unimodal or bimodal according to its standard deviation. Table 1 presents the summary of the standard deviations of the normalized ratio images according to the four cloud categories based on UTILITY. The standard deviations for cumuliform and cirriform clouds are larger than those for stratiform cloud and clear sky. Cumuliform clouds are distinctly separated from stratiform clouds and clear sky by a proper threshold, whereas there is little overlap between cirriform clouds and stratiform clouds–clear sky. In our experiments, we set the standard deviation threshold to Ts = 0.03. An image with a standard deviation greater than Ts is considered bimodal, otherwise it is unimodal. After an input ratio image is categorized as either unimodal or bimodal, the HYTA algorithm splits into two branches—one for fixed thresholding and the other for MCE thresholding.

Table 1.

The summary of standard deviation of the normalized B/R ratio corresponding to cumuliform, cirriform, stratiform, and clear sky based on the UTILITY set.

Table 1.

In the first branch, a fixed threshold is statistically estimated and used for the unimodal images. Because the threshold is predefined and global for the whole dataset, some experimental or statistical methodologies, like those presented in Long et al. (2006) and Sylvio et al. (2010), can be applied to estimate it. In our experiments we manually sampled 500 cloud patches from UTILITY, calculated the mean μ and the standard deviation δ of their normalized B/R ratio values, and set the threshold Tf as Tf = μ + 3δ. We finally get Tf = 0.250. Therefore, the pixels in a unimodal image with λN < Tf are detected as cloud elements, otherwise the pixels are classified as sky elements.

In the other branch, the adaptive MCE thresholding algorithm is applied for the bimodal images. Thresholding is one of the fundamental techniques for image segmentation, and many thresholding techniques have been proposed in literature. Comprehensive surveys can be found in Lee et al. (1990) and Sezgin and Sanku (2004). The MCE thresholding algorithm is adopted in this research because it is robust and unbiased to histograms of images (Li and Lee 1993; Li and Tam 1998).

Let F = {f1, f2, … , fN} and G = {g1, g2, … , gN} be two discrete probability distributions on a set. The cross entropy between F and G is an information theoretic distance between the two distributions and is defined by
e3
The MCE thresholding algorithm selects a threshold by minimizing the cross entropy between the original image and its segmented image. It can be interpreted as being indicative of the preservation of information. Let IN be the normalized B/R ratio image and h(i) (i = 1, 2, … , L, where L is the number of ratio levels) be the corresponding histogram. Then the segmented image, denoted by Bt with t as the threshold value, is constructed by
e4
where x and y denote the coordinate of a pixel and μ(a, b) is defined as
JTECH-D-11-00009.1-eq1
The cross entropy between IN and Bt is then calculated by
e5
The MCE determines the optimal threshold t* by minimizing the cross entropy D(t). That is,
e6
Eliminating the constant terms in D(t) of Eq. (5), Eq. (6) can be simplified to
e7
where .

After the optimal threshold t* is determined according to Eq. (7), it is used to distinguish cloud elements from sky elements. Pixels whose normalized ratio values are less than t* are classified as clouds; otherwise, pixels are sky.

3. Results and comparisons

a. Evaluation metrics for cloud detection

Traditionally, cloud fraction, defined as the ratio of the detected cloud pixels to the total number of pixels in an image, is used as an evaluation metric for cloud detection, and fraction values estimated by observers are used as references (Souza-Echer et al. 2006). This type of evaluation scheme is not precise enough to measure the accuracy of a cloud detection algorithm. First, the fraction mixes up correctly and wrongly detected cloud elements. After all, there are some pixels that are detected as cloud but are sky in fact, and vice versa. Second, the reference fractions do not give the ground truth about the type of each pixel in an image. This work evaluates detection performance with three metrics derived from the confusion matrix, based on BENCHMARK.

The confusion matrix is used in the pattern recognition and machine learning communities (Kohavi and Provost 1998; Fawcett 2006). There are four possible outcomes from a cloud detection method, as follows:

  • a true positive (TP) denotes a correct outcome in which the detected pixel is cloud,

  • a false positive (FP) denotes an incorrect outcome in which the detected pixel is sky,

  • a true negative (TN) denotes a correct outcome in which the detected pixel is sky, and

  • a false negative (FN) denotes an incorrect outcome in which the detected pixel is cloud.

The four outcomes can be formulated in a 2 × 2 confusion matrix as in Table 2. The confusion matrix can be used to derive several evaluation metrics (Kohavi and Provost 1998). This paper adopts precision (Pr), recall (Rc), and accuracy (Ac). Precision is the probability that a detected cloud element is true; recall is the probability that a true cloud element is detected; and accuracy is the probability of both correctly detected cloud and sky elements. Respectively, Pr, Rc, and Ac are defined as
Table 2.

Confusion matrix of cloud detection.

Table 2.
e8
Accuracy is widely used as a metric for the evaluation of classification systems; higher accuracy means better performance. Precision and recall are often used together to evaluate image segmentation algorithms (Estrada and Jepson 2009). There is an inverse relationship between precision and recall. That is, it is possible to increase one at the cost of reducing the other. For example, a high threshold can cause high recall but low precision; conversely, a low threshold can lead to high precision and low recall. A classification system should provide a justifiable trade-off between precision and recall.

b. The performance of HYTA

HYTA integrates fixed and MCE thresholding, so the performances of fixed and MCE thresholding are separately presented at the same time for comparison. Note that the threshold of fixed thresholding takes the same value as that of HYTA, that is, Tf = 0.025. Figures 5a–e shows the ground truth and the detection results for six examples, which cover three classes: cumuliform, cirriform, or stratiform–clear sky. Odd rows demonstrate the best results for HYTA in each class, while even rows show the worst results. Two facts can be observed after visually comparing the detection results of the three methods. First, fixed and MCE thresholding are complementary. For example, fixed thresholding outperforms MCE thresholding for stratiform/clear sky as displayed in the last two rows; nevertheless, it is mostly worse than MCE for cumuliform and cirriform (the first, third, and fourth rows in Fig. 5). Second, HYTA shows the cooperative effect of fixed and MCE thresholding. The detection results of HYTA, displayed in Fig. 5e, are obviously more attractive than those of fixed or MCE thresholding alone. As for the images in the second and last rows, HYTA does not coincide with fixed thresholding, which leads to the best results, because certain parts of the images (e.g., the left top zone of the image in the second row, and right side of the image in the last row) are whitened by the sun and lead to an abnormally low ratio value for a sky element in these regions. A methodology to eliminate the influence of the sun will be researched in the future.

Fig. 5.
Fig. 5.

(top to bottom) Examples of the detection results. (a) Original images, (b) the ground truth for detection, (c) fixed thresholding of normalized B/R ratio with Tf = 0.250, (d) MCE, (e) HYTA, (f) EGD with Tf = 55.43, (g) saturation with Tf = 0.2512, and (h) R2B with Tf = 0.5755. Clouds are marked in white and skies are black except that clouds are colored in white and skies in blue for (e).

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

The superiority of HYTA can be further verified through the quantitative evaluation based on BENCHMARK. BENCHMARK is further divided into four subsets, that is, cumuliform, cirriform, stratiform, and clear sky, in order to probe into the specificity of each method. The average precision, recall, and accuracy values are calculated according to these four subsets and the whole set. Table 3 presents the detailed performance results. Two clear facts can be found in Table 3. First, HYTA achieves the best performance, with an accuracy of 88.53% for the whole set; furthermore, it comes out with a reasonable trade-off between precision and recall. Second, it is further confirmed that fixed and MCE thresholding are complementary. MCE thresholding shows better accuracy for cumuliform and cirriform images compared with fixed thresholding; nonetheless, it fails with stratiform clouds and clear sky. HYTA combines the merits of both fixed and MCE thresholding and presents a robust performance for all of the cloud categories. Note that values of precision and recall for clear sky take 0 because the number of TP for clear sky is 0.

Table 3.

Performance results of cloud detection based on BENCHMARK for the fixed thresholding, MCE thresholding, and HYTA algorithms. The number of images for cumuliform, cirriform, stratiform, and clear sky are 14, 9, 6, and 3, respectively.

Table 3.

Next, we investigate the distributions of thresholds and the deviations of accuracy for MCE and HYTA in BENCHMARK. Figures 6a,c display the thresholds of MCE and HYTA for each image in BENCHMARK, with the fixed threshold Tf acting as the baseline. Figures 6b,d illustrate the deviations of accuracy for MCE and HYTA with the accuracy of fixed thresholding as reference. Note that the x axis denotes the index of each image in BENCHMARK; furthermore, the four image index intervals [1, 14], [15, 23], [24, 26], and [27, 32] represent cumuliform clouds, cirriform clouds, clear sky, and stratiform clouds, respectively. In Fig. 6a, the thresholds of MCE for the cirriform clouds scatter on both sides of the baseline; however, their deviations of accuracy are positive (i.e., better than reference) as in Fig. 6b. On the contrary, the thresholds of MCE for clear sky are greater than Tf, and those for stratiform clouds are lower than Tf, but their deviations of accuracy are negative (i.e., worse than reference). In most cases, HYTA takes the thresholds of MCE for cumuliform and cirriform clouds and derives the thresholds from fixed thresholding for stratiform clouds and clear sky as in Fig. 6c, and HYTA shows better accuracy in Fig. 6d as a result. In short, preferred thresholds for cumuliform and cirriform clouds scatter in an interval so that MCE is a better choice, whereas those for stratiform clouds and clear sky can be fixed.

Fig. 6.
Fig. 6.

The distributions of thresholds and deviations of accuracy for HYTA and MCE compared with the fixed thresholding. (a) Thresholds of MCE, (b) deviations of accuracy of MCE, (c) thresholds of HYTA, and (d) deviations of accuracy of HYTA.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

We tested HYTA on the UTILITY set and had an expert visually evaluate the detection results because it is too laborious to construct the ground truth for the 1000 images in UTILITY. The detection results are subjectively grouped into one of the following three categories: good, medium, and bad. We obtained 707 good, 241 medium, and 52 bad images in this way. Figure 7 presents some representatives in the three categories. Our evaluation results demonstrate that HYTA addresses most images well, even for thin clouds, as shown in Fig. 7a. We also have to note that HYTA is not perfect for the images that are tinted by the sun as shown in Figs. 7b,c.

Fig. 7.
Fig. 7.

(left to right) Some detection results by HYTA on the UTILITY set: labeled as (a) good, (b) medium, or (c) bad. Top rows in each set contain the original images and bottom rows denote the detection results, in which clouds are colored in white and skies in blue.

Citation: Journal of Atmospheric and Oceanic Technology 28, 10; 10.1175/JTECH-D-11-00009.1

c. Comparison to related work

We compare our HYTA with the following reputable methodologies:

  • The fixed R/B ratio (R2B) considers the ratio of the red channel and the blue channel of a color cloud image, and sets an predefined threshold to determine cloud and sky elements (Long et al. 2006).

  • The saturation method takes the saturation component of HSL color space into account, and classifies pixels with a fixed saturation threshold (Souza-Echer et al. 2006).

  • EGD applies the distance of the RGB vector of a pixel to the main diagonal of the RGB cube to distinguish cloud elements from sky elements (Sylvio et al. 2010).

Note that all of the fixed thresholds (Tf) for the listed three methods are derived from UTILITY set by the statistical approach, as discussed in section 2b, and have , , and . Note that these thresholds here are not identical with those used in the original literature because the training images are different. They, however, are better choices for BENCHMARK in our experiments.

Figures 5e–h shows some representative examples of detection results for the four methodologies. We observe that the HYTA is more accurate than the other three approaches, though the HYTA is weakened by the whitening of the sun, as shown in the second and last rows.

Table 4 further presents the detection performances of the four methods. HYTA shows the best performance according to average accuracy on the whole BENCHMARK. Furthermore, HYTA also shows the best precision for cloud element detection, though the EGD algorithm has the best recall. Taking accuracy into consideration, saturation and R2B rank second and third place, while EGD shows the worst results. This result is not surprising if we delve into the distributions of the features. From a statistical viewpoint, a larger overlap between the distribution of cloud elements and that of sky elements means a larger misclassification, leading to a worse detection performance for a fixed thresholding method. Figure 1 illustrates that the EGD has the largest overlap compared with the B/R ratio (its inverse is the R2B ratio), and saturation. In contrast, HYTA selects an adaptive threshold according to an individual image, rather than a fixed one; as a consequence, it achieves a better performance. In summary, HYTA outperforms these state-of-the-art cloud detection approaches based on BENCHMARK because of its hybrid thresholding strategy.

Table 4.

Performance results of cloud detection on BENCHMARK for the R2B, saturation, EGD and HYTA.

Table 4.

4. Conclusions

We have proposed the Hybrid Thresholding Algorithm (HYTA) for cloud detection on ground-based color images, aiming at complementing fixed thresholding and adaptive thresholding algorithms. Fixed thresholding methods are weak for bimodal images (e.g., thin cloud, cirriform) and MCE fails to address most unimodal images. HYTA integrates fixed thresholding and minimum cross entropy (MCE) thresholding together, so it can be competent when applied to both unimodal and bimodal cloud images. Our experiments demonstrate that HYTA outperforms not only fixed and MCE thresholding alone, but also other state-of-the-art approaches, that is, R/B ratio thresholding (Long et al. 2006), saturation thresholding (Souza-Echer et al. 2006), and Euclidean geometric distance (Sylvio et al. 2010).

There are some challenges to HYTA that need to be investigated in the future. First, one possible improvement for HYTA is to explore a more elaborate classification method for unimodal and bimodal images. Second, an intelligent treatment for the area near the sun and horizon should be studied, such as the use of local thresholding methodologies.

Acknowledgments

The authors acknowledge the support from the National Natural Science Foundation of China (Grant 60805041), Basic Research Fund of Chinese Academy of Meteorological Sciences (Grant 2007Z001), and Special Technical D&R Project for Scientific Academies or Institutes of China (Grant NCSTE-2006-JKZX-303). They thank Ying Ma, Wen Yao, Yang Zhang, and Hongbo Cui for their work on cloud image collection, and they would also like to thank James Z. Wang and the anonymous reviewers for their constructive comments.

REFERENCES

  • Buch, K. A., Sun J. C.-H. , and Thorne L. R. , 1995: Cloud classification using whole-sky imager data. Proc. Fifth Atmospheric Radiation Measurement Science Team Meeting, San Diego, CA, ARM, 35–39.

    • Search Google Scholar
    • Export Citation
  • Calbo, J., and Sabburg J. , 2008: Feature extraction from whole-sky ground-based images for cloud-type recognition. J. Atmos. Oceanic Technol., 25, 314.

    • Search Google Scholar
    • Export Citation
  • Carslaw, K. S., Harrison R. G. , and Kirkby J. , 2002: Cosmic rays, clouds, and climate. Science, 298, 17321737.

  • Cazorla, A., Olmo J. , and Alados-Arboledas L. , 2008: Development of a sky imager for cloud cover assessment. J. Opt. Soc. Amer. A, 25, 2939.

    • Search Google Scholar
    • Export Citation
  • Estrada, F. J., and Jepson A. D. , 2009: Benchmarking image segmentation algorithms. Int. J. Comput. Vision, 85, 167181.

  • Fawcett, T., 2006: An introduction to ROC analysis. Pattern Recognit. Lett., 27, 861874.

  • Heinle, A., Macke A. , and Srivastav A. , 2010: Automatic cloud classification of whole sky images. Atmos. Meas. Tech., 3, 557567.

  • Hoyt, D. V., 1978: Interannual cloud-cover variations in the contiguous United States. J. Appl. Meteor., 17, 354357.

  • Huo, J., and Lu D. R. , 2009: Cloud determination of all-sky images under low-visibility conditions. J. Atmos. Oceanic Technol., 26, 21722181.

    • Search Google Scholar
    • Export Citation
  • Kassianov, E., Long C. N. , and Ovtchinnikov M. , 2005: Cloud sky cover versus cloud fraction: Whole-sky simulations and observations. J. Appl. Meteor., 44, 8698.

    • Search Google Scholar
    • Export Citation
  • Kohavi, R., and Provost F. , 1998: Glossary of terms: Special issue on applications of machine learning and the knowledge discovery process. Mach. Learn., 30, 271274.

    • Search Google Scholar
    • Export Citation
  • Lee, S. U., Chung S. Y. , and Park R. H. , 1990: A comparative performance study of several global thresholding techniques for segmentation. Comput. Vision Graphics Image Process., 52, 171190.

    • Search Google Scholar
    • Export Citation
  • Li, C. H., and Lee C. K. , 1993: Minimum cross entropy thresholding. Pattern Recognit., 26, 617625.

  • Li, C. H., and Tam P. K. S. , 1998: An iterative algorithm for minimum cross entropy thresholding. Pattern Recognit. Lett., 18, 771776.

    • Search Google Scholar
    • Export Citation
  • Li, Z., Cribb M. C. , Chang F. L. , and Trishchenko A. P. , 2004: Validation of MODIS-retrieved cloud fractions using whole sky imager measurements at the three arm sites. Proc. 14th ARM Science Team Meeting, Albuquerque, NM, ARM, 1–6.

    • Search Google Scholar
    • Export Citation
  • Long, C. N., Sabburg J. M. , Calbo J. , and Pages D. , 2006: Retrieving cloud characteristics from ground-based daytime color all-sky images. J. Atmos. Oceanic Technol., 23, 633652.

    • Search Google Scholar
    • Export Citation
  • Otsu, N., 1979: A threshold selection method from gray level histograms. IEEE Trans. Syst. Man Cybern., 9, 6266.

  • Rossow, W. B., and Schiffer R. A. , 1991: ISCCP cloud data products. Bull. Amer. Meteor. Soc., 72, 220.

  • Sezgin, M., and Sanku B. , 2004: Survey over image thresholding techniques and quantitative performance evaluation. J. Electron. Imaging, 131, 146165.

    • Search Google Scholar
    • Export Citation
  • Shields, J. E., Johnson R. W. , Karr M. E. , and Wertz J. L. , 1998: Automated day/night whole sky imagers for field assessment of cloud cover distribution and radiances distributions. Proc. 10th Symp. on Meteorological Observation and Instrumentation, Phoenix, AZ, Amer. Meteor. Soc., 165–170.

    • Search Google Scholar
    • Export Citation
  • Slater, D. W., Long C. N. , and Tooman T. P. , 2001: Total sky imager/whole sky imager cloud fraction comparison. Proc. 11th ARM Science Team Meeting Proc., Atlanta, GA, ARM, 1–11.

    • Search Google Scholar
    • Export Citation
  • Souza-Echer, M. P., Pereira E. B. , Bins L. S. , and Andrade M. A. R. , 2006: A simple method for the assessment of the cloud cover state in high-latitude regions by a ground-based digital camera. J. Atmos. Oceanic Technol., 23, 437447.

    • Search Google Scholar
    • Export Citation
  • Stephens, G. L., 2005: Cloud feedbacks in the climate system: A critical review. J. Climate, 18, 237273.

  • Sylvio, L. M. N., Wangenheim A. V. , Pereira E. B. , and Comunello E. , 2010: The use of Euclidean geometric distance on RGB color space for the classification of sky and cloud patterns. J. Atmos. Oceanic Technol., 27, 15041517.

    • Search Google Scholar
    • Export Citation
  • Voss, J. K., and Zibordi G. , 1989: Radiometric and geometric calibration of a visible spectral electro-optic “fisheye” camera radiance distribution system. J. Atmos. Oceanic Technol., 6, 652662.

    • Search Google Scholar
    • Export Citation
  • Yang, J., Weitao L. , Ying M. , Wen Y. , and Qingyong L. , 2009: An automatic ground-based cloud detection method based on adaptive threshold (in Chinese). J. Appl. Meteor. Sci., 20, 713721.

    • Search Google Scholar
    • Export Citation
Save