Next Article in Journal
Bistatic Radar Observations Correlation of LEO Satellites Considering J2 Perturbation
Next Article in Special Issue
Correlation Filter of Multiple Candidates Match for Anti-Obscure Tracking in Unmanned Aerial Vehicle Scenario
Previous Article in Journal
Leadership Selection with the Fuzzy Topsis Method in the Hospitality Sector in Sultanahmet Region
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Absent Color Indexing: Histogram-Based Identification Using Major and Minor Colors

1
Graduate School of Information Science and Technology, Hokkaido University, Sapporo 060-0814, Japan
2
School of Artificial Intelligence, Changchun University of Science and Technology, Changchun 130022, China
*
Author to whom correspondence should be addressed.
Mathematics 2022, 10(13), 2196; https://doi.org/10.3390/math10132196
Submission received: 24 May 2022 / Revised: 16 June 2022 / Accepted: 21 June 2022 / Published: 23 June 2022

Abstract

:
The color histogram is a statistical behavior for robust pattern search or matching; however, difficulties have arisen in using it to discriminate among similar objects. Our method, called absent color indexing (ABC), describes how to use absent or minor colors as a feature in order to solve problems while robustly recognizing images, even those with similar color features. The proposed approach separates a source color histogram into apparent (AP) and absent (AB) color histograms in order to provide a fair way of focusing on the major and minor contributions together. A threshold for this separation is automatically obtained from the mean color histogram by considering the statistical significance of the absent colors. After these have been separated, an inversion operation is performed to reinforce the weight of AB. In order to balance the contributions of the two histograms, four similarity measures are utilized as candidates for combination with ABC. We tested the performance of ABC in terms of the F-measure using different similarity measures, and the results show that it is able to achieve values greater than 0.95. Experiments on Mondrian random patterns verify the ability of ABC to distinguish similar objects by margin. The results of extensive experiments on real-world images and open databases are presented here in order to demonstrate that the performance of our relatively simple algorithm remained robust even in difficult cases.

1. Introduction

Pattern search or matching is the task of finding targets through the use of images or through statistic or deterministic features extracted from images. Proposed image features for pattern search have included gray features [1], texture features [2], color features [3], and convolution features [4], where color features provide universally successful cues for identification of individuals in many applications. These have been extensively utilized in pattern search, computer vision, and image processing [5,6,7]. Analysis of color features plays a vital role in various tasks, including object matching, background subtraction, video tracking, and image retrieval [8,9,10].
Among color features, color histograms, a statistical measure of color distribution in images, have been widely used to describe color information. Color histograms are beneficial in that the color distribution in the template image is recorded without complicated learning processes, they feature strong robustness against object deformation and scale changes, and they provide effective statistics for utilizing discrete color distributions or histograms over a given color space. Color histogram-based approaches [11] can thus be effectively used to search for objects. However, these approaches reduce performance in discriminatin between similar objects, because any histogram trades positional information about the pixels for flexibility in matching. Swain et al. [12] proposed a combination of color histograms and intersection for searching a target location by histogram, where each bin represents coarse color frequencies in a given color space or system. Although such color indexing (CI) works well with changes in size or posture, it has difficulties handling changes in noise and illumination. To address these problems, Stricker et al. [13] used a relation of color histogram bins to generate a cumulative color histogram (CCH), whereby fixing the color order accumulates bins with smaller color frequencies into bins with relatively larger color values. This reduces sensitivity to noise interference and illumination changes, while the accumulated histogram reduces sensitivity in the process of object discrimination. The color co-occurrence histogram (CH) [14] method utilizes distance information of pairs of certain colored pixels in an image space to generate a color co-occurrence histogram and set a tolerance parameter to apply occlusion and deformation conditions in the algorithm. This can be costly in terms of computation time, and although the process of classifying colors uses Euclidian distances in RGB space, it can sometimes misclassify colors. Han et al. [15] introduced the fuzzy color histogram (FCH) based on the fuzzy c-means clustering algorithm, where an adjustable fuzzy membership matrix is defined to deal with different noise interferences and applications. Verma et al. [16] improved the fuzzy color histogram method (TFCM) and combined it with a spatial filter to solve the illumination problem for template matching. A triangular membership function is proposed to connect each bin for fuzzy logic implementation in a color histogram. The above-mentioned color histogram-based methods focus on bins with high contribution or frequency to design similarity measures.
Meanwhile, numerous methods based on the merits of color histograms have been proposed. Wang [17] introduced an image retrieval method based on color histograms of local feature regions and combined it with a Harris–Laplace detector to obtain spatial information before using the color histograms. The scheme in the method proposed by Varish et al. [18] used a color histogram and the wavelet transform method, applying color and texture features to enhance performance. Liu et al. [19] combined color histograms with local binary pattern-based features for better classification. This approach generally shows the possibility of combining color histograms or features with other schemes in classification tasks, to which our method for utilizing absent colors as a new feature type may contribute. Generally, these are not pure ways of using color histograms, and instead combine them with other features to achieve experimental results based on color histograms. This makes the overall algorithm more complex, preventing advantages in terms of computation time.
In this research, we explore ABC as a color feature for use in robust search or matching methods for objects with varying sizes, postures, and levels of occlusion in the scene. The key contribution of this study is that the proposed approach provides a balanced method of focusing on the relative importance of AP and AB by separating the original color histogram. In our prior work [20,21], ABC was formulated as the decomposition of a color histogram into two disjointed histograms using fixed parameters to achieve good performances in terms of feasible matching. In this study, we developed an automatic threshold, h T , designed to obtain more effective absent colors. In particular, we propose a more sophisticated version involving four specific techniques, including a mean color histogram, a novel algorithm based on statistical significance as defined for the sorted mean color histogram, a trial to investigate the availability of representative similarity measures combined with the proposed method, and a statistical treatment of the margin obtained by matching. The results of an evaluation of actual scenes and datasets are provided here in order to demonstrate the robust performance of our proposed ABC method.

2. Absent Color Indexing

The motivation behind our proposed approach is to enhance colors in cases where the objects to be searched have few positive features with existing color features. For example, when identifying individuals, eye color is not a major color feature by volume, however, it can provide a significant feature for identification.

