morphological pattern matching transforms : the SOMP transform (Single Object ... We propose to report to the solutions proposed in Chapter II to answer this ...
Chapter III: Metrics based on logarithmic laws III-1-Introduction III-2-Recalls on some existing metrics III-2-1-Definition of a metric III-2-2-Examples of functional metrics III-2-2-1-The most classical III-2-2-2-Examples of other metrics III-2-2-2-1- Intermediate metric between “global” and “atomic” III-2-2-2-2- A Bounded Metric Associating Binary and Grey-Level Approaches III-2-3-Examples of metrics defined on binary shapes
III-3-Two ways to introduce novel metrics in the LIP framework III-3-1-Extension of d1 and d∞ in the LIP sense III-3-2- Extension of the intermediate metric III-3-3-Extension to functions of the binary Asplünd’s metric
III-4-The Multiplicative Asplünd’s Metric III-4-1-Local processing and application to target tracking III-4-2-Neighborhoods generated by the Multiplicative Asplünd’s Metric III-4-3-How to overcome the noise sensitivity of Multiplicative Asplünd’s Metric
III-5-The Additive Asplünd’s Metric III-5-1- Definition of this novel metric III-5-2- Main property: insensitivity of the Additive Asplünd’s metric to exposure time variations III-5-2-1- Theoretical case: simulated exposure times III-5-2-2- Real case III-5-3- Other examples of application III-5-3-1 Region Growing Algorithm (RGA) III-5-3-1-1 Theoretical case: simulated exposure times III-5-3-1-2 Real case III-5-3-2 Contour detection III-5-4- Conclusion of Section III-5 and perspectives
III-6-Examples of Metrics for Color Images III-6-1-LIP-C approach III-6-2- Extension of LAC to color images and associated metrics III-6-3-Asplünd-like Metrics for Color Images III-6-3-1-Multiplicative Asplünd-like Metric III-6-3-2-Additive Asplünd-like Metric 1
III-7- Other notions around metrics III-7-1- Recalls III-7-2- Notions stronger than metrics III-7-3- Notions weaker than metrics III-7-3-1- Recalls on gauges theory in Vector Spaces and Topological Vector Spaces III-7-3-2- Definition of gauges in Image processing
III-8-Conclusion and perspectives References for Chapter III
2
Chapter III: Metrics based on logarithmic laws III-1-Introduction The interest of Image Processing and Image Understanding considerably developed these last three decades for various reasons: the power of computers exponentially increased while new tools appeared, making possible the common use of Computer Vision for biomedical applications (automated detection of cancerous cells, automated analysis of eye fundus images, 3-D reconstruction from serial or optical cuts issued for example of X-ray scanner), industrial applications (robotics, real time quality control on conveyors), safety and surveillance (sensitive sites, highways, streets, subway stations), images acquired by a drone (inspection of dams, bridges, nuclear power plant cooler) and many other situations. For all these reasons, the access to efficient tools in Image Analysis became a key need in order to take automated reliable decisions. In this aim, we have often to compare an image to a reference one in order to detect what is wrong, what has changed. The most classical approaches consist of detecting matching points or applying correlation tools. Among all the possible techniques, we can consider that Metrics answer well the previous requests. Nevertheless, it remains two properties which are generally not taken into account: -
The consistency with Human Vision, on which image interpretation was previously founded. The insensitivity to lighting variations.
When defining Metrics in the LIP Framework, the first property results of the LIP compatibility with the Human Visual System. It is much more difficult to satisfy the second property, but in the present chapter we will propose an efficient solution based on a novel kind of Metrics that we have extended to functions (grey level, color or multispectral images): the family of Asplünd’s metrics, which were initially restricted to binary shapes.
III-2-Recalls on some existing metrics III-2-1-Definition of a metric is a set and an application of in the space of real numbers. We say that is a metric defined on E if it satisfies the four following properties:
(symmetry property) (separation property) 3
(triangular inequality) The notion of Metric Spaces is a particular case of Topologic Spaces i.e. those spaces based on the concept of neighborhoods. In fact, given a metric on , we can define specific neighborhoods of a point , called “balls” and constituted of elements of whose 2 3 distance to is less than a given tolerance . In spaces like , and , balls become segments, disks and spheres. Nevertheless, in general Metric Spaces as functional ones (spaces of images for example), it is possible to observe neighborhoods with various shapes (cf. next section). III-2-2-Examples of functional metrics III-2-2-1-The most classical We will limit to the most classical ones, noted and . In the case of grey level images and defined on the same spatial support or on a region of , we have:
Such metrics are extremely different. Properties and usefulness of -
is a “global” metric in the sense that it takes into account all the points lying in the considered region The value represents the volume delimited by the representative surfaces of and In such conditions, it is able to evaluate if two images are roughly similar, but it is unable to extract small sized differences In the digital version, it is transformed into the double sum of the differences between pixels grey levels according to the rows and columns, multiplied by the area of one pixel:
Properties and usefulness of -
:
:
is an “atomic” metric in the sense that its value is computed on a single point In such conditions, it is able to detect very small sized differences between and , possibly limited to a single pixel in digital version. This is the reason why we have introduced in [1] an intermediate metric between and
Now let us come back to the ability of metrics to define neighborhoods and have a look at their shapes. Neighborhoods generated by the previous metrics: 4
The neighborhoods shapes are totally different for and . In fact, given a function , each function verifying satisfies for every point lying in the considered region. It means that belongs to a “tolerance tube” around (cf. Fig. 3-1-a)). This remark explains why is called “uniform convergence metric”. This result holds for images, the tolerance tube becoming the volume located between the representative surfaces of and – . When considering the “global” metric , a ε–neighborhood of a given function is totally different from a tube: it is an unbounded set! In fact, a function belonging to the ε– neighbor of may present at some point an arbitrary large difference and a very small area located between and (cf.Fig. 3-1-b))
x a)
b)
Fig. 3-1-a) The tolerance tube of f is represented by the hatched area Fig. 3-1-b) The local difference between a function f and a function g lying in the ε– neighbor of f may be arbitrarily large. Fig. 3-1 Neighborhoods shapes for and III-2-2-2-Examples of other metrics III-2-2-2-1- Intermediate metric between “global” and “atomic” For some applications of industrial control, where we aim at detecting defects, it happens that the metric is too global and thus insensitive to the purchased small defects while the atomic metric will extract acceptable defects reduced to a single pixel. It is the reason why we proposed an intermediate solution. This consists of making a compromise between the size of an unacceptable defect and its intensity (contrast) in relation to the background. Let us explain this concept in one dimension, knowing that there is no difficulty to write it in two (or three) dimensions. In order to do this, we define an interval of length , which is moved along the interval . We calculate the following integral:
5
An illustration of this metric is given Figure 3-2
Fig. 3-2 Value of
= largest hatched zone
In two dimensions, is simply replaced by a region of the spatial support, which is moved across it while computing the sup:
For this approach, the region R is sized at the defect’s desired dimension. In order to apply it to digital images, the double integral is replaced by the double summation according to rows and columns. III-2-2-2-2- A Bounded Metric Associating Binary and Grey-Level Approaches Let us consider two grey level functions f and g. The support notion them is the subset of D where they take strictly positive values:
of each of
The spatial domain D is then separated into three disjointed subsets:
where
represents the symmetric difference between two sets i.e.
At this step, the multiplicative contrast
is computed on each of these subsets: 6
-
If
-
If
-
If
,
is classically defined:
by convention
In order to replace the infinite value (case of ), we apply the method proposed in (Chapter II, Remark 12). Thus a novel punctual distance d is obtained:
Now, it is possible to perform a summation of these elementary distances when lies in D (or a region of D), resulting in a metric which takes into account the supports’ shapes as well as the distance between grey levels on the supports intersection:
But to the area of
which we can assimilate to the area of
or, by definition of
Comment: The first sum of represents a distance in terms of grey levels and the second one a distance in terms of shapes. The main interest we imagine for this metric is to quantify the evolution in shape and in grey level (concentration) of a polluting cloud (fumes, radioactive emissions, and so on). We successfully tested it in such case, but we have not the authorization to publish images. 7
III-2-3-Examples of metrics defined on binary shapes Symmetric difference metric Consider two binary shapes and (in (cf. Fig. 3-3-a) is given by the following formula:
The Symmetric Difference Distance between
or
), their symmetric difference
and
is then defined according to:
Note that this metric is very easy to program and very fast in computer time. Its principle must be compared to the functional metric defined in previous section 3-2-2 (cf. Fig. 3-3-b). In fact:
where
designs the sub-graph of
(set of points located under the representative
surface of ).
a)
b)
Fig. 3-3-a) Symmetric difference between A and B (hatched area) Fig. 3-3-b) Symmetric difference between the sub-graphs of functions f and g (hatched area) Fig. 3-3 Illustration of Symmetric Difference in the case of binary shapes and in the case of functions HAUSDORFF’s metric Given two binary shapes according to the formula:
and
(in
or
), we define the HAUSDORFF’s metric
8
This metric takes into account the point of maximal (cf. Fig. 3-4-a and 3-4-b).
(or
) whose distance from the other shape is
B A
A a)
B
b)
Fig. 3-4- Hausdorff’s distance between two binary shapes: length of the double arrow As we have done between and , we can observe the similitude between and : these two metrics are determined by a single point. Thus, Hausdorff’s metric generates neighborhoods representable as “tolerance tubes”. More precisely, if is a binary shape and a strictly positive real number, the neighborhood of generated by the error tolerance is the set of all binary shapes satisfying the double condition: contains the eroded set of by a ball of radius and is included in the dilated set of by the same ball. In such conditions, the “tolerance tube” of is the dilated of the boundary of by a ball of radius .
III-3-Two ways to introduce novel metrics in the LIP framework III-3-1-Extension of
and
in the LIP sense
This point has been studied in a previous paper ([1]) and is shortly recalled here: it consists of introducing the metrics and on the basis of the logarithmic addition law (more precisely on the subtraction law ⨺, due to the definition of the two classical metrics and : = =
Remark 1: what is the interest of such an extension? The logarithmic subtraction between two grey levels represents by definition (cf. Chapter II) the Logarithmic Additive Contrast (LAC) between them and it has been seen that such a contrast possesses a rigorous physical interpretation based on the Transmittance Law. This point results in a strong property: the LAC takes perfectly into account the intensity of the background on which an object is observed in transmission. In [1], various theoretical and applicative interests of that property have been presented: automated thresholding and multithresholding (cf. Fig.3-5-), contour detection (cf. Fig. 3-6-), target tracking (cf. Fig. 3-7-), processing of images acquired under 9
variable lighting, insensitivity of covariograms to lighting drift and lighting variations (cf. Fig 3-8-)…For more details concerning thresholding and multithresholding, see Chapter VI.
a)
b)
Fig. 3-5-a- Initial image with 256 grey levels Fig. 3-5-b- Multi-thresholded image with 6 grey levels Fig.3-5- Automated multi-thresholding done by Köhler’s method in which the initial contrast is replaced by the Logarithmic Additive Contrast Comment on Figure 3-5: we refer here to the automated thresholding method proposed by Köhler ([2]) which presents the advantage to take into account the spatial information (contrasts of boundaries associated to a threshold), contrary to methods based only on histogram information. Moreover, to better take into account the Human Visual System, we have replaced the initial Köhler’s contrast, based on a simple difference between grey levels, by the Logarithmic Additive Contrast.
a)
b)
c)
Fig. 3-6- a) Initial grey level image (a “well” with a very dark part) Fig. 3-6-b) Classical contour detection (Sobel gradient) applied on a) Fig. 3-6-c) Visualization of the maximal contrast MC(x) (f) (notion defined in Chapter II) at each point of a) Fig. 3-6 Comparison of Sobel gradient and MC(x) (f) as Contour Detectors 10
Comment on Figure 3-6: The pre-eminence of the logarithmic approach is obvious when comparing images b) and c). Nevertheless, to achieve the binarization of the contours proposed in c), (which is not the purpose here), it is possible to apply a thresholding (not very efficient for complex images) or more accurately a watershed algorithm (see Beucher and Lantuejoul ([3]), and Beucher ([4])).
Example of a reference target (magnified) Fig. 3-7-a- Image of car crash test (with the authorization of “Insurance Institute for Highway Safety”) Note that, due to the perspective, the different targets do not present exactly the same orientation
b)
c)
d)
Fig. 3-7-b) Represents the distance map associated to the classical metric d1 Fig 3-7-c) Represents the distance map associated to the logarithmic metric Fig 3-7-d) Location of the targets obtained by an automated thresholding of c) 11
Fig 3-7- Example of target tracking thanks to the logarithmic metric Comments on Figure 3-7: The dynamic range of the distance map obtained with (Fig. 37-c) is obviously better than that obtained with d1 (Fig. 3-7-b) as it is observable on the associated histograms. The automated thresholding applied on image c) to get the final result d) is due to Otsu ([5]), which is based on the classical technique of Interclass Variance Maximization. Let us now study two images of the same bricks wall acquired under variable lighting (cf. Fig. 3-8). These images are clearly “pseudo-periodic” and the goal is to estimate the period. The chosen tool to reach this goal is the covariogram concept, applied here to compare an image with its horizontal translated. The comparison is made thanks to a metric and the covariogram represents the translation vector (horizontal axis) and the distance value (vertical axis). We observe on the covariogram curve local minima corresponding to the translation values for which the studied image and its translated are most similar. The distance between two successive minima produces an estimation of the most probable period observed on the initial image in the translation direction.
a)
c)
b)
d) 12
e) Fig. 3-8-a) and b) Same bricks wall under variable lighting Fig. 3-8-c) Horizontal covariogram of a) computed thanks to the metric d1 (similar result with ) Fig. 3-8-d) Horizontal covariogram of b) computed thanks to the metric d1 Fig. 3-8-e) Horizontal covariogram of b) computed thanks to the metric Fig. 3-8 Insensitivity to lighting variations of Covariograms based on the Logarithmic Additive metric Comments on Figure 3-8: the covariograms previously presented are nothing but autocorrelation of the studied image where “correlation” is evaluated thanks to a distance, here and . It is interesting to note that these two metrics produce similar results for an image with standard lighting (image a)). When the illumination decreases significantly, the metric
preserves the covariogram interpretability while
fails.
III-3-2-Extension of the intermediate metric This metric has been introduced in III-2-2-1-1. Its LIP version is defined according to the following expression:
whose digital expression, corrected by
, is:
We have already explained the interest of dividing the previous expression by
.
Remark 2: For a good use of the metric, the region must be sized at the dimension of maximal purchased defects, so the result will not be polluted by very small ones, while preserving the extraction of larger defects. 13
Remark 3: This intermediate distance is defined according to a superior bound. In such conditions, it detects only one defect: that corresponding to the greatest value. In order to avoid this weakness, it is possible to come back to the version of and to compute it for all the positions of R in D. It remains to retain as defects all the R locations where the computed distance is greater than a chosen threshold (Figure 3-9).
a)
b)
c)
d)
e)
f)
g)
h)
Fig. 3-9 (a) Initial image f of skin wrinkles by fringes projection at time Fig. 3-9 (b) Initial image g at days, 14
Fig. 3-9 (c), (e), and (g): for different sizes of R : the detected region is the white square Fig. 3-9 (d), (f), and (h) represent the images (c), (e), and (g) thresholded at grey level 90 Fig. 3-9 Defects detection thanks to the logarithmic intermediate metric III-3-3-Extension to functions of the binary Asplünd’s metric Here we go on with the parallel previously established between functional and binary metrics. A few years ago we focused on a little known metric defined in [6] and [7] for binary shapes: the Asplünd’s one. Recall on the binary Asplünd’s metric: In the initial definition of Asplünd’s metric for a pair of binary shapes, one shape, for example, is chosen to perform the double sided probing of by means of homothetic shapes of : we compute the smallest number such that contains and the greatest number such that contains (cf. Fig. 3-10). The Asplünd’s distance between and is then defined according to:
Remark 4: Such a definition obviously implies that is magnified or reduced in any ratio .
remains unchanged when one shape
Figure 3-10- Asplünd’s metric for binary shapes Comment on Figure 3-10: After constructing the homothetic sets remark that for every shape , we have the equivalence:
and
, we can
This means that the set
is interpretable as a tolerance tube.
Furthermore, given a reference shape and a tolerance number , it is easy to characterize the set of shapes neighboring in the sense of the following inequality:
15
Starting from the couple and , we choose an arbitrary homothetic shape of , say , and compute the (unique) number such that . Thus the two homothetic sets and
delimit a tolerance tube constituted of their difference set In fact, each element B satisfying the double inclusion number , is an element of the neighborhood
. for some real
⇨ The difference with previous situations associated to atomic metrics is that the tolerance tube is generated by the pair of initially considered shapes and that it is not of constant thickness. Nevertheless, the similarity of Asplünd’s metric with atomic metrics let guess that we will have to consider the sensitivity to noise of Asplünd-like metrics. First papers in link with functional Asplünd’s metrics, probing and tolerance tubes: The idea of extending Asplünd’s metric to functions and consequently to images was in my mind from a long time. In a paper co-authored by Nathalie Montard ([8]) dedicated to the notion of Logarithmic Top-Hat, we made a link with Asplünd’s metric. A few years later, I proposed to Cécile Barat to work on this subject during her PhD. She proposed in fact two variants: -
The first, called “Pattern matching using morphological probing” ([9]) consisted of transferring to image analysis the principle of mechanical probing: it resulted into two morphological pattern matching transforms : the SOMP transform (Single Object Matching using Probing) and its extension to multiple object detection, the MOMP transform. It permits to define a priori tolerance tubes limited by two functions (a superior bound and an inferior one) in order to extract of an image all the patterns lying in the tolerance tube.
-
In the second ([10]), called VDIP: “Virtual Double-sided Image Probing: A unifying framework for non-linear grayscale pattern matching”, Barat proposed a unified approach of seemingly different methods by placing them under a topological formulation. Let us note that Barat highlights a property which will be at the center of Functional Asplünd’s Metric properties: “Moreover, the VDIP transform compensates automatically an additive illumination effect or a multiplicative illumination effect when working on log intensities. This allows detecting a pattern independently of the illumination”.
Definition of a Functional Multiplicative Asplünd’s metric: Here we refer to previous papers where this subject has been addressed ([1] and [11] for example). The novelty of what we proposed in [1] consists of using logarithmic homothetics as probing patterns. Thanks to the transmittance law, this logarithmic scalar multiplication always remains in the greyscale. This property makes possible the definition of a Logarithmic Multiplicative Asplünd Metric in the following way:
16
Given two images and defined on D, we choose, as for binary shapes, a probing element, say for example (cf. Fig. 3-11) and define the two numbers: and The corresponding Multiplicative Asplünd’s Metric is noted according to:
and is defined
(1) Fundamental property: As noted for the binary Asplünd’s metric (cf. Remark 4), let us focus on a strong advantage of the Multiplicative Asplünd’s Metric: it remains unchanged when one function ( for example) is replaced by any homothetic for . Remember that is brighter than when and darker than when Such a property shows the insensitivity of to strong illumination variations modelled by the logarithmic multiplicative law. Mathematicians Section: From the definition of and the previous fundamental property, it would be more rigorous to present the Multiplicative Asplünd’s Metric in the following way: -
First, we can define an equivalence relation R on the space of images: Given a pair of images and , we say they are “in relation” if they satisfy: ( R )
Note that the previous relation R is clearly an equivalence relation, because it satisfies the three required properties: R
*Reflexivity: *Symmetry: *Transitivity: -
R
Second, we associate each image
R
R and
R )
R
with its equivalence class
:
R } -
Third, we are now able to give a rigorous version of the Multiplicative Asplünd’s Metric defined on the space of equivalence classes : ) where and
) is the distance, according to formula (3-1) between two elements of the equivalence classes and . 17
Fig. 3-11- Computation of the double sided probing metric probing function.
when g is the
The following section is devoted to the Multiplicative Asplünd’s metric properties, drawbacks and main applications.
, its
III-4-The Multiplicative Asplünd’s Metric Remark 5: From the definition of given in formula (1) we observe a situation previously met for the multiplicative contrast introduced in Chapter II: this metric can produce infinite values when there exists at least a point in for which or is null and the other strictly positive. We propose to report to the solutions proposed in Chapter II to answer this problem. III-4-1-Local processing and application to target tracking Let us remark that this metric is adaptable to local processing, in particular to detect on an image the place where a given pattern or target model is probably located. In such a case, the target corresponds to an image defined on a spatial support smaller than the initial one . For each location of included in , the distance is computed, where the notation represents the restriction of image to . In the following example (cf. Fig. 3-12, previously presented in [1]), we consider a bricks wall from which we extract two bricks, one being bright and the second dark. For each of them, we produce the corresponding Asplünd’s map: for each location of the target inside the initial image , we compute the distance and we affect this number (normalized as a level in the standard grey scale ) at the center of the target. The smallest distance values are the dark points located at the bricks centers.
18
a)
b)
c)
d)
e)
Fig.3-12-a) Initial image Fig.3-12-b) Bright target Fig.3-12-c) Corresponding Asplünd’s map (values of
)
Fig.3-12-d) Dark target Fig.3-12-e) Corresponding Asplünd’s map (values of
)
Fig.3-12- Example of target detection by means of Multiplicative Asplünd’s Metric Comments on Figure 3-12: -
-
-
Let us note the strong similarity between the Asplünd’s maps c) and e). This shows the Multiplicative Asplünd’s Metric is roughly insensitive to “lighting” variations, as long as these variations can be modelled by the logarithmic multiplicative law. The targets have been chosen lightly smaller than the bricks themselves in order to facilitate the probing of a) by the targets. This explains the thickness of the dark points of c) and d). The final extraction (from c) and e)) of the bricks locations is easily realized by means of an automated thresholding ([5] for example). A classical approach by correlation (cf. Figure 3-13) produces an image less easy to interpret. In the best case, we will extract the bricks presenting grey levels similar to the target ones.
19
a)
b)
Fig.3-13-a) Chosen target Fig.3-13-b) Correlation map Fig.3-13 Example of target detection based on correlation If now we come back to the example given in Figure 3-7 where the targets were extracted thanks to the logarithmic version the Multiplicative Asplünd’s Metric the corresponding distance map.
a)
of the metric
, the problem can be solved by
. The next figure 3-14 presents the chosen target and
b)
c)
20
d)
e)
Fig. 3-14-a) Crash test image Fig. 3-14-b) Probing zones inside the target magnified 10 times Fig. 3-14-c) Probing function magnified 10 times Fig. 3-14-d) Asplünd's map Fig. 3-14-e) Thresholded image of (d) Fig.3-14 Target detection thanks to Multiplicative Asplünd's Metric Comment on Figure 3-14: As remarked for the previous case of bricks wall, it is recommended to select probing zones smaller than the target. The results obtained are very similar to those produced by the metric
.
III-4-2-Neighborhoods generated by the Multiplicative Asplünd’s Metric The neighborhoods generated by Asplünd’s metric have been already interpreted for binary shapes as tolerance tubes. The same reasoning is possible for grey-level images. Given an image and a tolerance number , let us consider the successive steps: 1. Create a family of tolerance tubes homothetics and such that 2. Define the neighborhood
consisting of regions delimited by two
: and
3. Visualize a mono-dimensional representation (Figure 3-15).
21
Fig. 3-15 Example of two images and
which are -neighbors in Asplünd’s sense
Remark 6: In a first approach, it may be surprising to associate an infinite number of tolerance tubes to a pair constituted of an image and a tolerance . This point is clarified thanks to the aforementioned Mathematicians Section. In fact, in a rigorous reasoning, an image lies in a -neighborhood of the considered image if and only if it satisfies the inequality . This means that an element of the equivalence class and another element of the equivalence class both lie in the same tolerance tube, as shown by Fig. 3-15. If we remember the physical meaning of the logarithmic multiplicative law (which multiplies the observed object thickness by ), the -similarity of and according to means that there exist two thicknesses and such that and belong to the same -tube. Moreover, it is possible to exhibit a Tolerance Tube centered on the studied grey level function. In fact, if we consider a grey level image and a tolerance value related to the Asplünd's metric, the neighborhood is the union of all the tubes . Among them, consider the tube defined by a pair of real numbers and computed to have symmetric values around the unit integer 1, for example such that and . Such a tube is centered at and the condition yields:
which gives the values of
and
:
and
The resulting tube is displayed in Figure 3-16.
22
f+ε
f f-ε
Figure 3-16- Visualization of a tolerance tube centered at f We are now focusing on the main drawback of the Multiplicative Asplünd’s Metric: its sensitivity to noise, which is a weakness shared by every atomic metrics. III-4-3-How to overcome the noise sensitivity of Multiplicative Asplünd’s Metric This point has been studied in [11], thus we will only present here a summary of this paper in which some examples of the Multiplicative Asplünd’s Metric have been exposed, like detection of human skin pores or extraction of dermal papillae from images acquired in confocal microscopy. In order to highlight the sensitivity of Multiplicative Asplünd’s Metric to noise, let us start with an initial image whose representative surface is a tilted plane (cf. Fig. 3-17-a) and Fig. 3-17-b)). A salt and pepper noise is added to (cf. Fig. 3-17-c) and Fig. 3-17-d)).
a)
b)
23
c) d) Fig. 3-17-a) Initial image f with a linear drift Fig. 3-17-b) Representative surface of image f Fig. 3-17-c) Image g: image f with salt and pepper noise added Fig. 3-17-d) Representative surface of image g Fig. 3-17 A synthesis image f and its noised version The computation of the Multiplicative Asplünd’s distance between and may be done thanks to the probing of image by (cf. Fig. 3-18). It appears clearly that the local maxima/minima of determine the probes locations, which shows precisely the sensitivity to noise of
a) b) Fig. 3-18-a) Representation of the probing of g by f (2-D representation) Fig. 3-18-b) Representation of the probing of g by f (3-D representation) Fig. 3-18 Sensitivity to noise of Let us now expose a solution to overcome this drawback of We will adapt to our particular situation a metric (later noted -metric) defined in the context of “Measure Theory”. Our goal here is not to deeply enter this theory, so we will limit to a short recall adapted to the context of grey level images defined on a subset of . Given a measure on , a grey level image , a metric on the space of grey level images and two arbitrary small positive real numbers and , a neighborhood of may be defined according to:
Such a definition implies that the measure of the set of points overcomes the tolerance satisfies another tolerance .
where the distance
Now, let us adapt this approach to the context of Asplünd's metric: -
The grey level image being digitized, the number of pixels lying in is finite, thus the “measure” of a subset of is directly linked to the cardinal (number of pixels) of 24
this subset, for example the percentage of its elements related to interest included in ). In our case, we search a subset of
(or a region of such that the
restrictions and of and to are neighbors for and at the same time the complementary set of related to is small sized when compared to . This last condition means that the ratio of the cardinals of and is smaller than an arbitrary acceptable percentage :
In such conditions, the neighborhood
-
becomes
Let us now explain the role played by the -metric in the case of the oblique plane (cf. Fig. 3-18). For decreasing the Asplünd's distance between and , we need to move closer together the probing functions and thanks to the -metric. If we report to the definition of this metric, the set corresponds to the part of where the highest noise peaks are located. Before presenting more precisely the method, let us visualize (Fig. 3-19) the set emerging through the probing functions for the thresholds values and . These values mean that the set represents of the set (Fig. 3-19-a) and of the set (Fig. 3-19-b). It appears that a small-sized restriction of the set permits to strongly decrease the Asplünd's distance, and thus to overcome the noise effect.
a)
b)
Fig. 3-19-a) Probing of g by f with tolerance p = 0.98 Fig. 3-19-b) Probing of g by f with tolerance p = 0.95 Fig. 3-19- Getting probing functions closer to the target Associated with Asplünd's distance, the -metric permits to determine a set satisfying the distance (percentage) condition. The method takes in consideration the differences, pixel per pixel, between two images, and more precisely the histogram of these differences. This subtraction does not imply any problem because the superior probing function is always superior to the image , which is superior to the inferior probing 25
function . In such conditions, the resulting differences always remain in the greyscale. The histograms corresponding to the differences between and (resp. and ) are presented in Fig. 3-20-a (resp. 3-20-b).
a)
b)
Fig. 3-20-a) Histogram of the differences between λ⨻f and g Fig. 3-20-b) Histogram of the differences between g and μ⨻f Fig. 3-20 Differences between g and its probing functions Let us remark that the first bin of each histogram (value 0) represents the number of contact pixels between the two corresponding images. In order to decrease Asplünd's distance, the probing functions and must be as close as possible to . Thus we decided to disregard the pixels corresponding to the first bin of the actual histogram of differences, until the most relevant bins have been reached. Neglect the first bin means that the following bin is considered as the new first one. This step modifies the selection of the pixels making contacts: they will be closer to the image . Now let us define the real numbers (resp. ) corresponding to the bins making contact between the images and (resp. and ). Initially, and they are pointing on the real first bin of the histograms. In this situation,
and
determine the initial Asplünd's distance
. If now we increase
for instance, a new will be computed such that the bin becomes the bin making a contact. In other words, if is a pixel belonging to the first bin of the histogram of differences between and , we can write and For
, a similar approach is performed: if
of differences between
and
, a number
belongs to the first bin of the histogram is computed such that:
and The scalar
(resp.
the superior probe closer to . The scalars
) is the grey-level number we must subtract (resp. add) from
(resp. to the inferior probe ) in order to get the contact points and are increased until the percentage has not been reached. 26
The set of pixels belonging to the bins of the histograms which are neglected corresponds to . A new Asplünd's distance (smaller than the previous one) is computed for each new pair For evaluating this technique on a real example, let us come back to the image “Bricks wall” presented in Figure 3-12-a. We apply it a Salt and Pepper noise and we show (cf. Fig. 3-21) the results obtained thanks to the -metric for various values of the percentage
a)
b)
d)
e)
f)
g)
c)
h)
Fig. 3-21-a) Initial image f: Bricks wall Fig. 3-21-b) Image f with Salt and Pepper noise added Fig. 3-21-c) Target (magnified) 27
Fig. 3-21-d) Extraction of the target from image a) thanks to Fig. 3-21-e) Extraction of the target from image b) thanks to Fig. 3-21-f) Extraction of the target from image b) thanks to the M-Metric when the percentage p of neglected points equals 0.98 Fig. 3-21-g) Extraction of the target from image b) thanks to the M-Metric when the percentage p of neglected points equals 0.95 Fig. 3-21-h) Extraction of the target from image b) thanks to the M-Metric when the percentage p of neglected points equals 0.90 Fig. 3-21 Detection of a target (here a brick wall) on a noisy image Comments on Fig. 3-21: All the displayed images use the same standard grey scale: a dark area corresponds to a small value of Asplünd's distance, and the lighter it is, the larger the distance. Images (d) and (e) show the detection of the chosen target (image (c)) when applying the standard Multiplicative Asplünd’s Metric: Obviously, no information can be extracted (image (e)) from the noisy image. Images (f), (g), (h) correspond to the target extraction from the noisy image (b). They have been obtained for various values of the percentage of neglected pixels ( , , , for (f), (g), (h) respectively. They prove that the -metric permits us to improve the result produced on (b) by the standard Multiplicative Asplünd’s Metric and to finally get a quality comparable to that obtained without any noise (image (g) corresponding to the percentage ). However, if the percentage value decreases too much, we can observe the emergence of horizontal black lines (image (h)). Such lines are due to the fact that the vertical boarders between two successive bricks are small enough to be neglected at the considered percentage. In conclusion, the -metric appears efficient to overcome the problem of noise sensitivity of the Multiplicative Asplünd’s Metric. Nevertheless, a research remains to do in order to find an automated method for determining the optimal percentage adapted to a given noisy image. This would probably necessitate a hypothesis on the noise nature. Another way to approach this problem would consist of studying the curve representing Asplünd's metric decreasing according to the percentage of neglected points.
III-5-The Additive Asplünd’s Metric Plenty of papers dedicated to the LIP Model use it through a minor property: its ability to transform a linear processing in a logarithmic one i.e. to act as a logarithmic Look Up Table. This remark does not mean that the concerned papers are of limited interest, but they remember existing methods, which damages their novelty. I want here to warmly thank Dennis Deng, one of the first PhD students to dedicate their research work to the LIP Model. In fact, Dennis said me two years ago: “what limits the notoriety of the LIP model is it fails in proposing one or two killer applications”. I must admit that this opinion led me think about what could be such a killer application.
28
I hope that the results exposed in the present section contribute partially to answer the question: the introduction of an Additive Asplünd’s Metric appears us as a first step for introducing Image Processing tools able to overcome the difficult situation of uncontrolled lighting. This point appears as a crucial one and in our knowledge, general solutions do not exist. After we had extended the binary Asplünd’s metric to grey level images thanks to the logarithmic scalar multiplication, I must admit that it was not obvious to imagine an Additive variant of this metric founded on the logarithmic additive law. What oriented me in this direction was to consider the ability of the LIP addition to produce brightness variations on an image, and consequently to simulate and compensate lighting variations. The proposed Additive Asplünd’s Metric answers well such questions: in particular, it will be shown that it is a tool theoretically insensitive to exposure time variations (cf. Chapter V, Section V-2). The main remaining weakness is the sensitivity to noise, but a first solution has been mentioned in section III-4-3 for the Multiplicative Asplünd’s Metric, which would be adaptable to the Additive one. III-5-1- Definition of this novel metric The novel metric we study in the present paper is not properly an Asplünd-like metric, because it is not defined by means of homothetic functions, but thanks to the LIP additive law. Nevertheless, it obviously remains in the class of Double Sided Probing metrics. Given two grey level images
and , we define two real numbers
and
according
to:
{ where lies in the interval and designs a region of the spatial support , possibly itself (cf. Fig. 3-22). In such conditions, is always greater than , lies in the interval and in the interval , which means that, in the definition of , the probing function is not always an image. For evaluating the “distance” between the probing functions and seems natural to take into account the difference . After observing that its values in
, we will compute
, it takes
which will be interpretable as a grey level.
We are now able to evaluate the Additive Asplünd’s distance and according to the formula:
between
(2) 29
Remark 7: such a value remains unchanged when function In fact, the constant becomes
(or ) is replaced by a “translated” and becomes .
The previous remark implies that:
Figure 3-22 Additive Asplünd’s distance between function. Remark 8: Instead of defining
on the space
and
, where
is the probing
of grey level images, it is more
adequate to associate each image with its equivalence class, noted images such that for some constant lying in .
, constituted of
Thus we consider the space
and the following result holds: The application
associating to a pair of equivalence classes is a metric on the space
Proof: In fact, 1)
2)
(D, [0,M[)
satisfies the properties of a metric: takes its values in
The constants thus
the distance
and
: correspond respectively to the superior and inferior probes,
and (Symmetry condition)
The rigorous expression of this condition is: 30
Nevertheless, it has been seen that such values remain unchanged when the equivalence classes example.
and
are replaced by any of their elements, say
and
In a first step, is considered as the probing function, and the constants defined in order to satisfy:
and
If now represents the probing function, let us consider the functions and . We apply them the subtraction and we get the resulting functions: and
for
are
and
(cf. Figure 3-23)
Then Moreover,
This means that
satisfies:
is the constant
performing the inferior probing of
by
In the same way,
and
appears as the constant
performing the superior probing of
by .
Finally,
Fig. 3-23 Illustration of the symmetry property 31
3)
satisfies the separation property:
We have to prove the following equivalence:
-Suppose
. It implies that
for some constant
and we have
seen (cf. Remark 7) that -To establish the other implication,
4)
yields:
satisfies the triangular inequality:
Let us consider three images
and . We must establish the following inequality:
To the distance , we associate the “probing” constants (cf. Fig. 3-24). Such constants satisfy the double inequality:
of
To the distance , we associate the “probing” constants (cf. Fig. 3-24), which satisfy:
of
Now we perform the probing of image by , resulting in two constants corresponding to the superior and inferior probes.
by
and
Figure 3-24 Triangular inequality property We can write:
32
(α) On another hand:
(β) From (α) and (β), we deduct: and
This result is obtained by definition of
:
Finally:
III-5-2- Main property: insensitivity of the Additive Asplünd’s metric to exposure time variations III-5-2-1- Theoretical case: simulated exposure times In a previous paper [12], we established that the LIP addition of a constant to a gray level image permits to precisely estimate images of the same scene acquired under other exposure times. Such a property has been refined and extended to color images [13]. This subject will be detailed in Chapter V. If we refer to the remark of Section 3.1, the following result holds:
Remark 9: In such conditions, considering an image and images of the same scene simulating the acquisition of under variable exposure times (Figure 3-25-a), it becomes possible to perform the recognition of a target extracted from (Figure 3-25-b) in every image . In fact, if is defined on a region , for each image , we move the target inside and for each location of at a pixel , we compute the Additive Asplünd’s distance between and the restriction of to , noted . Such a distance takes its values in the standard grey scale
and is then a grey 33
level assigned to . In such a way, we get a map of Additive Asplünd’s distances between the target and the corresponding region of (Figure 3-25-c) and Figure 3-25-d). The location of the target corresponds to the values 0 observed inside the map (Figure 3-25-c and Figure 3-25-d).
f
f
140
Figure 3-25-a- Initial image f. Images f
f
180
f
240
K, K = 140, K = 180, K = 240.
Figure 3-25-b- Target T extracted from f: the eye of Lena magnified four times
Figure 3-25-c- and Figure 3-25-d- Asplünd’s maps for f and f the target corresponds to a black pixel.
240: the location of
Fig. 3-25 Location of a target independently of simulated exposure times III-5-2-2- Real case We know that probing metrics are very sensitive to noise. It is the reason why we proposed in [11] a solution to overcome this drawback. The previous section III-5-2-1 has 34
shown the major interest of the Additive Asplünd’s metric at a theoretical level. We will now focus our study on real acquisitions of a same scene under variable exposure times. Let , at exposure times target selected inside
,
,
represent images of a same scene acquired respectively , , , (Figure 3-26-a) and a for example ( Figure 3-26-b).
We proceed as for the theoretical case: for each location of , we compute the Additive Asplünd’s distance between and the restriction of to , noted . We get a map of Additive Asplünd’s distances between the target and the corresponding region of (Figure 3-26-c). It remains to extract the minimum of each map to locate the target (Figure 3-26-d for
for
Fig. 3-26-a- Images
for
,
Figure 3-26-b- Initial target the black arrow
for
,
for
,
(magnified 6 times) selected in
at the extremity of
Figure 3-26-c- Maps of Additive Asplünd’s distances between the target and a corresponding region of , , . 35
Figure 3-26-d-Asplünd’s map for . Magnification of the target location inside the image : it corresponds to the minimum of the Additive Asplünd’s distance (black pixel). Figure 3-26 Location of a target independently of exposure times First comments on this metric: a novel “Asplünd-like” metric has been proposed, named Additive Asplünd’s metric. Precisely, this metric is defined on the space of equivalence classes
which means, in a mathematical formulation, on the Quotient Space of Equivalence Relation R :
by the
R If we remember that the logarithmic addition (resp. subtraction) of a constant to (resp. from) an image permits to simulate images of the same scene acquired under arbitrary exposure times, we can conclude that the Additive Asplünd’s metric is absolutely insensitive to exposure time variations. This point is mathematically established at a theoretical level (case where exposure time variations are simulated). When considering real cases, where images are acquired at various exposure times, we could fear that this insensitivity property fails, due to quantification effects and decreasing of SNR on dark images. Nevertheless, the detection of a target has been successfully performed (cf. Figure 3-26). III-5-3- Other examples of application In this section, we selected some examples illustrating the interest of the Additive Asplünd’s metric insensitivity to exposure time variations. III-5-3-1 Region Growing Algorithm (RGA) Let us recall the basic RGA, called Single Linkage (cf. [14] for example). Given a grey level image , we start with a seed selected in and we consider the -neighborhood 36
of . The first step consists of aggregating to the elements of similar to . Similarity is classically satisfied when the grey level difference between and a candidate is less than a fixed threshold . This step results in a region . For the following step, we consider as candidate a pixel lying in the external -boundary of and the condition to aggregate y to is that there exists a pixel similar to in the intersection . The process is iterated until the convergence step, which means when no more new pixel may be aggregated to the current region. Remark 10: It is possible to evaluate similarity by means of a distance: two pixels are similar if their distance is less than . This is what we are presenting now, using the Additive Asplünd’s metric, but we must take into consideration that by definition the Additive Asplünd’s distance between two grey levels always equals zero. For that reason we propose to consider the -neighborhoods of the studied pixels and . If the 9 elements of are noted we define:
where
3-5-3-1-1 Theoretical case: simulated exposure times As established for in section 3-5-2-1, the local metric is theoretically insensible to exposure time variations. To establish this property, let us consider the initial image (Lena, Figure 3-27-a) and we simulate exposure time variations of : ,
,
(Figure 3-27-b).
Then we choose a seed (white cross, Figure 3-27-a), and we perform a RGA by means of the Additive Asplünd’s distance, with a similarity threshold The Region obtained (represented in white, Figure 3-27-c) is obviously independent of the considered exposure time.
Fig. 3-27-a- Initial image (Lena) and the initial seed (white cross)
37
f
f
140
f
180
Fig. 3-27-b- Simulations of exposure time variations: f, f
f
f
140
f
f 140, f
180
240
180, f
f
240
240
Fig. 3-27-c- Regions obtained with the initial seed, ε = 12 and the Additive Asplünd’s metric Fig. 3-27 Insensitivity of Region Growing to exposure time variations thanks to the Additive Asplünd’s metric Let us note that other metrics fail in performing RGA on images acquired under variable exposure times. This point is illustrated (cf. Figure 3-28) for RGA applied to the same sequence of images used in Figure 3-27. In order to drive the aggregation process, we used the Euclidean distance between the grey levels of two pixels (i.e. the absolute value of their difference) and we chose a value of the similarity parameter to get, starting from the same seed, a region comparable to that obtained in Figure 3-26-c for the initial image of Lena. Then we applied RGA to the darkened images the same value of .
,
,
with
Fig. 3-28 Region Growing applied to Lena (image ) with the same initial seed and with aggregation parameter . In white, the obtained regions for , 38
Remark 11: The previous result concerning the insensitivity of Additive Asplünd’s metric to lighting variations is not surprising, because the logarithmic addition (resp. subtraction) of a constant to (resp. from) an image permits together to simulate exposure time variations and to define the Additive Asplünd’s Metric itself. Nevertheless, it opens a new way to process images under variable lighting, which consists of defining and applying invariant tools instead of searching to enhance/stabilize such variable images with more or less efficient algorithms. III-5-3-1-2 Real case We proceed as for the theoretical case, but the considered images of a grey level chart are acquired at various exposure times, here 7.5ms, 15ms, 30ms and 50ms (Figure 3-29-a). Then we choose an initial seed (white cross, Figure 3-29-b) and we perform the region growing by means of Asplünd’s metric with (Figure 3-29-c) and by means of Euclidean’s metric with (Figure 29-d). The values of are the same that in the theoretical case.
7.5ms
15ms
30ms
50ms
Figure 3-29-a- Acquisition of the gray level chart under various exposure times
Figure 3-29-b- Initial seed (white cross)
Figure 3-29-c- Results of Region Growing by means of Asplünd’s metric (exposure times: 7.5, 15, 30 and 50ms) 39
Figure 3-29-d- Results of Region Growing by means of Euclidean’s metric (exposure times: 7.5, 15, 30 and 50ms) Figure 3-29 Compared results of Region Growing algorithm driven by Asplünd’s and Euclidean’s metrics Comment on Figure 3-29: The proposed example shows clearly that the Asplünd’s driven RGA is very stable compared to the Euclidean case. Nevertheless, as previously said, probing metrics are very sensitive to noise, thus it is possible that this problem occurs in other situations (darker images, bad quality of the sensor…). We would just remind that we proposed a solution to attenuate this drawback in the case of the Multiplicative Asplünd’s Metric (cf. previous section III-4-3 or [11]) by neglecting a percentage of pixels: the most penalizing ones to perform the probing and compute the Asplünd’s distance. Such an approach is obviously adaptable to the case of the Additive Asplünd’s Metric. Another possible solution would be to apply to the studied images a Noise Filtering Algorithm as a pre-processing. Note that this technique is more efficient if we have determined an appropriate model of the noise nature. III-5-3-2 Contour detection To put in evidence the contours present inside an image , it is possible to use the local metric
previously defined in Section III-5-3-1 (Remark 10).
Such a metric permits to compute the distance and each of its 8 neighbors
between a pixel
.
From these 8 values lying in the grey scale according to:
, we can derive a grey level
In this way, we get a Gradient Additive Asplünd Map (
) representing, for each
pixel , the grey levels variations of any image of the equivalence class (cf. Remark 8), in a neighborhood of . This means that the is the same for all images K: in other words, the proposed Contour Detection method will be theoretically independent of the exposure time value.
40
Remark 12: A variant of the previous gradient consists of replacing in the definition the term “Max” by an average value “Mean”, computed for example in a logarithmic manner:
where
represents the LIP-sum.
Remark 13: We will not develop this point. Similar approaches are proposed in ([1], section 2-3-2) where the Asplünd’s distance was simply replaced by the Additive Contrast. For all these approaches, the interested reader will take into consideration their sensitivity to noise. The present section aspires essentially to propose a novel tool and to prove its efficiency in several situations. Thus we will limit us to the examples previously exposed, even if many other applications of the Additive Asplünd’s Metric could be presented like characterization of pseudo-periodic textures by means of autocorrelation, covariograms…(cf. Fig. 3-8 dedicated to the approach of this problem by means of the Multiplicative Asplünd’s Metric). III-5-4- Conclusion of Section III-5 and perspectives The notion of “metric” is one of the most useful in image processing. In fact, a metric is able to efficiently replace correlation tools, contrast or gradient concepts (interpreted as the distance between two grey levels)… It permits for example: -to perform pattern recognition -to compare remote sensing images in order to detect what has changed between two acquisitions -to locate a given target inside an image or to follow it in a video stream -to perform autocorrelation of an image in order to detect for example pseudo-periodic structures Nevertheless, most of existing metrics do not possess strong physical justifications. The Additive Asplünd’s Metric defined in the present section takes place in the LIP framework and is thus built on the Transmittance Law, which makes it optimal to process images acquired in transmission. Moreover, the consistency of the LIP Model with Human Vision permits to interpret images in reflection as a human eye would do. Finally, the Additive Asplünd’s Metric is actually insensitive to lighting changing and particularly to exposure time variations. To show such properties we have chosen, among plenty of possible subjects, to focus on the location of a target and on the Region Growing algorithm. 41
Concerning future works, we plan: -to establish another property of the Additive Asplünd’s Metric: its ability to simulate variations of diaphragm aperture. This point is partially done and some results are exposed in Chapter V. -to extend the results to color and multivariate images (partially done, cf. following Section III-6).
III-6-Examples of Metrics for Color Images We explored three ways to develop this point. The first one consists of considering the LIPC (LIP Color) Model, the second to build metrics associated to contrasts and the third to create Asplünd-like Color Metrics. The present Section III-6 will mainly focus on the third approach for two reasons: on one hand, it is the most original, and on the other hand, the Asplünd-like Metrics will possess very strong properties thanks to the LIP laws. III-6-1-LIP-C approach We presented an extended paper on the LIP-C Model ([15]) where the interested reader will probably find some points which remain to develop. This Model has been founded on visual experimentations (tables of Stiles and Burch: http://cvrl.ucl.ac.uk) in order to be consistent with Human Vision. LIPC obviously permits to generalize Asplünd’s metrics to Color Images. Nevertheless this Model produces a rather complex environment. For this reason we will propose simplified approaches. III-6-2-Extension of LAC to color images and associated metrics This point has been initialized in Chapter II, Section II-3-2-, where we have shown how various Color Metrics can be deducted from the Logarithmic Additive Contrasts defined in each channel . Such metrics are probably interesting to study in depth but it is not our objective here. III-6-3-Asplünd-like Metrics for Color Images From now and all along the present Section III-6-3, the various Asplünd-like Metrics dedicated to Color Images will be noted with a subscript : and a superscript ⨻ or ⨹ according to the nature multiplicative or additive of the metric:
or
.
Note that the present study of Asplünd-like metrics is an extension of Chapter II, Section II-3 where we shortly introduced the Multiplicative Asplünd’s Metric between two colors and the Logarithmic Additive Contrast for Color images. III-6-3-1-Multiplicative Asplünd-like Metric Between two colors: 42
Before extending the Multiplicative Asplünd’s Metric to color images, let us define it between two colors and . We will note it
and we propose the following definition:
where
(3)
Remark 14: The previous approach (3) seems us an interesting compromise between the use of LIPC and a trivial solution consisting of computing a distance in each channel as we have done for grey levels, and gathering them in different manners. Remark 15: Let us highlight a strong advantage of the Color Multiplicative Asplünd’s Metric: it remains unchanged when one color ( for example) is replaced by any homothetic for . Remember that is brighter than when and darker than when This property shows the insensitivity of to strong illumination variations modelled by the logarithmic multiplicative law. From the definition of and the previous Remark 15, it would be more rigorous to present the Color Multiplicative Asplünd’s Metric as we made in section III-3-2, by means of an equivalence relation R on the space of Colors. Given a pair of colors relation” if they satisfy: (
R
and
, we say they are “in
)
i.e.
and
Then we associate each with its equivalence class grouping the colors which are in relation with . From a rigorous point of view, is defined on the set of color equivalence classes (see the “Mathematician” Section of III-3-2). Between two Color Images: Knowing the distance between two colors, we can deduce various distances between two color images and on a subset D. We adopt here the notation instead of for the Region Of Interest in order to avoid confusion with the Red channel . First solution: distance
(cf. G. Noyel [16])
43
with:
Remark 16: In the whole spatial support is taken in consideration instead of a subset , the notation for the previous distance will be simply:
Remark 17: The previous definition is easily extended to multivariate images by applying the and onto all the corresponding channels. Remark 18: As for grey level images, this probing metric is sensitive to noise and the solution we exposed hereinabove (cf. Section III-4-3) has been demonstrated applicable for color and multivariate images. Now let us propose an application example similar to that expose in Section III-4-1 dedicated to target tracking. We consider an initial color image representing a “Bricks Wall” (cf. Fig. 3-30-a)) and we select a target constituted of one brick (cf. Fig. 3-30-b)). It is thus possible to create the Asplünd’s map associated to the Multiplicative Asplünd’s Metric where designs precisely the restriction of to the subset of corresponding to the target location (cf. Fig. 3-30-c)). From this Asplünd’s map, it is quite easy to extract each brick of the wall (dark points in Fig. 3-30-c)).
a) b) c) Fig. 3-30-a) Initial Color image f (“Bricks Wall”) with selected target Fig. 3-30-b) Color target t (magnified 2 times) Fig. 3-30-c) Asplünd’s map of b) inside a) Fig. 3-30 Example of Color Target Tracking thanks to Multiplicative Asplünd’s Metric
44
Another example is given in [16] concerning the detection of a target inside a lowlight image. This point is illustrated in Fig. 3-31 where a ball has been selected on the initial image “Christmas Tree” (3-31-a)). The goal is to detect all the Christmas balls on a low-light version of image a). The final result is shown in Fig. 3-31-b) and the balls locations have been extracted without difficulty from the Asplünd’s map (Fig. 3-31-c)) of inside the dark version of a).
a)
b)
c)
Fig. 3-31-a) Initial Color image f (“Christmas Tree”) with selected target t Fig. 3-31-b) Detected Christmas balls on a low-light version of a) Fig. 3-31-c) Asplünd’s map of t inside the low-light version of a) Fig. 3-31 Color Target tracking on a dark image Remark 19: In [16], Noyel makes a comparison, in the situation of Fig. 3-31, between the Multiplicative Asplünd’s approach and color metrics classically used in the Lab context, like:
and the associated ones: or It appears that the superiority of Asplünd’s metric is unquestionable. Second solution: Knowing the distance between two colors in one point of the region of interest , it becomes possible to take into account all the points lying in and to cumulate the information in the manner of (resp. ) according to: 45
Or III-6-3-2-Additive Asplünd-like Metric As we made for the Multiplicative Asplünd’s Metric, let us first define the Additive Asplünd’s Metric between two colors and . We will note it
and we propose the following definition:
Where
(4)
Remark 20: This Color Additive Asplünd’s Metric
is not a color but a real
number. More precisely lies in the interval and is thus interpretable as a grey level without any normalization. In fact, as for grey level images, we have always: and This implies that is divided by 2.
and justifies the definition of
where
Example of application: As we have already done for grey level images, we can apply this metric in various situations like Region Growing, Contour Detection…and we know that the results will be faintly sensitive to exposure time variations, to lighting variations and to lighting drift. We limit us to an example of contour detection on the image “Peppers” in presence of lighting drift, compared to the classical Sobel filter applied to the luminance image (Fig. 3-32). To do that, we need only to define for example the average distance (grey level) G(x) between a pixel and its eight neighbors according to: (5)
46
a)
b)
c)
Fig. 3-32 a) Initial image “Peppers” with lighting drift Fig. 3-32 b) Sobel filter applied to a) Fig. 3-32 c) Result of contour detector defined in (5) Fig. 3-32 Sobel applied to the luminance image compared to Color Additive Asplünd Gradient Now, starting from the Additive Asplünd’s distance between two colors, if we aim at defining the Color Additive Asplünd’s Metric between two color images and , we can adopt the same reasoning that for the Multiplicative Asplünd Metric (section III-6-3-1-) where three solutions were proposed. We leave the interested reader make these developments by himself.
III-7- Other notions around metrics III-7-1- Recalls It is well known that Topology is the “neighborhoods science” and is available in many configurations depending on the structure of the space on which it is defined: -
General Topology does not require any hypothesis and is then usable on a simple set without structure. It consists of a family T of subsets of satisfying the following basic properties: ° and T °Any union of elements of T is an element of T °A finite intersection of elements of T is an element of T A pair ( , T) constituted of a set and a family T satisfying the previous hypotheses is called a Topological Space, the elements of T are the Open sets of ( , T) and a subset of verifying where is an open set is a neighborhood of . A very complete reference on the subject has been written by Dugundji ([17]). A particular example of Topological Spaces is constituted of Metric Spaces: -
A Metric Space is a set equipped with a metric (distance) which means: is defined on with values in satisfying the properties recalled in Section III-2-1 of the present Chapter. In such case, a neighbor of is a set containing an open ball including x.
Fundamental Remark: Some particular concepts stronger or weaker than metrics require a Vector Space Structure to be defined. It is the case for example of Scalar Products and Norms (stronger concepts) and Gauges (weaker notion). The space is a Real Vector Space (cf. Section I-2-2, Chapter I) and we are thus justified to study these 47
topological notions in the context of images. Nevertheless, our objective here is not to develop these points in detail, even if we are convinced of their interest, especially concerning Gauges. We will simply evoke them in the following two sections. III-7-2- Notions stronger than metrics Pinoli proposed in [18] a definition of Scalar Product between two grey level images according to:
and
The discrete version is obtained from the previous formula by replacing the double integral by a double sum and the points by pixels . It is well-known that from a Scalar Product we can derive a norm correlation coefficient
and a
Remark 21: Such a correlation coefficient offers obviously an applicative interest: it permits for example novel approaches of target tracking or covariograms (auto-correlation). In this occasion, we focus on the difference between a Correlation approach which tries to optimize the overlapping of functions (in fact of their sub-graphs) and a Probing approach (like Asplünd’s metrics) which uses one image to surround the other by means of ordinary or logarithmic scalar multiplication or addition of a constant. III-7-3- Notions weaker than metrics III-7-3-1- Recalls on gauges theory in Vector Spaces and Topological Vector Spaces This part mainly concerns mathematicians or readers being curious of novel notions in image processing. In fact, the notion of Gauge is classical in the field of Vector Spaces and it seemed me interesting to propose a short summary on this subject, in direct link with Asplünd’s metrics. Before introducing the Gauge concept, we need some recalls: -
The notion of Vector Space has been done in Chapter I, when we studied the set . If is a Real Vector Space and A is a subset of E: o is said balanced if o is said absorbing if
48
It is easy to verify that a balanced set contains necessarily the origin space and that is symmetric with respect to . In the same way,
of the vector
is always an element of an absorbing set .
Now let us define a Gauge: Definition:
being a subset of , we call Gauge of defined on with values in :
the following application (function)
if it exists some +∞ if for every
such that
,
Remark 22: Here are some basic properties of gauges: 1234-
If If If If
is absorbing, and if is a subset of with a. b. If is convex: c. If is balanced: d. If is convex, balanced and absorbing (i.e. a disk), norm on
is a semi-
Remark 23: The concept of Gauge exists in particular in Topological Vector Spaces (cf. [19]), i.e. Vector Spaces equipped with a topology compatible with the Vectorial Structure, which means that the two laws (addition and scalar multiplication) of this Vectorial Structure are continuous:
In this situation, topologies.
and
from
is continuous
from
is continuous are equipped with the corresponding product
For mathematicians familiar with Topological Vector Spaces, it is well-known that in such a space , each neighbor is absorbing, thus it generates a Gauge III-7-3-2- Definition of gauges in Image processing In the case of the subspace of the Vector Space , it is obvious that the sub-graph of any image is a neighborhood of where is the origin of or i.e. the image null in every point of (cf. Fig. 3-33). 49
M Neighborhood
associated with
= g
Sub-graph of g Fig. 3-33 Neighborhood of
generated by an image
Comment on Figure 3-32: If we consider an image which absorbs for the first time is defined by:
in the space of images
, the homothetic
Note that it corresponds precisely to the superior probe of image define the Multiplicative Asplünd’s distance between and .
by
permitting to
This remark gives a novel interpretation of the probing approach and in particular of the Asplünd-like metrics. Moreover, we are justified to ask if it would be interesting (and first possible) to introduce inferior probing in Topological Vector Spaces. In case of positive answer, we can plan to define Asplünd’s metrics in such spaces.
III-8- Conclusion and perspectives In this Chapter, we introduced novel metrics in link with LIP operations ⨹ and ⨻ and we proposed a special focus on Asplünd-like metrics, due to their high interest in the processing of images acquired under low lighting, or variable lighting. In the Introduction of the present book, I explained the reasons which encouraged me to introduce the LIP addition. The motivation was mainly to develop a grey level mathematical morphology where structuring elements could be grey level functions themselves. However, the logarithmic operators opened me plenty of novel research ways with efficient applications, so that the initial objective was temporarily forgotten. The Asplünd’s Metrics I introduced drive me back to the founding ideas. In fact, we have seen how the probing and moreover the double sided probing techniques consist of 50
moving a grey level image (the probe) in upper and lower contact with the representative surface of the studied image. This point of view appears as the next episode of the abundant literature devoted to 3D structuring elements and particularly grey level ones (see for example Serra ([20])). Considering we dispose now of various metrics, I want to come back to the application “automated thresholding” presented in Chapter II, Section II-1-6-1 and Section II-2-2-1 where we used only LIP Additive Contrast and LIP Multiplicative Contrast to propose novel versions of Köhler’s method. My goal is not here to enter in depth in the numerous existing automated thresholding techniques I studied thirty years ago. At this time, I introduced a new algorithm based on functional metrics. The principle of this algorithm uses the concept of metrics to find the binary image which most closely resembles the initial image. Let us recall some notations: is the initial image and a threshold within the interval . To we associate a binary image constituted of two classes and defined as follows: and Such classes permit to build a step function
according to:
and where and (cf. Fig.3-33).
represent the grey level average values of
and
, respectively
M
0
Fig. 3-33 Initial image
(in blue) and associated step function (in red)
Now let us consider a functional metric , in order to evaluate the similarity between and . With such notations, we propose the following automated thresholding method: 1- For each threshold 2- Select the threshold
, compute satisfying:
51
3- Apply
to
to get a binary image
Comment on the method: The major interest of this approach is that it generates different results according to the choice of the metric: - If is a global distance like , the corresponding method will be close to that of Otsu (Interclass Variance Maximization), with the same drawback: it will be insensitive to very small (in terms of area) defects. - If is an atomic distance like , the method becomes sensitive to very small defects, as the Entropy Maximization. - If we apply an intermediate metric (cf. III-2-2-2-1) we are able to create intermediate methods between the two extreme previous solutions.
52
References for Chapter III [1] M. Jourlin, M. Carre, J. Breugnot, M. Bouabdellah, “Logarithmic image processing: additive contrast, multiplicative contrast, and associated metrics”, Advances in Imaging and Electron Physics, vol.171, Elsevier, NewYork (2012), 357-406. [2] R. Köhler, “A segmentation system based on thresholding”, Computer Graphics and Image Processing, 15(4), (1981), 319-338. [3] Beucher, S. (1991). The watershed transformation applied to image segmentation. ScanningMicroscopy International, (1991), 299-314. [4] S. Beucher and C. Lantuejoul, “Use of watersheds in contour detection” International Workshop on image processing: Real-time edge and motion detection / estimation, (1979), Rennes, France. [5] N. Otsu, “A threshold selection method from grey-level histograms”, IEEE Transactions on Systems, Man and Cybernetics, 9(1), (1979), 62–66. [6] E.Asplund, “Comparison between plane symmetric convex bodies and parallelograms”, Math. Scand. 8, 1 (1960), 71-180. [7] B. Grünbaum, “Measures of symmetry for convex sets”, Proceedings of Symposia in Pure Mathematics, 7 (1963), 233-270. [8] M. Jourlin, N. Montard, “A logarithmic version of the top-hat transform in connection with the Asplünd distance, Acta Stereologica, 16(3), (1998), 201-208. [9] C. Barat, C. Ducottet and M. Jourlin, “Pattern matching using morphological probing”, IEEE International Conference on Image Processing (ICIP), (Vol. 1), (2003), 369-372). [10] C. Barat, C. Ducottet and M. Jourlin, “Virtual double-sided image probing: A unifying framework for non-linear grayscale pattern matching”, Pattern Recognition, Vol. 43, Issue 10, (2010), 3433-3447. [11] M. Jourlin, E. Couka, B. Abdallah, J. Corvo and J. Breugnot, “Asplünd's metric defined in the Logarithmic Image Processing (LIP) framework: A new way to perform double-sided image probing for non-linear grayscale pattern matching”, Pattern Recognition, 47 (9) (2014) 2908-2924. [12] M. Carré, M. Jourlin, “LIP operators: Simulating exposure variations to perform algorithms independent of lighting conditions”, International Conference on Multimedia Computing and Systems (ICMCS), Marrakech (2014) [13] V. Deshayes, P. Guilbert, M. Jourlin, “How simulating exposure time variations in the LIP Model. Application: moving objects acquisition”, 14th International Congress for Stereology and Image Analysis, 2015, Liège [14] R.M. Haralick, L.G. Shapiro, “Image Segmentation Techniques (Survey)”, Computer Vision, Graphics and Image Processing, 29, (1985), 100-132 [15] M. Jourlin, J. Breugnot, F. Itthirad, M. Bouabdellah, B. Closs, (2011), “Logarithmic Image Processing for Color Images”, Advances in Imaging and Electron Physics, Volume 168 (2), 65-107 [16] G. Noyel, M. Jourlin, (2015), “Asplünd’s Metric defined in the Logarithmic Image Processing framework for Color and Multivariate Images”, IEEE International Conference on Image Processing, Québec (Canada) 53
[17] J. Dugundji, (1966), “Topology”, Allyn and Bacon, 447 p [18] J.-C. Pinoli, (1992), “Metrics, scalar product and correlation adapted to logarithmic images”, Acta Stereologica, 11 (2), 157-168 [19] H.H. Schaefer, (1999), “Topological Vector Spaces”, Springer Verlag New-York, Second Edition, 362 p [20] J. Serra, (1983), “Image Analysis and Mathematical Morphology”, Academic Press, London
54