Automatic Coin Classification and Identification

We investigate object recognition and classification in a setting with a large number of classes as well as recognition and identification of individual objects of high similarity. Real-world data sets were obtained for the classification and identification tasks. The considered classification task is the discrimination of modern coins into several hundreds of different classes. Identification is investigated for hand-made ancient coins. Intra-class variance due to wear and abrasion vs. small inter-class variance makes the classification of modern coins challenging. For ancient coins the intra-class variance makes the identification task possible, as the appearance of individual hand-struck coins is unique. Figure 1 shows sample images for the considered collections of coins.


Introduction
We investigate object recognition and classification in a setting with a large number of classes as well as recognition and identification of individual objects of high similarity. Real-world data sets were obtained for the classification and identification tasks. The considered classification task is the discrimination of modern coins into several hundreds of different classes. Identification is investigated for hand-made ancient coins. Intra-class variance due to wear and abrasion vs. small inter-class variance makes the classification of modern coins challenging. For ancient coins the intra-class variance makes the identification task possible, as the appearance of individual hand-struck coins is unique. Figure 1 shows sample images for the considered collections of coins. Modern coins were acquired by a high-speed machine vision system for coin sorting described in detail by Fürst et al. (2003). For ancient coins the setting is more general, images acquired by scanner and camera devices are considered. We will also discuss the use of a 3D acquisition device and 3D models for ancient coins ).
The initial step of object recognition will be discussed as the problem of detection. i.e. foreground-background segmentation. Background knowledge on coins, i.e. the circular shape, which holds for most modern coins and is approximately true for ancient coins, is exploited in suggested segmentation methods . Invariance with respect to translation is solved by segmentation, scaling is covered by normalization and rotation is handled in the suggested methods for invariant description, classification and identification.
We will compare two approaches for classification of coins, a method based on matching edge features in polar coordinates representation (Nölle et al., 2003) and a method for matching based on an Eigenspace representation (Huber et al., 2005). Discussion on the influence of dirt and abrasion will be included. Classification of modern coins makes additional use of geometric measurements and information extracted from obverse and reverse side of the coins. Incorporation of geometrical measurements and fusion of coin sides is realized by preselection and Bayesian fusion. In order to limit the number of coin classes to discriminate the concept of multiple Eigenspaces (Leonardis et al., 2002) is applied in the Eigenspace framework. Rejection of unknown coins and a discussion on false classification and false acceptance rates vs. false rejection is included.
For identification of coins we will consider an approach based on shape features describing the edge of an ancient coin (Huber-Mörk et al., 2008;Zaharieva et al., 2007). Features are derived from the Fourier domain representation of the coin contour. Comparison of two coins is done by matching the features derived from contour representations. Bayesian fusion of coin sides is studied. In order to discuss the identification performance a discussion on precision vs. recall is included (Huber-Mörk et al., 2010). Improvement by 3D modeling and analysis is also presented (Hödlmoser et al., 2010).
Results are presented for all considered data sets and methods. The data set for classification of coins consisted of approximately 12 000 coins with images of reverse and obverse sides. The data set contained 932 different coin classes. A derived data set was made publicly available as a benchmark by the EU MUSCLE network of excellence . Depending on the acceptable rejection rate correct decisions are taken in more than 92% for the Eigenspace approach. With the edge matching method approximately 86% of the coins are either correctly classified or correctly rejected. Considering only valid coins, i.e. coins in the database of 932 coins, the Eigenspace approach achieved a correct classification rate of 94.58%, whereas the direct edge matching approach scored 84.79%. Correct rejection of invalid coins was obtained at a rate of 78.45% for the Eigenspace approach and 98,29% were achieved in the direct edge matching approach.