2.1. Definition of Absent Colors

By introducing absent colors to realize this idea, we propose a novel approach to utilizing color histograms for robust pattern identification. This approach focuses on low-frequency colors in any two histograms of the target image. When evaluating histogram similarity, there must be four conditional combinations with respect to high and low frequencies in their bins. If both bins include high frequencies, they have high similarity, and if one is low and the other is high, it provides a low contribution to the total similarity. The case where both have low frequencies is conventionally evaluated as having a low contribution to similarity, however, the recognition of this as a common characteristic in our trials formalizes their treatment in similarity evaluations as an effective new approach. However, contamination by additional noise must be prevented in histograms when designing algorithms, because noise can easily influence such low frequencies.
Table 1 defines histograms H and G in the same color space or specification as consisting of high-frequency bins ( h AP and g AP ), low-frequency bins ( h AB and g AB ), and bins with no entities (0 and 0). Below, we propose a detailed scheme for defining these using a reasonable threshold value. As Table 1 shows, we define apparent colors (AP) as those in high-frequency bins, while colors in low- and null-frequency bins provide candidate absent colors (AB). There are nine possible arrangements of bins having the same colors, as shown in Table 1. In the top row and the leftmost column, every pair includes h AP or g AP , which are evaluated for similarity in almost all methods based on color histograms as features; if both bins are AP, then their contribution to similarity may be larger, while those including an AB element make a lower contribution. As mentioned in the previous section, our motivation here is to focus on other items in the table, namely, those such as ( h AB , g AB ) where both elements are AB. Such pairs are conventionally evaluated as minor elements in similarity calculations. Note that the last possible combination, 0 and 0, is never evaluated in any similarity evaluation scheme, because they represent colors not present in target images and are thus beyond the scope of consideration.

2.2. AP and AB Histograms

Illumination effects are handled by transforming RGB images to CIE L*a*b* color space and removing the L* channel, avoiding sensitivity reduction by enhancing the contribution of absent colors. We use the a* and b* channels to establish a two-dimensional color space from the CIE L*a*b* color space. When establishing many color features in color statistics, the CIE L*a*b* color space has a broader color range that is closer to human vision, allowing brightness to be separated as an independent coordinate (the L* channel).
As an example, Figure 1 shows two images, 1 and 2. Let their color space have β 1 × β 2 bins or quantization. In order for images 1 and 2 to be evaluated as matched or unmatched, their two-dimensional color histograms H = h i j i , j = 1 , 1 , , β 1 , β 2 and G = g i j i , j = 1 , 1 , , β 1 , β 2 are represented in terms of the relative frequencies of classified colors in their bins, confirming their summation to be unity. Moving forward, for explanation purposes we use H here as a representative example. Figure 2 shows the relative histograms, H and G, for images 1 and 2, respectively.
From the original two-dimensional color histogram H, we create a pair of two-dimensional histograms, H = H P + H , H P = h i j P , and H = h i j as complements. We have omitted the subscripts i and j in the formula for simplicity and to avoid confusion.
h P = h ( 1 ϕ ( h ) ) = h ϕ ( h ) ¯ ,
h = h ϕ ( h ) ,
where ϕ ( x ) is an indicator function that shows classification such that ϕ ( x ) = 1 if x h T and ϕ ( x ) = 0 otherwise. The threshold value, h T , is an important parameter in this study and is defined in Section 2.3. Note that the initial values of the other elements without any indication in the above definition are set to 0. H P includes major colors frequently observed in image 1, while H contains minor colors that are denoted as “absent” colors because their occurrence is infrequent within the image. Both have the same structure as the two-dimensional histogram H. The elements h P and h represent the color frequencies. We expect to systematically and effectively utilize information included in the histogram at low frequencies through the decomposition process.
From H , we intend to make an opposite counterpart for the major color histogram as a complementary feature in the original histogram. However, certain special cases, such as zero frequency, should be considered. To briefly explain the cases of zero frequency ( h = 0 ) during the inversion process of the absent color histogram H , we temporarily assume that H , H, and G are one-dimensional histograms only in Figure 3.
In the first case (I) shown in Figure 3, if h = 0 and h > h T , then h N = 0 ; In cases (II) and (III), if h = 0 , h = 0 and g > 0 , then h N = h T ; finally, in case (IV), if h = 0 , h = 0 and g = 0 , then h N = 0 . Table 2 summarizes these three transformations to provide a clear explanation.
After the above-mentioned inverting process, the absent color histogram H N = h i j N is defined to represent small or zero frequencies in the original one, as follows:
h N = ( h T h ) ϕ ( h ) ψ ( h ) + h T ψ ( h ) ¯ ψ ( g ) .
Here, ψ ( x ) is another indicator function that satisfies the following conditions: ψ ( x ) = 1 if x > 0 ; otherwise, ψ ( x ) = 0 . Finally, it is necessary to normalize both H P and H N to satisfy the condition that all components should sum to 1.
Figure 4 shows major color histograms, H P and G P , and absent color histograms, H N and G N , for images 1 and 2, respectively.

2.3. Threshold Definition

In the algorithm described in the last section, the threshold, h T , plays a main role in defining apparent and absent colors. This section describes how to define h T in order to provide a meaningful algorithm with effective performance. We first introduce the mean color histogram, M, to find an averaged tendency of the color distributions in two histograms to be compared, then use it realize a stable definition of the threshold. M = m i j i , j = 1 , 1 , , β 1 , β 2 is defined as
m i j = h i j + g i j 2 .
Generating the mean color histogram is a critical phase before threshold selection. The proportion of each color in the histogram is statistically analyzed for matching images, thereby improving the rationality and dynamism of threshold determination and guaranteeing the accuracy of the final similarity measurement.
We next convert the two-dimensional histogram M to a sorted one-dimensional histogram M sorted , as follows:
M sorted = m i 1 sorted m i sorted .
The threshold value, h T , can be defined by the following equation through use of an order index s related to a significant rate α , by which we can separate the set of all bins into sets of apparent and absent colors by considering the rarity of absent colors in the images.
h T = m s sorted + m s + 1 sorted 2 .
s = a r g m i n i = 1 s m i sorted 1 α .
Using parameter s, a stable decomposition can be performed with no “chattering” near the threshold value in comparison with a constant threshold. In the definition of the absent color histogram, because zero frequency plays an important role in eliminating any noise effects, we must remove near-zero frequencies in the absent color histogram. For example, we compare frequencies as 0.2 × h T in our experiments. Figure 5 shows the mean color histogram for histograms H and G. Figure 6 is a Pareto chart [22] for this example. We can use this information to determine the significant rate, α , which represents effectiveness in revealing the rareness of absent colors and contributes to setting of the threshold value.
Note that the mean color histograms can be used both to derive the threshold, h T , and to calculate similarities based on apparent and absent colors, as described in the next section.

2.4. Similarity Measures

Many measures for testing similarity between two histograms or probability density functions have been proposed, including intersection, chi-square distance, Jensen–Shannon divergence, and Bhattacharyya distance. This section describes these measures in combination with our ABC in order to demonstrate its universality in evaluating the similarity of images, as described in Section 3.2. We expect this universality of ABC to make it useful as an effective scheme for many applications.

2.4.1. Intersection

Intersection [23] has been used in many studies and applications because of its simplicity. It is defined for two same-sized histograms, H and G, as follows:
I H , G = i , j = 1 , 1 β 1 , β 2 m i n h i j , g i j .
For the two histogram types proposed in this paper, we define a scheme for combining the two intersections using weighting coefficients, as follows:
S = w P I H P , G P + w N I H N , G N ,
where w P and w N are weights for balancing the two types of intersections using the constraint w P + w N = 1 .

2.4.2. Chi-Square Distance

The chi-square test is a non-parametric test that is mainly used to compare two or more sample rates. In order to measure similarity between two histograms, we use the χ 2 statistic to observe frequencies. We define our version using the mean color histogram as follows:
χ 2 H , G = i , j = 1 , 1 β 1 , β 2 h i j m i j 2 m i j + i , j = 1 , 1 β 1 , β 2 g i j m i j 2 m i j ,
where m i j is the element of the mean color histogram. Equation (10) can be simplified as
χ 2 H , G = i , j = 1 , 1 β 1 , β 2 h i j g i j 2 h i j + g i j .
The total distance between the histograms is defined using the following weights:
D χ 2 = w P χ 2 H P , G P + w N χ 2 H N , G N .

2.4.3. Jensen–Shannon Divergence

JS divergence [24] is a symmetric divergence measurement based on Kullback–Leibler divergence [25]. By calculating divergences between histograms, a larger divergence indicates smaller correlative relation and smaller similarity between the histograms. This is defined as
D KL H G = i , j = 1 , 1 β 1 , β 2 h i j l o g h i j g i j .
We define a particular version of JS divergence as follows using the mean color histogram M:
D JS H , G = 1 2 D KL H M + 1 2 D KL G M .
In this formula, the antilogarithm cannot be zero in logarithm calculations such that l o g h i j g i j can take a relatively minimum value. The JS divergence-based distance between the histograms is defined as
D JSD = w P D JS H P , G P + w N D JS H N , G N .

2.4.4. Bhattacharyya Distance

In statistics, the Bhattacharyya distance [26] is often used to measure the dissimilarity of two discrete or continuous probability distributions. It is closely related to the Bhattacharyya coefficient, which measures overlap between two statistical samples or populations. The Bhattacharyya distance can be used to determine relative relationships between two samples or to determine differences between two classes. Thus, the two histograms can be considered as discrete probability distributions; the formula is
BD = l n B C H , G ,
where 0 BD , 0 BC 1 and BC H , G is the Bhattacharyya coefficient,
BC H , G = i , j = 1 , 1 β 1 , β 2 h i j g i j .
The distance between two sets of apparent and absent color histograms is defined as
D B D = w P BD H P , G P + w N BD H N , G N .

3. Experimental Evaluation

In this section, we consider the numerous challenges of ABC matching. In order to analyze the performance of our method, we derive a signal-to-noise (SNR) formula for adding reasonable noise to the Mondrian random pattern, as shown in Figure 7. We utilize three common measurements, namely, the F-measure, Margin, and Fisher ratio (FR), to explain the essential strengths of the ABC. Finally, we utilize real data to evaluate the matching effect of the ABC. The pseudo-code of ABC approach is shown in Algorithm 1.
Algorithm 1: Proposed ABC approach
  • Input: Reference image S R and compared image S S .
  •          Initial parameters: β 1 = 10 , β 2 = 10 , α = 0.2 ,
  •           w P = 0.6 , w N = 0.4
  • Output: Target location L T in the searched image.
  • repeat
  •    1: Crop the compared image from position ( i , j ) in the scene.
  •    2: Generate two-dimensional color histograms H and G by a* and b* channels.
  •    3: Divide color histograms into apparent color histograms H P , G P and absent color histograms H , G .
  •    4: Invert absent color histograms H and G to H N and G N .
  •    5: Calculate similarity R ( i , j ) by H P and G P , H N and G N .
  • until all locations are scanned, then find position L T with m a x ( R ( i , j ) ) ;

3.1. Preparation of Signal and Noise