State of the art in coin image analysis
For modern coins, i.e. machine struck coins, judging systems using electromechanical devices are wide-spread. Those systems are commonly based on measuring weight, diameter, thickness, permeability and conductivity (Davidsson, 1996), oscillating electromagnetic field characteristics (Neubarth et al., 1998), and photo-and piezoelectric properties (Shah et al., 1986). Typically, such systems are only capable to discriminate a small number of different coin denominations and are mostly limited to a specific currency.
Approaches towards classification of modern coins using image processing are described in various papers and patents. A neural network approach capable of discriminating between 500 Won and 500 Yen coins was published by Fukumi et al. (1992). A number of coin authentification methods employing optical means are described in patents, e.g. a system by which both sides of a coin are first imaged by cameras, followed by feature extraction from binarized images, and finally combined with a magnetic sensor measurement is described by Hibari & Arikawa (2001). The so called Dagobert coin recognition system was developed for high volumes of coins and a large number of currencies (Fürst et al., 2003;Nölle et al., 2003). Image binarization followed by area measurement and comparison of coin center and center of gravity was also suggested in a patent (Onodera & M., 2002).
Another system based on the analysis of one side of a coin by transformation of its image into polar coordinates and matching of profiles taken along angle direction was described by Tsuji & Takahashi (1997). A special acquisition device for coins employing colored illumination from various angles was suggested by Hoßfeld et al. (2006). Methods based on matching gradient directions (Reisert et al., 2006; and color, shape and wavelet features (Vassilas & Skourlas, 2006) were suggested. An approach based on multiple Eigenspaces aims at classification for a large number of classes (Huber et al., 2005). This approach initially obtains a translationally and rotationally invariant description and secondly an illumination-invariant Eigenspace is selected from multiple Eigenspaces (Leonardis et al., 2002). Finally probabilities for coin classes are derived for the obverse and reverse sides of each coin and Bayesian fusion is performed.
For ancient coins, i.e. hand struck coins, some publications discussing approaches for classification appeared.
Early approaches, which achieved a moderate classification performance, were based on matching of contour and texture features (Van Der Maaten & Postma, 2006) or make use of interest point extraction and matching of local features (Zaharieva et al., 2007). More recently, an approach based on interest points and improved feature description and matching was reported (Arandjelović, 2010). The inherent properties of hand struck coins result in individual features of each coin and a large intra-class variance. Therefore, object classification becomes challenging. However, in contrast to object classification, object identification relies on those unique features which distinguish a given object from all other members of the same class. Results on identification of ancient coins were 4 Will-be-set-by-IN-TECH reported by Huber-Mörk et al. (2008), where the combination of shape and local descriptors to capture the unique characteristics of the coin shape and die information was suggested. For ancient coin recognition features from the Scale-invariant feature transform (SIFT) (Lowe, 2004) was used and compared to algorithms based on shape matching i.e. a shape context description and a robust correlation algorithm (Zaharieva et al., 2007). Ancient coins are in general not of a perfect circular shape. From a numismatic point of view, the shape of a coin is a very specific feature. Thus, the shape described by the edge of a coin serves as a first clue in the process of coin identification and discrimination. A shape based method tuned to the properties of ancient coins was combined with matching of local features through Bayesian fusion (Huber-Mörk et al., 2010).

Coin image preprocessing
The appearance of coins in 2D images is highly influenced by the lighting conditions and the orientation of the imaged surface. Coins are characterized by a 3D surface and the reflected light into the camera direction is typically a mixture of strong specular and diffuse refections depending on the placement of camera and light sources, the type of light sources, the coin surface structure, dirt and abrasion. In order to diminish the influence induced by the lighting conditions a controlled acquisition setup is recommended. Controlled acquisition strongly improves recognition of objects of low intra-class surface variation, e.g. modern coins. Ancient coins are characterized by high surface variation even within a single class, therefore different type and direction of light sources make small patterns on the coin look very different which limits, for instance, the use of local image features for coin recognition. Best practice for acquisition of ancient coins was summarized by  and Hoßfeld et al. (2006) described a sophisticated system for modern coin acquisition.
In this section, we will discuss preprocessing under controlled illumination for modern coins and slightly varying conditions for ancient coins. Since the shape of historical coins might not be as regular or flat as the shape of their present counterparts, it is a promising approach to calculate 3D models for higher coin matching rates. Therefore, we will also present acquisition of 3D data from stereo image pairs and stripe projection in this section.

Coin detection
The separation of an object of interest from background is commonly termed segmentation. Under controlled acquisition automatic intensity thresholding approaches (Sezgin & Sankur, 2004) are feasible for modern coins (Nölle et al., 2003). Due to textured background, presence of other objects in the image, inhomogeneous or poor illumination and low contrast, straightforward methods based on global image intensity thresholding tend to fail.
In situations, where explicit knowledge on the properties of objects is available, this knowledge can be used to steer segmentation parameters. For example, the compactness measure was used in a comparable application to find an intensity threshold in images showing circular spot welds by Ruisz et al. (2007).
Similarly, ancient coins were localized by thresholding the local intensity range, i.e. the difference between maximum and minimum graylevel, in a local window and evaluation of the compactness measure . Typically, the shape of modern coins is circular, whereas ancient coins deviate from this shape, but still stay close to a circular outline. Therefore, approaches based on edge detection and application of the Hough transform (Duda & Hart, 1972) were applied to modern coins (Reisert et al., 2006) as well as to ancient coins (Arandjelović, 2010), where a modified version of the Hough transform was used.
For a modern coin, such as shown in Fig.2 (a), we suggest an edge based technique to segment the coin from the background. The detection of the coin employs a common segmentation approach and works reliably for controlled lighting conditions and relatively clean background, e.g. a moderately dirty conveyor belt. Problems might be caused by very dark coins, i.e. coins which reflect only a small amount of light towards the camera. A multi-stage segmentation procedure is suggested. The outline of the suggested segmentation method is: 1. Smoothing of the image to suppress noise and background texture, see Fig.2(b).
2. Edge filtering using a Laplacian of Gaussian approach followed by zero-crossing detection (Marr & Hildreth, 1980) An example of an overlay of the extracted blob onto the input image is shown in Fig.2(f). Coin position and diameter are estimated from the detected blob, which directly delivers access to a translation invariant description.
For ancient coins we employ a measure of compactness c t related to a threshold t defined as where A t is the area of the region covered by the coin and P t is the perimeter of the coin. The measures A t and P t are obtained by connected components analysis (Sonka et al., 1998) 131 Automatic Coin Classification and Identification www.intechopen.com applied to the binary image which is derived from thresholding the intensity range image. Figure 3 (a) shows an intensity image of an ancient coin, Fig. 3 (b) is the corresponding intensity range image and Figs. 3 (c)-(e) show thresholded images for different selections of t along with calculated values for compactness c t . The image thresholded at the optimal level t opt with highest compactness is given in Fig. 3 (f). A sudden decrease of the compactness measure occurs with oversegmentation of the coin into several small regions, e.g. compare to Fig. 3 (e).

Invariant preprocessing for 2D images
Apart from illumination dependency the appearance of a coin varies considerably with respect to its grey values depending on dirt and abrasion. These variations frequently are inhomogeneous. This suggests, even if illumination influence could be neglected, that for recognition purposes grey values by themselves will not give appropriate results. On the other hand, edge information remains more or less stable or at least degrades gracefully. Therefore, we based the feature extraction for coin recognition on edges. In principle any edge detector may be used for this purpose. From our experience the approaches suggested by Canny (1986), by Rothwell et al. (1995) and the Laplacian of Gaussian method (Marr & Hildreth, 1980) work satisfactorily.
For reliable matching of coins invariance with respect to rotation has to be taken into account. Invariance with respect to translation is already discussed and taken into account by an approach involving segmentation in Sec. 3.1. Scale variance is accounted for either by using a calibrated acquisition device or normalization of the segmented image.
In general, rotational invariance is either approached via the use of geometrical moments (Hu, 1962), radial coding of features (Torres-Mendez et al., 2000), or using a mapping from Cartesian to polar coordinate representation, e.g. log-polar mapping (Kurita et al., 1998). A method based on the construction of an Eigenspace from uniformly rotated images was published by Uenohara & Kanade (1997). The application of their approach works through locating of a specific small pattern in a larger image. In a later paper (Uenohara & Kanade, 1998) an improvement of the location method based on the discrete cosine transform (DCT) was suggested.
We obtain rotational invariance by estimation of the rotational angle followed by a rotation into a reference pose. Angle estimation is performed for images transformed 132 Advances in Object Recognition Systems

www.intechopen.com
Automatic Coin Classification and Identification 7 into polar coordinates. In the polar image shift invariance, corresponding to rotational invariance when mapped back to Cartesian coordinates, is achieved through cross-correlation. Cross-correlation is efficiently implemented using the fast Fourier transform (FFT) (Cooley & Tukey, 1965).
Rotational invariance for a coin edge image involves cross-correlation with reference edge images. The edge image is mapped from Cartesian to polar coordinates, see Fig.4. The result of cross-correlation between the coin image to be classified and a set of reference images is used to derive class hypotheses. In detail, for both sides of a coin under investigation rotational invariant processing and hypothesis generation proceeds as follows: 1. Estimation of coin diameter from coin detection.
2. Selection of a set of reference images depending on thickness and diameter measure (if available). Each reference image is associated with a coin class.
3. Cross-correlation of the coin side edge image under investigation with all reference coin edge images in the selected reference set, resulting in a cross-correlation value and associated rotation angle estimation for each reference class.
4. Ranking of the reference set by the maximum correlation value and generation of a set of hypotheses for the highest-ranking classes.

Fig. 4. Processing for rotational invariance
To obtain reliable estimates for cross-correlation and rotation angle the polar image is split into n bands along the radius coordinate, corresponding to concentric rings in Cartesian coordinates. The peak of the correlation value K i for band i is determined for each band and the position of the peak is taken as an estimate for the rotation angle in band i.T h es a m p l e mean angle directionᾱ is estimated via (Fisher, 1995):

Will-be-set-by-IN-TECH
A cross-correlation estimate K for the coin under investigation is calculated using K = 1/n ′ ∑ n i=1 δ i K i . The number of bands n ′ ≤ n used in cross-correlation and angle estimation varies between images and is simply obtained by n ′ = ∑ n i=1 δ i .

Surface analysis from 3D data
Analysis of coin images in 2D might lead to loss of important features, e.g. highlights due to specular reflections decrease the quality of the images and handicap automatic analysis. Especially ancient coin surfaces are reliefs visualizing inscriptions and symbols. Therefore, the appearance of coins in 2D images is highly influenced by the lighting conditions. Different lighting directions make small patterns on the coin look very different and limits, for instance, the use of local image features for coin recognition. Since the surface shape of historical coins might not be as regular or flat as the shape of their present counterparts, we suggest to calculate 3D reconstructions for higher coin matching rates. With 3D scans, detailed models of both coin sides are obtained which allow a more accurate analysis (Akca et al., 2007).
However, 3D acquisitions are more laborious and expensive and, to our knowledge, 3D vision approaches applied to 3D databases of coins do not exist at the moment. By using 3D coin models, various additional features can be obtained for object matching which are not available in 2D (e.g. changes on the coin's surface, thickness and volume measurements). The profile of an exemplary ancient coin is shown in Fig. 5 (a). Two coin cuts, which are obviously visible in the 3D reconstruction Figure 5 (a) can be seen in the profile plot in Fig The Breuckmann stereoSCAN 3D system (http://www.breuckmann.com/index.php?id= stereoscan) was used for coin data acqusition ). The scanner is an active stereo system consisting of a projector and two cameras serving as stereo camera pair and combines the shape from structured light and stereo vision approach (Stoykova et al., 2007). In order to evaluate the accuracy of the coin models acquired by the Breuckmann stereoSCAN 3D, real world coin data is compared to data gathered from their virtual 3D model counterparts. A black and white stripe pattern is projected on the coin's surface. The stripes get deformed by the coin's shape and its surface structure. By using a stereo camera pair, 3D information can be obtained from two 2D images showing the same object at exactly the same time from different views. In active stereo vision, a light source projects artificial features. This features are easy to extract as their properties are known and they can be matched unambiguously. In the setup used for coin acquisition, the scanner provides a theoretical x-y resolution of 20 µm and a theoretical z-resolution limit of 1 µm.
The goal of stereo vision is to obtain depth information from 2D input data. Since the two cameras have a fixed relative orientation, the distance between them is not variable and the position of any point in 3D space can be obtained by triangulation. Therefore, the intersection between two lines of two images, where each line is passing through the projection of the point and the projection center, has to be determined. The setup can be described using epipolar geometry, which is the geometry between two views (Hartley & Zisserman, 2003). As an initial step, corresponding points must be found, which is performed using the projected and deformed stripe pattern on the object's surface. We fixed the coins on a rotation / tilt table in front of the active stereo system and the object was scanned from eight different but known viewing positions. For aligning the data from different viewpoints, the Iterative Closest Point (ICP) algorithm, which was presented by Besl & McKay (1992) and Chen & Medioni (1992), is used. Since the position of the rotation/tilt table is known, a preliminary alignment process can be performed first. All eight scans are finally aligned and merged into a polygon mesh.

Extraction of coin shape features
As the appearance of an ancient coin is often unique, e.g. due to variations in the hammering process, die, mint signs, shape, scratches, wearing, etc. its image contains important information for identification. The uniqueness in the appearance of coins results from variations in the coin blank material and application of the tools in minting, as well as from wear of the coin. Therefore, for numismatists the shape of the coin edge is regarded to be an important feature to characterize a coin.
Our approach of shape comparison is based on a description of the difference between the shape of a coin and the shape of a circle. Therefore, the suggested approach is called deviation from circular shape matching (DCSM). In order to represent the coin shape, a border tracing on the binary image resulting from segmentation is performed. A list of border pixels is obtained and resampled to l samples using equidistantly spaced intervals with respect to the arc length. A one-dimensional descriptor, i.e. a curve describing the border, is obtained from fitting the coin edge to a circle and unrolling the polar distances between sample points and fitted circle into a vector. The center s c =( x c , y c ) of the fitted circle is derived from the center of gravity and the radius r is the mean distance between the center and all sample points s i =( x i , y i ) using where (x i , y i ) are the coordinates of sample point s i and · denotes the L 2 -norm. The 1D representation is given by D =(d 1 ,...,d l ),where The division by r makes the representation invariant with respect to scale. Figure 6 (e) shows the obtained 1D representation.

Matching for classification and identification
Matching for classification or identification is based on edge based features extracted as described in the previous section. In this section, we will discuss direct matching of edge features, Eigenspace matching and shape matching.

Direct matching of edges
In the direct matching approach for edge points we start with a binary edge image E derived from a coin image.
be the list of cartesian edge point coordinates with the center of gravity (x m , y m ) as origin. The polar coordinate representation of E c is given by Assume E m is a reference image, or so called master edge image, and E a is an edge image to be matched. Then in general there is an unknown rotation φ around the center of gravity that aligns both edge images. In polar coordinates this rotation transforms into a cyclic translation in the angular direction. To determine φ we may deploy a fast correlation method based on the edge images, see Subsec 3.2 Although correlation methods based on the fast Fourier transformation perform efficiently, there are some drawbacks using the edge images directly. First, to preserve the visual information the resolution of the edge image cannot be too small. Depending on the diameter of the coin we typically get coin image resolutions from 100 × 100 to 300 × 300 pixels and the correlation would add significantly to the overall computational costs. Secondly, the outer border, which in most cases contains a substantial part of the edge points, usually does not help to find φ as it comprises too many symmetries. To avoid both we suggest to calculate the correlation on a two dimensional edge density function restricted to the inner part of the coin. This is given by The sets {θ 0 ,...,θ n } and {ρ 0 ,...,ρ l } are the discrete resolutions in angular and distance directions, respectively. Now, we may estimate φ by correlating E d m and E d a . By choosing a high resolution in the angular direction (i.e. n ≥ 512) and a coarse resolution (i.e. l ≤ 16) in the distance direction, omitting to include the coin borders, we found that φ usually may be determined up to ±0.5 • .O n c eφ is known, we may align the actual coin image to the master. This is done efficiently by only calculating the rotated coordinates for the edge points in E c a resulting in the rotated actual coin edge image E aφ . From here we compute two distance measures whereĒ d is the result of applying a morphological dilation operation to the binary edge image E in order to counteract the remaining uncertainty of the angular position. e abrasion tells us how many expected (master) edge points are missing, whereas e dirt sums the additional edge points in the actual edge image. If these errors are higher than given thresholds we have to dismiss the match. In general we cannot know which master coin corresponds to the actual coin image. Therefore, we have to calculate eqns. 7 and 8 for all master coin candidates.

Eigenimage representation and matching
The Eigenspace decomposition for image analysis was introduced by Sirovich & Kirby (1987) and found numerous applications over the last decades, most prominently in the field of face recognition (Turk & Pentland, 1991). We start with the description of the mathematical 137 Automatic Coin Classification and Identification www.intechopen.com procedure of eigenspace construction employing principal components analysis (PCA). Subsequently, we discuss multiple Eigenspaces in the context of coin recognition.
In the Eigenspace approach, we consider a set of M images B 1 to B M .E a c hi m a g eB i is of size N × N pixels. The images are reformed into vectors Γ 1 to Γ M , e.g. by scanning the image line by line. If all pixels of an image are used to produce a vector, each vector Γ 1 has length L = N 2 . An average vector Ψ and difference vectors ψ i are calculated by Principal axes are obtained by the Eigendecomposition of the covariance matrix C defined by The Eigenvectors are sorted in non-increasing order depending on the corresponding Eigenvalue. A small number M ′ of significant Eigenvectors is retained from the ranked Eigenvalues, a common practice which leads to the most expressive features (Turk & Pentland, 1991). A weighting factor ω k corresponding to the k-th Eigenimage for a new reformed image is obtained by projection onto the k-th Eigenspace component u k using The weights ω k are arranged in an vector Ω =( ω 1 ,...,ω ′ M ) T . For the coin recognition task, not the full images are reformed into a vector, only the interior pixels of the coin are rearranged into the vector Γ, see Fig. 7. To overcome limitations regarding illumination variation in the Eigenspace approach a number of solutions were proposed, e.g. Murase & Nayar (1994) investigate the determination of the illumination which gives best discrimination. The PCA of edge images and smoothed edge images is suggested as an illumination invariant way of Eigenspace construction by Yilmaz & Gökmen (2000), gradient images are used as input to PCA by Venkatesh et al. (2002) and Bischof et al. (2001) use a set of gradient based filter banks applied to the Eigenimage representation. Figure 8(a) shows the first 32 Eigenimages constructed from graylevel images, the top left image is the Eigenimage corresponding to the largest Eigenvalue. Histogram equalization is sometimes suggested as a way to achieve illumination invariance. Figure 8(b) shows the most expressive Eigenimages constructed from histogram equalized images. Figure 8( Yilmaz & Gökmen (2000). There Eigenhills are derived from application of the PCA to edge images which are covered by a "membrane". We used a 2D Gaussian filter kernel with a s of 1.5 to smooth the edge images which are of size 128x128 pixels. Figure 8(d) shows the most expressive Eigenimages, i.e. Eigenhills, constructed from smoothed edge images.  Eigenimages. Approximately 76% of the variance present in the original set of smoothed edge images is contained in the first 32 sorted Eigenhills. Therefore, the Eigenhills approach achieves a compact representation comparable to intensity Eigenspace, while also being illumination invariant.

Shape matching
The shape descriptions of two coins are compared by a linear combination of global and local shape matching. The local matching is derived from the difference of Fourier shape descriptors, whereas the correlation coefficient between the curves serves as global measure of shape similarity. The mean absolute or squared distance between the magnitude values of the Fourier coefficients is used as local measure of dissimilarity, i.e.
where · p , p ∈{1, 2} is the L p norm. The lower v ≥ 1 and upper offsets u ≥ 0 for the Fourier descriptors are small constants and used to limit errors stemming from imprecise circle fitting and quantization noise.
The global shape matching is obtained from a measure of dissimilarity or similarity, e.g. from the mean squared error (MSE) or the normalized cross correlation (NCC) coefficient ncc(u) for ashiftofu samples

www.intechopen.com
where i + u might exceed l and modulo addition is applied. The maximum D G =( 1 − max i=1...,l ncc(i))/2 is used as a measure of global shape match. Similarly, the MSE is given by In the case of MSE, the maximum D G = max i=1...,l mse(i) is used as a measure of global dissimilarity. The position of the minimum of D G is related to the rotation angle between the compared coins. While the MSE requires l shifts of the signal and l evaluations of eqn. 14, the NCC is efficiently computed in a more efficient way (Lewis, 1995).
The overall measure of shape dissimilarity becomes where the weighting factor α ∈ [0, 1] controls the influence of local and global dissimilarity terms.
In order to be invariant with respect to mirroring, the D G is replaced by the minimum of global dissimilarity obtained from matching the signal and the reversed signal. Mirror invariance enables the matching of coins irrespective of which side is shown on the image.

Classification and information fusion
A framework for classification and identification based on preselection, classification and Bayesian fusion is presented. For modern coins preselection based on correlation, classification based on Eigenspace representation and prior information, and fusion of obverse and reverse class probabilites is discussed. For identification of ancient coins preselection on shape features and classification based on fusion of shape and a local features based representations is demonstrated.

Classification and information fusion of modern coins
In the Eigenspace approach, we consider a collection of reference coefficient vectors Ω r = (ω r1 ,...,ω rD ) T , r = 1,...,R and an observed coefficient vector Ω s =( ω s 1 ,...,ω s D ) T , corresponding to the coin side to be classified. Classification starts from two observation vectors together with a set of hypotheses, ranked by their corresponding correlation measure. We introduce the following notation with typical values of parameters given in brackets: The selection of the parameter R is motivated by the balance between representing occurring variation within a coin and efficient construction of the Eigenspace. The Eigenproblem for general R × R matrices require on the order of R 3 arithmetic operations (Pan & Chen, 1999), accordingly a small R is preferred. The number of coin sides S is obviously equal to 2. The maximum number of classes per Eigenspace is determined by preselection of classes, usually based on measurements of diameter and thickness, if available. This means multiple Eigenspaces, each of which holding a limited number of classes to discriminate, are build and selected from geometric measurements (Huber et al., 2005). The number of hypotheses H generated from ranking of correlation values was limited to 5. This decision is motivated by observing the necessary number of hypotheses to ensure that the valid decision is included in the considered set of hypotheses. From a validated set of coins, it was observed, that the correct coin class is contained in 92. 62, 95.15, 96.91, 98.04 or 98.88% of all cases when retaining the first 1,2,3,4 or 5 hypotheses, respectively. This means, a classification scheme considering the highest ranking result only would not do better than 92.62%. On the other hand, considering 5 hypotheses limits a classification and fusion system to 98.88%, which is a reasonable limit for practical application.

Classification of modern coins
The distance to the r-th coefficient vector on side s is calculated by the Euclidean distance where the summation term in the denominator accounts for normalization.

Information fusion of modern coins
A-priori probabilities P s (G s h ) are either set to equal probability, e.g. P 1 (G 1 h )=1/H for side 1a n dP 1 (G 1 h )=1/H for side 2, respectively. If the coins are imaged in way that there is no rotation between obverse and reverse images, one can make use of this knowledge as modern coins are characterized by either 0 or 180 degrees of rotation between sides. In this case, the P s (G s h ) are derived from the difference in rotation angle α h for side 1 (e.g. obverse) and angle 142 Advances in Object Recognition Systems www.intechopen.com α j for side 2 (e.g. reverse) using The weights a and b account for the fact that a number of coins exist which appear similar under rotation. The constant term is chosen relatively small, in our study a = 0.08 turned out to be a good choice.
The prior probability P 2 (G 1 h , G 2 j ) is assumed normally distributed around zero angle difference for coins with same orientation on front and back side and around 180 degree angle difference for coins turned upside down between sides.
The fusion of probabilities estimated of both coin sides and prior information uses the Bayes formula We concentrate on the nominator since the denominator is a constant term. Combination of both sides is done by the product rule (Kittler et al., 1998) where probabilities are only derived for hypotheses present for both sides. The product rule of combination is equivalent to naive Bayes fusion of classifiers. Naive Bayes fusion of classifiers in turn coincides with Bayes classification over composite descriptors if the individual features are conditionally independent (Shi & Manduchi, 2003).

Classification and information fusion of ancient coins
Apart from shape features, descriptors based on local features were used for classification and identification of ancient coins in related papers (Huber-Mörk et al., 2008;Kampel et al., 2009;Zaharieva et al., 2007). Local features based on SIFT (Lowe, 2004) were used in preselection for shape feature matching. Probabilities are derived from ranked results from shape matching and fused with results from local features based matching. Fusion of ancient coins is performed similar to modern coins. In cases were images of both coin sides are available, fusion of coin side results is also possible.

Classification of ancient coins
Local features based approaches and shape descriptors deliver distance measures between the coin in question and all other images in the database. In this case, a two-stage rank based strategy is possible, i.e. a small subset is preselected based on shape comparison and further processed using local features based matching (Huber-Mörk et al., 2008). Here, we follow a strategy combining probabilities which are derived from distance measures through a rule of combination (Huber-Mörk et al., 2010), e.g. the product rule Kittler et al. (1998). Conditional independence between shape and local features, as well as between coin sides, can be assumed.

www.intechopen.com
From ranking the shape dissimilarity D AB for shapes given in eqn. 15 for shape B matched to shape A results in a preselection set P. From an observed shape description A we derive a conditional probability for a coin side label L assigned to B. The conditional probability for a P shape (L|A) is estimated to be inversely proportional to the dissimilarity given in eqn. 15 between coin A and coin B labelled L: where the summation term in the denominator accounts for normalization.
A similar argument is applied to derive a conditional probability for observed local descriptors X matched to local descriptors Y labeled L and corresponding to an image contained in the preselection set P: where M XY denotes the number of matches between the query image with local descriptors X and the coin side image with local descriptors Y and the denominator accounts for normalization.

Information fusion of ancient coins
As local and shape features describe different properties of a coin, it is reasonable to assume statistical independence between shape and local feature measurements. Thus, the combination is performed by the product rule Kittler et al. (1998): = P shape (L|A) · P local (L|X) where L shape and L local are labels derived from shape and local descriptions.
The idea of fusion of different descriptor outputs is extended to a fusion of more than one image of a coin. Typically, a coin is presented by images of the obverse and reverse side. Fusion of coin sides is obtained in a straightforward fashion. Eqn. 24 is extended to the following four terms where A i and X i corresponds to shape and local feature descriptions of the i−th coin side.

Results
In this section we summarize results for classification of modern coins and identification of ancient coins.

Results for modern coins
Image data of modern coins was acquired trough a coin collection which took place in the course of the implementation of the Euro currency in twelve European countries at the turn of the year 2001 to 2002. During this campaign 300 tons of coins coming from virtually all countries of the world but predominately from the twelve Euro member states have been collected by the Dagobert coin sorting system. Results are presented for two samples of 11 949 coins and 12 949 coins, respectively, taken randomly from the collected money. Those coins have been manually labeled into valid and invalid coins. Valid coins are coins from 30 countries including most European countries, the USA, Canada and Japan. The portion of valid coins in the sample was 91.6% or 94.15%, depending on the considered set. The remaining 8.4% or 5.85%, respectively, are dominated by coins from Asia, South-America, Africa and former socialist countries. Figure 1 (b) shows examples for these coin images.

Direct edge matching based approach
Apart from image sensors for obverse and reverse coin sides sensors for thickness and area measurements are present in the Dagobert system. Based on their measurements a first rough pre-selection of potential master coins is determined, in our case a set of 6 coins are preselected. This provides us with a set of master coins that have almost the same diameter and that have to be distinguished. A total number of 12949 coin images were validated manually as well as tested against 913 master coin patterns of all diameters in the recognition pattern set. Table1 shows the results. The set of incorrectly sorted coins is quite small.  Table 1. Classification results for modern coins using edge based matching The Dagobert system was used to sort several tons of coins and is able to meet the real-time conditions, i.e. to process 5 to 6 coins per second. Using the obverse and reverse face for the recognition task, approximately 85% of the material is either sorted into classes defined in the recognition pattern set, i.e. the set of valid coins, which contained around 1500 patterns of coin faces, or is correctly rejected. Random tests performed on classified sets of coins indicate that we seem to meet the goal of having less than 0.1% false classifications.

Edge Eigenspace based matching
We discuss results including rejection based on the a-posteriori probability P(G k |Ω).Ac o i n pattern Ω is accepted to be of class G k if P(G k |Ω) ≥ t, and rejected if P(G k |Ω) < t ,w h e r e t ∈ [0, 1] is the rejection threshold. The parameter t is used to tune the system towards the desired trade-off between false rejection and false acceptance. The trade-off between false acceptance rate (FAR) and false rejection rate (FRR) is an important performance measure in verification and recognition systems. False acceptance of invalid coins is measured by the   Fig. 10 (b), the tradeoff between FCR plus FAR and FRR can be identified. An operating point, corresponding to a specific t, is found on the ROC curve, e.g. for perfect classification with FAR + FCR ≈ 0, a very high FRR has to be taken into account (i.e. FRR > 0.5). If the 146 Advances in Object Recognition Systems www.intechopen.com incorrect decisions FCR, FRR and FAR are equally weighted and we aim at minimization of the sum of false decisions FD=FCR+FAR+FAR. We find the optimum value for the rejection threshold t as the minimum of FD. This can be seen from Fig. 10 (c), in which the minimum of FD is found for t = 0.006. At the same time correct decisions, i.e. correct classification and correct rejection rates, are maximized.
Considering only valid coins, i.e. the 91.6% coins included in the 30 countries mentioned above, and using no rejection mechanism, correct classification was made for 98.27% of valid coins, which is close to the practical optimum of 98.88% mentioned in Section 5.1 With rejection at the chosen level of t=0.006, a percentage of correct classification of 94.54%, 0.53% false classification and 4.93% false rejection is achieved for valid coins. Considering only invalid coins, i.e. the 8.4% coins not included in the 30 countries mentioned above, and rejection at the chosen level of t=0.006 classification into any of the known coin classes happens for 20.47% of the unknown coins. Correct rejection of unknown coins is performed for 79.53% of invalid coins. Examining at the mixed sample, a correct decision, i.e. correct classification or rejection, was made for 93.23% of all coins. False decisions, i.e. either false classification, false rejection or false acceptance, took place for 6.77% of all coins.  Table 2. Classification results for modern coins using edge Eigenspace based matching.

Results for ancient coins
To evaluate our approach on coin data, we use an image database provided by the Fitzwilliam Museum, Cambridge, UK, which consists of 2400 images of 240 different ancient coins of the same class. Figure 1 (b) shows four of the coins contained in the data set. Each row shows the same coin acquired by different devices at varying conditions and different orientations. In particular, each coin side was acquired at three different angles of rotation using a scanner device and two acquisitions were made using a digital camera and varying illumination. At first sight, all coins bear the same characteristics. However, the coins shown in the different rows are produced by different dies. What makes this data set special and ideal to thoroughly test identification methods, is that all the coins are very similar. All the images are issued in the time of, or at least in the name of, Alexander the Great who came to power in Macedonia in 336 BCE and died as emperor in 323 BCE. Some of the coins are from much later and were minted in places around the Black Sea, in Egypt, in modern-day Turkey, Iran, etc. All coins follow the same basic standard: on the obverse side there is the head of Heracles in a lion-skin. The reverse side shows the god Zeus, seated left on a throne. Nevertheless, there is a huge range of detail in the minor variations that experts use to deduce the mint and date of the coin.

147
Automatic Coin Classification and Identification www.intechopen.com

2D matching
It takes 0.006 seconds to compare two coins based on their shape description on a Intel Core 2 CPU with 2.5 GHz. Therefore, shape matching is suited as a preselection step to the less efficient matching based on local features which typically takes two orders of magnitude longer (Bay et al., 2006). The size of the preselection set is determined experimentally from Precision-Recall curves. Recall measures the ratio given by true positives divided by the sum of true positives and false negatives, i.e. rec = TP/(TP + FN) and precision is given by prec = TP/(TP + FP),w h er eFP is the number of false positives. Figure 11 (a) shows plots of precision versus recall for the test set of 240 different images containing 10 images of each coin. Different settings of the shape matching weight parameter α show that a relatively large value of α, which directs the matching dissimilarity towards more local influence, performs best. In order to obtain a preselection set of moderate size and high quality, i.e. the coin in question should likely be contained, a high recall is aspired. This is obtained by selecting the set size corresponding to the sudden decrease in Fig. 11 (a). Figure 11 (b) shows that this sudden decrease in precision versus recall corresponds to a preselection set size of 9 to 10 images. We combine shape and local descriptors to increase the identification rate. Preselection based on shape matching allows for the restriction of required comparisons for local features matching. As a result we achieve speed up of the identification process and higher accuracy rate. Since our shape descriptor is mirroring invariant, preselection can be performed either on the whole available coin data, i.e. the preselected set can contain images of the second coin side, or preselection can be performed on the relevant coin side directly.
As a conclusion the preselection size was set to 10. Therefore, for the experiments presented here, P shape (L|A) is computed for the 10 images with lowest dissimilarity and P local (L|X) for the same 10 images. The final decision is made according to the product rule given in Equ 24.

148
Advances in Object Recognition Systems www.intechopen.com Table 3 shows the identification rates for the single descriptors and their combination with a leave-one-out evaluation scheme. The shape-based preselection of size 10 was performed accordingly to the given side of the test coin image. The DCSM alone gives an identification rate of 97.04% on the whole data set of 2400 images. For a preselection size of 10, there are only 13 cases (0.54%) where the correct coin is not contained in the preselected set. Consequently, local feature matching on the preselected set and fusion with the label probabilities from DCSM lead to an identification rate of 98.54%.

3D extensions
Usually, a reference object, e.g. a cone, a square prism or a cylinder, is scanned and measured manually when the accuracy of the scanner needs to be calculated. After gathering all the dimensions, the values can be compared to the values determined from the 3D reconstruction. Additionally, scanner resolution evaluations can be made. Due to the fact that in our case the scanned object is small and both the surface and the shape of historical coins are not regular or flat, many dimensions cannot be measured precisely (e.g. coin profile details). Since we cannot provide the same accurate values for coins as we can provide for known objects, like cones or cylinders, our results will be based on a comparison between manually measured values from ancient coins and the values determined from the 3D model counterparts. As evaluation parameters, the maximal diameter and the volume of each coin are used.
The models are analyzed using Geomagic Studio, a commercial software for 3D data processing. The volumes of the original coins are calculated manually after computing the density by using the uplift of the coin in water and by measuring the weight of the coin. The compared diameter value represents the maximal existing value on the coin's surface. The maximal diameter from a real world coin is also determined manually. From a 3D model, the volume can be calculated using Geomagic Studio. The maximum diameter can be computed by segmenting one side of the coin and taking the largest distance between two border points. Because of the irregular shape of some coins, both the obverse and the reverse side of a coin must be taken into account.
In total, we scanned 22 coins: 14 ancient coins from the Roman era and 8 tornese silver coins from medieval age. Figure 12 (a) shows the volume of both the original ancient coins using the water volume calculation and their 3D model counterparts using Geomagic Studio. The maximum difference between manual and automatic measurements is 36.24 mm 3 .T h e smallest difference between real-world data and the data gathered from 3D models is 0.57 mm 3 . Figure 12 (b) shows the maximum diameter of both the real world manually measured one and the value calculated by using 3D models in Geomagic Studio. A maximum difference of 1.12 mm is measured, two coins have exactly the same diameter measured from 3D models and from real-world data. Table 4 shows maximum difference, minimum difference, and the mean variation coefficient of all volume and diameter measurements.   Table 4. Maximum difference, minimum difference and coefficient of variation between automatic 3D measurements and manual 2D measurements of ancient coin properties.

Conclusion
We have presented methods for coin classification and identification applicable to coin collections comprising either a large number of coin classes, e.g. modern coins, or high intra-class variation, e.g. ancient coins.
Modern coins represent financial value only if the coins are sorted and returned to the respective national banks. A tunable system is required as national banks accept coins only if they are delivered with a high degree of purity. The rejection mechanism based on the probabilistic fusion result allows to adjust a tradeoff between rigorous classification (yielding high reliability against false acceptance but a higher rate of false rejections) versus tolerant classification (yielding more false acceptances but fewer false rejections). Coin class probabilities for both coin sides are combined through Bayesian fusion including a rejection mechanism. Correct decision into one of the 932 different coin classes and the rejection class, i.e. correct classification or rejection, was achieved for 93.23% of coins in a test sample 150 Advances in Object Recognition Systems www.intechopen.com containing 11 949 coins. False decisions, i.e. either false classification, false rejection or false acceptance, were obtained for 6.77% of the test coins.
In order to facilitate prevention and repression of illicit trade of stolen ancient coins technologies aimed at allowing permanent identification and traceability of coins become of interest. Since every individual coin has signs, caused by minting techniques for pre-industrial ones or by use-wear for more recent ones, that make it unique and recognizable to an expert's eye, traceability of pre-industrial coins can make use of visual inspection. We presented an approach for object identification based on the combination of shape and local descriptors and applied it to the task of ancient coins identification. Shape matching was used to match coin edges whereas the die of the coin was matched by means of local features. From the output of each of these two methods individual coin label probabilities were estimated and finally fused. On a data set of 2400 coin images the combination of shape and local features outperform the accuracy rate of the single features and achieved an identification rate of 98.83%.
The results for classification of modern coins and identification of ancient coins are regarded to be almost perfect. Due to large intra-class variance, the classification of ancient coins is still a challenging task, especially if attempted from single 2D images. Additional information, e.g. from 3D measurements, or complementary information, e.g. textual descriptions, is supposed to improve the classification task for ancient coins significantly.