We first describe a color image, I t = t i j . We denote I t by signal I s = s i j , while noise I n = n i j is defined as
I t = I s + I n .
The variance of image I t is represented as
σ t 2 = E I t μ t 2 = 1 m n i = 0 m 1 j = 0 n 1 I t i , j μ t 2
where μ t = μ s + μ n is the average value in image I t , μ s and μ n are the average values of I s and I n , E I n = μ n = 0 describes the noise distributions obeyed by certain balanced and unbiased Gaussian distributions, and m and n are the sizes of the images. As mentioned in Equation (20),
σ t 2 = E I s + I n μ s + μ n 2 = E I s μ s 2 + 2 E I s μ s I n μ n + E I n μ n 2 = E I s μ s 2 + E I n μ n 2 = σ s 2 + σ n 2 ,
where σ s 2 and σ n 2 represent the variance of the signal and noise in image I s and I n . The formulas are calculated as
σ s 2 = 1 m n i = 0 m 1 j = 0 n 1 I s i , j μ s 2 .
σ n 2 = 1 m n i = 0 m 1 j = 0 n 1 I n i , j μ n 2 .
The signal-to-noise ratio (SNR) is calculated as
S N R = 10 log σ s 2 σ n 2 = 10 log σ t 2 σ n 2 σ n 2 = 10 log σ t 2 σ n 2 1 .
Next, we analyzed the standard deviations σ n of noise in stationary background regions of the datasets [27,28], where we collected the small regions of interest (ROI) with sizes of 100 , 100 at the same positions in their background without any moving things: 61 , 531 in 50 frames of Biker, and 1 , 1 in 50 frames of Walking, respectively. Then, σ n can be calculated from numerous estimated noise values in the difference images; I n = I t I t ¯ . σ t is from one of 50 images in each dataset.
Table 3 shows the SNR in the sampled images of these databases. The average value of SNR in these two datasets is 36.01. In order to add noise to the noise-free Mondrian random pattern, we utilized the knowledge on noise obtained from Table 3 and thereafter added the noise of unbiased Gaussian distributions to the individual channels of the color image by SNR = 36, 33, and 30, where a reduced SNR implies increased noise.

3.2. Evaluation of ABC in Combination with Four Similarity Measures

In these experiments, we added artificial noise to the original images in order to investigate the performance of our method against others. Figure 7 shows an example of a synthetic Mondrian random pattern with no structures except for a colored circle as an elemental shape.
We next add noise to the color image. We first separate the individual channels of the color image and then add unbiased Gaussian noise of SNR = 36, 33, and 30 to each channel before finally merging the channels into a color image. Therefore, CI, CCH, TFCM, and ABC can be tested by use of these Mondrian random patterns embedded as typical additional noise. We tested four similarity measures, as follows: first, reference images of size 50 × 50 in Figure 7 were randomly selected, then searches were performed for the best matching positions in each noisy version. To evaluate each similarity measure, we use the F-measure, as follows:
P r e c i s i o n = T P T P + F P
R e c a l l = T P T P + F N
F - m e a s u r e = 2 × P r e c i s i o n × R e c a l l P r e c i s i o n + R e c a l l ,
where TP and FP indicate the numbers of true positives and false positives, respectively, defined by a threshold value of intersection over union (IoU). TP can thus have an IoU exceeding 0.75, while FP has a value below threshold 0.25. FN represents the number of false negatives, where TP+FN is the entirety of the target image. F-measure is the harmonic mean of Precision and Recall.
Table 4 shows a performance evaluation in matching using ABC-based similarity measures under different noise conditions. We found that in all cases, ABC could be used in combination with these similarity measures using experimental parameters I = 10 , J = 10 , α = 0.2 , w AP = 0.6 , and w AB = 0.4 . We use Intersection in later experiments because of its similarity in the range from 0 to 1, which makes it easier to compare with other approaches.

3.3. Analysis by Margin and Fisher Ratio

In this section, we evaluate performance by comparing ABC with three other color histogram-based matching methods, CI [12], CCH [13], and TFCM [16], as these methods are frequently cited and have been used in many papers and studies.
Margin [29] is defined as the difference in similarity between the best and second-best matching positions. The best-matching position is the maximum value at which the area of IoU between ground truth and the searched position should exceed 0.90. The second-best matching position is the maximum value at which the area of IoU is less than 0.15. A larger margin provides stronger distinguishability in avoiding interference by similar objects. Figure 8 shows example profiles. These are projected onto the horizontal axis by 3D similarity profiles for ABC, CI, CCH, and TFCM. We found that the margin of ABC was much larger than that of the other three methods.
In order to statistically investigate the performance of ABC and others in terms of margin, we independently extracted from random positions 100 reference images sized 50 × 50 , then searched for them within the reference image itself or in versions contaminated with noise. For each image, we were able find the best position or peak as peak1 and the second-best position as peak2. From the noisy image, we separated 100 pairs of peak1 and peak2 and created their histograms, as shown in Figure 9. The similarity ranges of ABC, CI, and CCH are the same from 0.3 to 1, and that of TFCM is the same from 0.8 to 1. In order to better clarify this observation, we utilized Fisher’s ratio (FR) to evaluate the discriminating power of any two-class discriminator. FR is defined as
F R = m p 1 m p 2 2 σ p 1 2 + σ p 2 2 ,
where m p 1 , m p 2 , σ p 1 2 , and σ p 2 2 represent the means and variances, respectively, of the peak1 and peak2 classes. Here, an increased numerator indicates an increased distance or interval between classes, and a reduced denominator indicates the greater compactness of each class; thus, FR can be greater when the feature space for classification is better for discrimination or identification. Table 5 summarizes the FR obtained by CI, CCH, TFCM, and ABC in cases of noisy Mondrian random patterns in which we varied the SNR from 36 to 30.
Table 5 indicates that the FR of ABC was superior to those of CI, CCH, and TFCM with the case of SNR = 36, 33, and 30, and furthermore, that it maintained this performance even in cases with a reduced SNR. As shown in Figure 10, the horizontal axis represents the change in variance, and the vertical axis represents the change in mean value, which is the size of the average margin. In these experiments, we used every set of ten images to observe those distributions in the means and variances that construct the FR values. As a result, there are two types of similarity measures, corresponding to the two approaches used to increase FR: first, to increase the difference or distance between the means or centers of the two classes, or second, to decrease their own variances. ABC adopts the former approach, while TFCM uses the latter approach.

3.4. Search in Cluttered Scenes

We designed search tasks in cluttered scenes and with actual objects under five conditions: varied illumination, rotation, deformation, scaling, and occlusion [30,31,32]. In these experiments, the reference in Figure 11a is of size 88 × 44 , and the five scenes are of the same size, 360 × 640 . We first tested ABC performance under illumination change, as shown in Figure 11. Except for TFCM, all were able to correctly find the position of the reference under the illumination change condition. Observing their profiles, it can be seen that the difference between the highest and second-highest peak under the ABC-based search was larger than that under the other two. This observation can be confirmed from its profile in Figure 12a, which verifies that ABC may have the best discrimination performance among these classes. Figure 13 shows the other challenges of searching for the reference. In Figure 13a, the doll was rotated by a small angle at the same location. In Figure 13b, the doll’s clothing was deformed, and in Figure 13c the doll’s apparent size was reduced by moving it back. Finally, in Figure 13d the doll was occluded by placing it behind another doll; nonetheless, the different methods were able to find its true position.

3.5. Tracking in Open Data

Tracking is a difficult task requiring a stable and reliable matching scheme for consecutive following of objects of interest. Many conventional tracking algorithms [33,34,35] track targets by accurately updating the reference; here, however, our aim was to test the fundamental feasibility of ABC in tracking tasks with no modification of the single reference. Liquor [27] is an open dataset that includes interesting sequences of bottles being picked up and moved by human hands in which rotation, deformation, scaling, and occlusion happen over many consecutive frames. We used frames #1301–#1400 to test the tracking performances of CI, CCH, TFCM, and ABC. In frames #1301–#1380, the target bottle remains in the leftmost position. Other bottles are picked up by hands, passed in the front of the target bottle, then moved to other positions. In frames from #1381 to the end, the target is picked up and moved forward, including small out-of-plane rotations to the left and right.
In the first frame, we defined the reference shown at the top left in Figure 14. We used horizontal displacement, Δ x , of matched positions from the central ground truth positions as a fundamental evaluator, because in these frames the bottle of interest was moved mainly horizontally and other candidate mismatched bottles were placed on the same level. Therefore, a smaller Δ x can show better tracking performance in the algorithms. In this tracking experiment, we chose the following five typical situations for the target bottle in order to demonstrate ABC performance: (1) In frame #1304, all three methods were able to find reasonable positions, because the bottle is not moved; (2) because of the large occlusion in frame #1320, only ABC was able to capture the lower-left position of the target, while the other three methods were misled to unreasonable places; (3) because of the partial occlusion in frame #1351, the result from CCH was largely shifted; (4) in frame #1354, possibly the most difficult case of full occlusion, none of the four methods wre able to identify the target; and (5) in frame #1395, where the bottle is lifted and moved to the right, only ABC maintained stable tracking of the bottle.
We next tested the effectiveness of introducing significance level, α , to determine h T using the same data frames. In preparation, we scanned all possible positions in frames #1301–#1400 to find the average, h ¯ T , and its variance, σ h T 2 , which were obtained as 0.05 and 6.96 × 10 4 , respectively, by introducing α = 0.02 . Based on this result, it is reasonable to compare the two cases of α = 0.02 and h T = 0.05 , which can be selected as representative constant values. Figure 15 shows that in these two cases, there was no apparent difference in performance except for the case of frame #1373, where the constant h T failed to find the correct position.
Table 6 shows the number of mismatches in the Liquor dataset for frames #1301–#1400. The size of the reference image is 210 × 73 pixels. If Δ x exceeds 73, the searched position does not overlap with the ground truth. We thus set 20, 30, 40, or 50 pixels to observe the number of mismatches. For example, if Δ x exceeds 20, the result is incorrect matching. As a result, ABC could not find targets under large occlusion conditions, although it remained robust in other frames. In Figure 16, we show the performance of the Skiing [27] dataset for frames #31–#60. The reference image is defined at the top left, and the size is 41 × 39 pixels. The challenges are deformation and rotation. (1) In frame #32, ABC, CI, CCH, and TFCM can search for the correct positions because the skiier does not change significantly in the sky. (2) In frames #38, #45, and #58, only ABC can match the target. This is because ABC provides a good balance between the major and absent colors. In the comparison process, red and yellow colors are major colors for the reference image, and are the absent colors for the compared images. (3) In frame #50, the proportion of yellow pixels is decreased because of the large deformation. Therefore, four methods cannot match the target. Table 7 shows the number of mismatches in the Skiing dataset for frames #31–#60. The number of mismatches proves the performance of our proposed ABC approach. ABC is more robust in the matching process.
ABC has several merits: technical simplicity, invariance with respect to in-plane rotation and distortion, and scaling as shown in the previous sections; however, it retains demerits as well, particularly the necessity of color and a reasonable image size in order to keep the histograms effective and avoid loss of positional information. In many of our experiments, we showed its effectiveness in tracking and searching problems, where a rapid method is generally needed in both the preparation or off-line processing and in on-line or real-time calculation. When sufficient data can be obtained from the training images, it may be possible to utilize different methods of machine learning, such as CNN or effective classifiers, to solve these problems. We suggest the combination of the proposed technique with these methods in order, for instance, to reduce the size and cost of training as well as to raise the total performance in processing. For example, in certain hierarchical approaches, ABC can represent an effective way of nominating possible candidates for continuing either the following detailed classification or other applications. In this type of utilization, it is preferable for absent colors to be somewhat independent of or orthogonal to any other features in order to maintain better performance in total.

3.6. Computational Cost

We calculated the computation cost of ABC using Visual Studio 2015 and the OpenCV 2.4.13 library, without parallel processing or GPU acceleration. The hardware used was a Windows 10 PC with a 2.81 GHz Intel Core i5-8400 CPU and 8 GB of RAM. We tested reference images of size 50 × 50 that were scanned and searched pixel-by-pixel in a scene of size 100 × 100 . The entire computation required 0.1029 s per the OpenCV timing function and 0.1030 s per the QueryPerformanceCounter function.

4. Conclusions

Here, we have proposed a novel method based on color histogram, called absent color indexing for robust pattern search. By reorganizing a color histogram into two complementary histograms, we observed that the new feature of absent colors can effectively increase the margins, resulting in high reliability or distinguishability in matching in many different tasks. In the proposed method, low-frequency colors or ones that are relatively non-existent in the color histogram bins are enhanced by inversion for fair treatment. A novel way of obtaining an important parameter for histogram decomposition is provided through specifying the statistical significance level in the mean histogram. Mondrian random patterns were effectively used as a general type of pictures for fundamental evaluation of the proposed method in comparison experiments with several representative competitors. Experimental results using real-world images and datasets showed that the proposed method has good performance. In future works, we hope to investigate the applicability of ABC to real tasks such as human tracking and WEB search, as well as to problems where color features are highly important and greater reliability may be necessary.

Author Contributions

Conceptualization, Y.T. and S.K.; methodology, Y.T. and S.K.; software, Y.T.; validation, Y.T., S.K. and M.F.; formal analysis, Y.T. and S.K.; investigation, Y.T. and S.K.; resources, Y.T. and S.K.; writing—original draft preparation, Y.T.; writing—review and editing, Y.T., S.K. and M.F.; visualization, Y.T.; supervision, S.K. and M.F.; project administration, S.K. and M.F. All authors have read and agreed to the published version of the manuscript.

Funding

This research was supported by the National Natural Science Foundation of China, grant No. U2141231.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data presented in this study are available upon reasonable request from the corresponding author.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Liu, X.; Wang, Z.; Wang, L.; Huang, C.; Luo, X. A hybrid rao-NM algorithm for image template matching. Entropy 2021, 23, 678. [Google Scholar] [CrossRef] [PubMed]
  2. Keyvanpour, M.R.; Vahidian, S.; Mirzakhani, Z. An analytical review of texture feature extraction approaches. Int. J. Comput. Appl. Technol. 2021, 65, 118–133. [Google Scholar] [CrossRef]
  3. Mallick, A.K.; Mukhopadhyay, S. Video retrieval framework based on color co-occurrence feature of adaptive low rank extracted keyframes and graph pattern matching. Inf. Process. Manag. 2022, 59, 102870. [Google Scholar] [CrossRef]
  4. Ma, J.; Jiang, X.; Fan, A.; Jiang, J.; Yan, J. Image matching from handcrafted to deep features: A survey. Int. J. Comput. Vis. 2021, 129, 23–79. [Google Scholar] [CrossRef]
  5. Shukran, M.A.M.; Abdullah, M.N.; Yunus, M.S.F.M. New Approach on the Techniques of Content-Based Image Retrieval (CBIR) Using Color, Texture and Shape Features. J. Mater. Sci. Chem. Eng. 2021, 9, 51–57. [Google Scholar] [CrossRef]
  6. Thyagharajan, K.; Kalaiarasi, G. A review on near-duplicate detection of images using computer vision techniques. Arch. Comput. Methods Eng. 2021, 28, 897–916. [Google Scholar] [CrossRef]
  7. Amiri, M.; Soleimani, S. A Hybrid Atmospheric Satellite Image-Processing Method for Dust and Horizontal Visibility Detection through Feature Extraction and Machine Learning Techniques. J. Indian Soc. Remote Sens. 2022, 50, 523–532. [Google Scholar] [CrossRef]
  8. Yao, R.; Lin, G.; Xia, S.; Zhao, J.; Zhou, Y. Video object segmentation and tracking: A survey. ACM Trans. Intell. Syst. Technol. (TIST) 2020, 11, 1–47. [Google Scholar] [CrossRef]
  9. Li, X.; Yang, J.; Ma, J. Recent developments of content-based image retrieval (CBIR). Neurocomputing 2021, 452, 675–689. [Google Scholar] [CrossRef]
  10. Yu, S.; Niu, D.; Zhang, L.; Liu, M.; Zhao, X. Colour image retrieval based on the hypergraph combined with a weighted adjacent structure. IET Comput. Vis. 2018, 12, 563–569. [Google Scholar] [CrossRef]
  11. Yankun, Y.; Xiaoping, D.; Wenbo, C.; Qiqige, W. A Color Histogram Based Large Motion Trend Fusion Algorithm for Vehicle Tracking. IEEE Access. 2021, 9, 83394–83401. [Google Scholar] [CrossRef]
  12. Swain, M.J.; Ballard, D.H. Indexing via color histograms. In Proceedings of the Third International Conference on Computer Vision, ICCV, Osaka, Japan, 4–7 December 1990; pp. 390–393. [Google Scholar]
  13. Stricker, M.A.; Orengo, M. Similarity of color images. In Proceedings of the Storage and Retrieval for Image and Video Databases III, San Jose, CA, USA, 5 February 1995; International Society for Optics and Photonics: Bellingham, WA, USA, 1995; Volume 2420, pp. 381–393. [Google Scholar]
  14. Chang, P.; Krumm, J. Object recognition with color cooccurrence histograms. In Proceedings of the 1999 IEEE Computer Society Conference on Computer Vision and Pattern Recognition (Cat. No PR00149), CVPR, Fort Collins, CO, USA, 23–25 June 1999; Volume 2, pp. 498–504. [Google Scholar]
  15. Han, J.; Ma, K.K. Fuzzy color histogram and its use in color image retrieval. IEEE Trans. Image Process. 2002, 11, 944–952. [Google Scholar] [CrossRef] [PubMed] [Green Version]
  16. Verma, N.K.; Goyal, A.; Chaman, A.; Sevakula, R.K.; Salour, A. Template matching for inventory management using fuzzy color histogram and spatial filters. In Proceedings of the 2015 IEEE 10th Conference on Industrial Electronics and Applications, ICIEA, Auckland, New Zealand, 15–17 June 2015; pp. 317–322. [Google Scholar]
  17. Wang, X.Y.; Wu, J.F.; Yang, H.Y. Robust image retrieval based on color histogram of local feature regions. Multimed. Tools Appl. 2010, 49, 323–345. [Google Scholar] [CrossRef]
  18. Varish, N.; Pradhan, J.; Pal, A.K. Image retrieval based on non-uniform bins of color histogram and dual tree complex wavelet transform. Multimed. Tools Appl. 2017, 76, 15885–15921. [Google Scholar] [CrossRef]
  19. Liu, P.; Guo, J.M.; Chamnongthai, K.; Prasetyo, H. Fusion of color histogram and LBP-based features for texture image retrieval and classification. Inf. Sci. 2017, 390, 95–111. [Google Scholar] [CrossRef]
  20. Tian, Y.; Kaneko, S.; Sasatani, S.; Itoh, M. Robust Picture Search by Absent Color Indexing. In Proceedings of the Seventh Asia International Symposium on Mechatronics, AISM, Hangzhou, China, 19–22 September 2019; Volume 589, pp. 860–866. [Google Scholar]
  21. Tian, Y.; Kaneko, S.; Sasatani, S.; Itoh, M.; Fang, M. Reliable and Accurate Pattern Search by Combination of Absent Color Indexing with Correlation Filter. In Proceedings of the IECON 2019-45th Annual Conference of the IEEE Industrial Electronics Society, IECON, Lisbon, Portugal, 14–17 October 2019; Volume 1, pp. 5413–5418. [Google Scholar]
  22. Alkiayat, M. A Practical Guide to Creating a Pareto Chart as a Quality Improvement Tool. Glob. J. Qual. Saf. Healthc. 2021, 4, 83–84. [Google Scholar] [CrossRef]
  23. Yuan, B.H.; Liu, G.H. Image retrieval based on gradient-structures histogram. Neural Comput. Appl. 2020, 32, 11717–11727. [Google Scholar] [CrossRef]
  24. Nielsen, F. On a generalization of the Jensen–Shannon divergence and the Jensen–Shannon centroid. Entropy 2020, 22, 221. [Google Scholar] [CrossRef] [Green Version]
  25. Ji, S.; Zhang, Z.; Ying, S.; Wang, L.; Zhao, X.; Gao, Y. Kullback-Leibler divergence metric learning. IEEE Trans. Cybern. 2020, 52, 2047–2058. [Google Scholar] [CrossRef]
  26. Basener, W.F.; Flynn, M. Microscene evaluation using the Bhattacharyya distance. In Proceedings of the Multispectral, Hyperspectral, and Ultraspectral Remote Sensing Technology, Techniques and Applications VII, Honolulu, HI, USA, 24–26 September 2018; International Society for Optics and Photonics: Bellingham, WA, USA, 2018; Volume 10780, p. 107800. [Google Scholar]
  27. Wu, Y.; Lim, J.; Yang, M.H. Online object tracking: A benchmark. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, CVPR, Portland, OR, USA, 23–28 June 2013; pp. 2411–2418. [Google Scholar]
  28. Wu, Y.; Lim, J.; Yang, M.H. Object tracking benchmark. IEEE Trans. Pattern Anal. Mach. Intell. 2015, 37, 1834–1848. [Google Scholar] [CrossRef] [Green Version]
  29. Wang, F.; Cheng, J.; Liu, W.; Liu, H. Additive margin softmax for face verification. IEEE Signal Process. Lett. 2018, 25, 926–930. [Google Scholar] [CrossRef] [Green Version]
  30. Yang, H.; Huang, C.; Wang, F.; Song, K.; Zheng, S.; Yin, Z. Large-scale and rotation-invariant template matching using adaptive radial ring code histograms. Pattern Recognit. 2019, 91, 345–356. [Google Scholar] [CrossRef]
  31. Li, Z.; Gao, S.; Nai, K. Robust object tracking based on adaptive templates matching via the fusion of multiple features. J. Vis. Commun. Image Represent. 2017, 44, 1–20. [Google Scholar] [CrossRef]
  32. Korman, S.; Milam, M.; Soatto, S. OATM: Occlusion Aware Template Matching by Consensus Set Maximization. In Proceedings of the The IEEE Conference on Computer Vision and Pattern Recognition, CVPR, Salt Lake City, UT, USA, 18–23 June 2018; pp. 2675–2683. [Google Scholar]
  33. Ning, J.; Yang, J.; Jiang, S.; Zhang, L.; Yang, M.H. Object tracking via dual linear structured SVM and explicit feature map. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, CVPR, Las Vegas, NV, USA, 27–30 June 2016; pp. 4266–4274. [Google Scholar]
  34. Bertinetto, L.; Valmadre, J.; Henriques, J.F.; Vedaldi, A.; Torr, P.H. Fully-convolutional siamese networks for object tracking. In Proceedings of the European Conference on Computer Vision, ECCV, Amsterdam, Netherlands, 11–14 October 2016; pp. 850–865. [Google Scholar]
  35. Cheng, J.; Tsai, Y.H.; Hung, W.C.; Wang, S.; Yang, M.H. Fast and accurate online video object segmentation via tracking parts. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, CVPR, Salt Lake City, UT, USA, 18–23 June 2018; pp. 7415–7424. [Google Scholar]
Figure 1. Images 1 and 2 at 173 × 100 pixels. (a) Image 1. (b) Image 2.
Figure 1. Images 1 and 2 at 173 × 100 pixels. (a) Image 1. (b) Image 2.
Mathematics 10 02196 g001
Figure 2. Original color histograms ( β 1 = 10 , β 2 = 10 ). (a) H for image 1. (b) G for image 2.
Figure 2. Original color histograms ( β 1 = 10 , β 2 = 10 ). (a) H for image 1. (b) G for image 2.
Mathematics 10 02196 g002
Figure 3. Special cases of zero frequency h = 0 during the inverting process. (a) shows the case (I) when h = 0 and h > h T . (b) shows the cases (II), (III), and (IV) when h = 0 , h = 0 and g > 0 or g = 0 .
Figure 3. Special cases of zero frequency h = 0 during the inverting process. (a) shows the case (I) when h = 0 and h > h T . (b) shows the cases (II), (III), and (IV) when h = 0 , h = 0 and g > 0 or g = 0 .
Mathematics 10 02196 g003
Figure 4. Apparent and absent color histograms. (a) H P for image 1. (b) H N for image 1. (c) G P for image 2. (d) G N for image 2.
Figure 4. Apparent and absent color histograms. (a) H P for image 1. (b) H N for image 1. (c) G P for image 2. (d) G N for image 2.
Mathematics 10 02196 g004
Figure 5. Mean color histogram.
Figure 5. Mean color histogram.
Mathematics 10 02196 g005
Figure 6. Pareto chart of parameter α and sorted histogram, M sorted .
Figure 6. Pareto chart of parameter α and sorted histogram, M sorted .
Mathematics 10 02196 g006
Figure 7. Mondrian random pattern.
Figure 7. Mondrian random pattern.
Mathematics 10 02196 g007
Figure 8. Projected profiles of similarity (No noise σ = 0 ). (a) ABC. (b) CI. (c) CCH. (d) TFCM.
Figure 8. Projected profiles of similarity (No noise σ = 0 ). (a) ABC. (b) CI. (c) CCH. (d) TFCM.
Mathematics 10 02196 g008
Figure 9. Distributions of margins between p e a k 1 and p e a k 2 for ABC, CI, CCH, and TFCM (SNR = 36). (a) ABC. (b) CI. (c) CCH. (d) TFCM.
Figure 9. Distributions of margins between p e a k 1 and p e a k 2 for ABC, CI, CCH, and TFCM (SNR = 36). (a) ABC. (b) CI. (c) CCH. (d) TFCM.
Mathematics 10 02196 g009
Figure 10. Analytical diagram of FR (SNR = 36).
Figure 10. Analytical diagram of FR (SNR = 36).
Mathematics 10 02196 g010
Figure 11. Search in a cluttered scene. The red, blue, green, and black bounding boxes represent the matching results of ABC, CI, CCH, and TFCM, respectively. (a) Reference. (b) Cluttered scene under dark illumination.
Figure 11. Search in a cluttered scene. The red, blue, green, and black bounding boxes represent the matching results of ABC, CI, CCH, and TFCM, respectively. (a) Reference. (b) Cluttered scene under dark illumination.
Mathematics 10 02196 g011
Figure 12. Three-dimensional profiles of similarity. (a) Profile of ABC similarity. (b) Profile of CI similarity. (c) Profile of CCH similarity. (d) Profile of TFCM similarity.
Figure 12. Three-dimensional profiles of similarity. (a) Profile of ABC similarity. (b) Profile of CI similarity. (c) Profile of CCH similarity. (d) Profile of TFCM similarity.
Mathematics 10 02196 g012
Figure 13. Search under rotation, deformation, scaling, and occlusion by ABC, CI, CCH, and TFCM where the red, blue, green, and black bounding boxes represent the matching results of four approaches, respectively. (a) Rotation. (b) Deformation. (c) Scaling. (d) Occlusion.
Figure 13. Search under rotation, deformation, scaling, and occlusion by ABC, CI, CCH, and TFCM where the red, blue, green, and black bounding boxes represent the matching results of four approaches, respectively. (a) Rotation. (b) Deformation. (c) Scaling. (d) Occlusion.
Mathematics 10 02196 g013
Figure 14. Tracking by ABC ( α = 0.2 ), CI, CCH and TFCM.
Figure 14. Tracking by ABC ( α = 0.2 ), CI, CCH and TFCM.
Mathematics 10 02196 g014
Figure 15. Comparison of two cases for threshold selection.
Figure 15. Comparison of two cases for threshold selection.
Mathematics 10 02196 g015
Figure 16. Matching performance in Skiing dataset.
Figure 16. Matching performance in Skiing dataset.
Mathematics 10 02196 g016
Table 1. Combinations of apparent (AP) and absent (AB) colors.
Table 1. Combinations of apparent (AP) and absent (AB) colors.
HistogramsH
h AP h AB 0
G g AP ( h AP , g AP ) ( h AB , g AP ) ( 0 , g AP )
g AB ( h AP , g AB ) ( h AB , g AB ) ( 0 , g AB )
0 ( h AP , 0 ) ( h AB , 0 )
Table 2. Value of h N in conditions of h = 0 .
Table 2. Value of h N in conditions of h = 0 .
h N h = 0 , h > h T h = 0 , h = 0
g > 0 0 h T
g = 0 00
Table 3. Statistical characteristics of background noise.
Table 3. Statistical characteristics of background noise.
RGB
Biker σ n 0.9580.9031.143
SNR35.0935.2034.17
Walking σ n 1.0210.9531.028
SNR36.4837.9037.23
Table 4. Performance of ABC with various similarity measures.
Table 4. Performance of ABC with various similarity measures.
F-Measure
SNR363330
ABC + Intersection0.9730.9650.952
ABC + Chi-square0.9760.9710.961
ABC + JS divergence0.9800.9740.971
ABC + Bhattacharyya0.9740.9700.968
Table 5. Margins in CI, CCH, TFCM and ABC.
Table 5. Margins in CI, CCH, TFCM and ABC.
CICCHTFCMABC
SNRClassMeanStdMeanStdMeanStdMeanStd
36Peak10.9520.0340.9350.0410.999 3.6 × 10 4 0.9460.049
Peak20.5830.0600.5900.0690.9020.0200.4560.055
FR28.6718.2821.7543.77
33Peak10.9370.0380.9150.0420.999 2.2 × 10 4 0.9350.057
Peak20.5750.0580.5910.0720.9100.0210.4550.064
FR26.5214.8016.9531.18
30Peak10.9190.0400.8980.0450.998 5.7 × 10 4 0.9140.058
Peak20.5790.0530.5920.0650.9080.0240.4650.064
FR25.7914.8514.0726.58
Table 6. Number of mismatches in 100 frames.
Table 6. Number of mismatches in 100 frames.
CICCHTFCMABC
Δ x 20 15284916
Δ x 30 1522407
Δ x 40 1520184
Δ x 50 1519163
Table 7. Number of mismatches in 30 frames.
Table 7. Number of mismatches in 30 frames.
CICCHTFCMABC
Δ x 20 2524235
Δ x 30 2424234
Δ x 40 2323234
Δ x 50 2323234
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Tian, Y.; Fang, M.; Kaneko, S. Absent Color Indexing: Histogram-Based Identification Using Major and Minor Colors. Mathematics 2022, 10, 2196. https://doi.org/10.3390/math10132196

AMA Style

Tian Y, Fang M, Kaneko S. Absent Color Indexing: Histogram-Based Identification Using Major and Minor Colors. Mathematics. 2022; 10(13):2196. https://doi.org/10.3390/math10132196

Chicago/Turabian Style

Tian, Ying, Ming Fang, and Shun’ichi Kaneko. 2022. "Absent Color Indexing: Histogram-Based Identification Using Major and Minor Colors" Mathematics 10, no. 13: 2196. https://doi.org/10.3390/math10132196

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop