Définition de graphe
Soient deux fonctions d'étiquetage L V (V) et L E (E) qui associent à chacun des éléments de V, respectivement de E, une ộtiquette Un graphe ộtiquetộ G est un 4-tuple G = (V, E, à, ξ), avec :
V est un ensemble de nœuds
E ⊆ V × V : un ensemble d’arcs à : V → L V : la fonction d’ộtiquetage de nœud ξ : E → L E : la fonction d’étiquetage d’arcs
Correspondance de Graphe
Graphs are a commonly used representation in the field of information science and technology, allowing for the description of structured data A graph G consists of a set V of nodes and a set E of edges, represented as G = (V, E) Supervised classification tools are increasingly essential in various applications, including pattern recognition and Case-Based Reasoning (CBR).
Graph matching is a critical topic in the analysis of chemical components This article highlights the extensive study of graph matching techniques that have emerged over time, emphasizing their significance in various applications.
In the context of shape recognition, the comparison procedure involves determining the similarity between two graphs: the model graph G_M and the data graph G_D Generally, the graph matching problem can be represented as follows: Given two graphs G_M = (V_M, E_M) and G_D = (V_D, E_D), with |V_M| = |V_D|, the goal is to find a matching function f: V_D → V_M such that (u, v) ∈ E_D if and only if (f(u), f(v)) ∈ E_M When such a matching function f exists, it indicates an isomorphism, meaning G_D is isomorphic to G_M, referred to as exact matching Conversely, the term "inexact" in graph matching problems signifies that an isomorphism cannot be found between the two graphs, typically due to differing numbers of vertices or edges in the model and data graphs In such cases, the best correspondence can be achieved by establishing a non-bijective match between the data graph and the model graph.
The graph matching problem has been proven to be NP-complete When the number of nodes in the two graphs differs, the challenge of graph matching becomes more complex than in the case of exact graph matching Similarly, the complexity of the inexact subgraph problem is equivalent to that of the largest common subgraph problem, which is also known to be NP-complete Various techniques have been proposed to address this issue, including probabilistic relaxation, the EM algorithm, neural networks, decision trees, and genetic algorithms.
All previously mentioned methods share a commonality in employing an optimization algorithm to transform one graph into another, utilizing a quality function to measure the similarity between the two graphs This function is designed with consideration for the cost of matching vertices from graph V_D to graph V_M The authors assert that an appropriate matching should result in an accurate distance measurement between graphs Based on this premise, the problem is reframed as a question of graph distance Furthermore, this perspective on the graph matching issue will facilitate the establishment of a testing framework for our approach and enable a comparative study.
Graphe de distance
Distance d'édition
The edit distance (ed) is a measure of dissimilarity used to compare graphs, representing the minimum cost sequence of basic operations required to transform one graph into another This transformation involves elementary operations such as insertion, deletion, and substitution of nodes or edges Under specific conditions related to the costs of these operations, the edit distance between graphs serves as a valid metric.
In practice, the cost of basic operations depends on the specific application Typically, this cost is determined either through human expertise or, more rigorously, through artificial learning methods as suggested in [17].
On the other hand, the computation of edit distance is performed using dynamic programming, which results in exponential complexity in the worst-case scenario This limitation makes it unsuitable for nearest neighbor search in large databases.
Une autre possibilité permettant d'évaluer la proximité entre objets complexes (ensembles, séquences, graphes, .) pour comparer des objets ou des graphes.
Le coefficient de correspondance mc est la mesure la plus simple répondant à cette définition et permettant de comparer des objets complexes o 1 et o 2
C'est en se basant sur ce concept que des mesures de dissimilarité exploitant le plus grand sous-graphe commun (mcs) ont été proposées :
In the previous formulas, |G| denotes the size of graph G, which can be represented as a linear combination of the number of nodes and arcs in G Additionally, mcs(G1, G2) refers to the largest common subgraph shared by graphs G1 and G2, indicating that this subgraph cannot be expanded into another common subgraph through the addition of any nodes or arcs.
La distance d'édition est liée au plus grand sous-graphe commun par la relation donnée par l'équation
The cost functions associated with edit distance adhere to the conditions outlined in [16], indicating that the methods for calculating the maximum common subgraph (MCS) of two graphs can also be utilized to determine edit distance, and vice versa, with both calculations sharing the same algorithmic complexity Due to the challenges posed by the complexity of these measures, various approximation-based approaches have been proposed in [19] Additionally, three other categories of techniques can be employed to assess graph similarity: spectral graph theory [19], probabilistic methods [20], and combinatorial optimization methods [21], [22].
Among them, a combinatorial optimization method was proposed that offers a distance metric based on arc matching This approach approximates topological preservation, induced by isomorphism, by seeking a correspondence between the arc sets of two graphs while minimizing the matching of these sets.
Kriegel and Schurnauer demonstrate that for labeled graphs, the arc matching distance adheres to the properties of non-negativity, symmetry, and the triangle inequality Recently, Riesen et al proposed an approximation method for calculating graph edit distance, where the correspondence between two graphs relies on the matching of a bipartite graph.
The cost matrix for the correspondents of different node labels serves as input for the Hungarian algorithm, which processes the association cost matrix of nodes This algorithm computes the association distance between nodes G1 and G2, representing the cost of the optimal association, with a worst-case complexity of O(n^3), where n is the maximum number of arcs.
The Hungarian method involves a series of steps to analyze the cost matrix in order to determine the optimal cost for pairing nodes We present two graphs, G1 and G2, where the distances between the nodes of G1 and G2 are illustrated in Table 1.
Table 1: Matrice des cỏts de G 1, G 2
Nœud 4 11 19 14 13 Étape 1: Réduction des lignes : créer une nouvelle matrice des cỏts en choisissant le cỏt minimal sur chaque ligne et en le soustrayant de chaque cỏt sur la ligne.
Nœud 1 Nœud 2 Nœud 3 Nœud 4 Réduit de
Step 1 involves reducing the number of rows, while Step 2 focuses on reducing the columns by creating a new cost matrix This is achieved by selecting the minimum cost from each column and subtracting it from every cost in that column.
In Step 2, the focus is on reducing the columns, while Step 3 involves determining the minimum number of rows and columns required to cover all zeros in the matrix If the calculated number matches the total number of rows or columns, the matrix is considered reduced, leading to Step 5 Conversely, if this number is less than the total rows or columns, the process continues to Step 4.
Table 4: étape 3 : déterminer le nombre minimal de lignes sur les lignes, colonnes pour couvrir tous les zéros
Dans ce cas, le nombre minimal de lignes est de 3 Donc, on va à l’étape 4. Étape 4:
- Trouver la cellule de valeur minimum non-couverte par une ligne.
- Soustraire cette valeur de toutes les cellules non-couvertes
- Ajouter cette valeur aux cellules situées à l’intersection de deux lignes
Table 5: étape 4 : Trouver la cellule de valeur minimum non-couverte par une ligne
Table 6: étape 4 : recaler la valeur pour les cellules basées sur cette valeur minimum
Soustraire toutes les cellules non-couvertes par la valeur 1, Ajouter les cellules situées à l’intersection de deux lignes par valeur 1
Table 7: étape 4 : déterminer le nombre minimal de lignes
Maintenant, le nombre minimal de lignes est de 4, Donc, on passe à l’étape 5
+1 -1 Étape 5 : Déterminer la solution optimale
Table 8: étape 5 : déterminer la solution optimale
Nœud 4, Nœud 1 ne pourrait pas ờtre choisi car l’affectation de ôOằ ne serait pas de cỏt minimal
Table 9: le cỏt minimal de G 1, G 2
Donc le cỏt de la meilleure association des nœuds de G 1 et G 2 est 48
Distance entre signatures de graphe ôgraph probing ằ
A faster technique for assessing graph similarity involves extracting a feature vector representation known as a graph signature This method, introduced by [25], efficiently handles graphs with hundreds of thousands of nodes and edges in linear time It enables the description of both labeled and directed graphs.
In a directed, labeled graph G, where the arc labels belong to a finite set of size a, the arc structure of a given node is represented by a 2a-tuple of non-negative integers {x1, , xa, y1, , ya} Here, xi denotes the number of incoming arcs labeled li, while yj indicates the number of outgoing arcs labeled lj Within this framework, two types of signatures are established.
- Probe1(G) : un vecteur dont qui rassemble les nombres de sommets partageant la même structure d’arcs, pour toutes les structures d'arcs rencontrées dans le graphe
- Probe2(G) : un vecteur dont chaque composante est associé à une étiquette d'arc qui représentant le nombre d'arcs ayant à une étiquette li
Figure 1 illustrates the distance between graph signatures GP for various types of graphs: (a) undirected graphs without labeling, (b) directed graphs without labeling, and (c) labeled directed graphs Utilizing these signatures and based on the L1 norm, the distance between graph signatures ô GP ằ (between two graphs G1 and G2) is defined.
GP (G 1 ,G 2 ) = L1(Probe1(G 1 ), Probe1(G 2 )) +L1(Probe2(G 1 ), Probe2(G 2 ))
The distance between graph signatures adheres to non-negativity, symmetry, and the triangle inequality, but it does not guarantee uniqueness In other words, the graph signature distance is a pseudo-metric, meaning that two non-isomorphic graphs can possess identical signatures.
Lopresti and Wilfong present an intriguing relationship between edit distance and graph signature distance Specifically, they demonstrate that, within a factor of 4, the distance between graph signatures serves as a lower bound for the edit distance, regardless of the graphs being compared.
Figure 2: La distance entre deux graphes selon ED et GP, (a) les graphes non orienté, sans étiquetage, (b) les graphes orientés, sans étiquetage, (c) les graphes étiquetés, orientés
In this context, the graph topology can be partially overlooked by counting the occurrences of a set of subgraphs, known as fingerprints or signatures in different contexts, for each graph This allows for the comparison of objects to be described as vectors.
Building on the original concept presented in sources [22] and [24], the authors have expanded the model of the minimum cost correspondence between two sets of elements to include subgraphs, which are more complex and discriminative objects.
Symbol spotting
Symbol spotting is defined as the identification of regions of interest within an image document that may contain a specific symbol, without explicitly recognizing it This process, known as contextual symbol localization, contrasts with the recognition of pre-segmented symbols The challenge of symbol recognition remains a prominent topic within the scientific community Various approaches have been proposed for symbol recognition, particularly those based on shape descriptors, which are calculated on the object's contour or its entirety While these methods are robust against noise and occlusions, they require clear segmentation of the document, a significant challenge since symbols are often integrated with other graphic layers.
Alternative approaches utilize graph structures for symbol representation, effectively capturing the topology of symbols Typically, a symbol is decomposed into a set of segments or connected components, with their spatial relationships represented through a relational graph Consequently, the Symbol Spotting problem transforms into a Graph Matching challenge, which relies on the method of graph construction.
We propose a structural method for symbol representation, where each node signifies a connected component automatically labeled by a clustering algorithm applied to a shape descriptor dataset The arcs illustrate the spatial relationships between connected components, utilizing two types of arc labeling: bidimensional Allen relations and distances between two regions.
Les méthodes de construction de graphe
Numerous graphic recognition methods have been developed for symbol recognition, categorized into several families: 2D Hidden Markov Models (HMM), Pixel Features, Graph-based approaches, Structural Signatures, and Hierarchical Symbol Representations This section focuses on graph-based methods for graphic symbol recognition.
In 1996, B T Messmer and H Bunke introduced a method for representing symbols and drawings using attributed relational graphs In this approach, nodes represent segmented lines labeled by their lengths, while arcs connecting the nodes indicate adjacency relationships between the segments Each arc is labeled with the angle between two segments.
Figure 3 : Graphiques attribués relationnelle, chaque nœud est comme une ligne segmentée, un arcs établis la relation d’adjection entre deux segmentations (source[14])
Josep Liadós et al present a method utilizing Region Adjacency Graphs (RAG) that employs high-level primitives extracted from a segmentation process A closed region is identified using a prototype symbol, which serves as a node in the graph Edges connect adjacent regions, with nodes labeled using shape descriptors applied to the region's boundary (chain code) Additionally, edges are labeled with a common chain between adjacent regions, incorporating information about the region's length and orientation into the graph.
Figure 4: Chaque nœud est une région fermée L’arc lie deux régions adjacentes (source[32])
In the article [33], the authors introduced a novel method for graph creation, where each node represents a connected component They extract rotation and translation invariant features based on Zernike moments [43] from each connected component Nodes are automatically labeled using the k-medoids clustering algorithm [44], based on the extracted features To construct edges, they utilize a neighborhood graph family based on a distance threshold, meaning that each pair of points (centers of the bounding boxes of connected components) is connected by an edge in the associated graph if they are within a specified distance threshold t.
According to Rashid Jalal Qureshi and colleagues, a combined approach is proposed that integrates a structural method with one that captures the topological relationships among primitive graphs Following the preprocessing stage, a quadrilateral vectorization is achieved, representing lines within a drawing.
Figure 6: vectorisation de quadrilatères, source [45]
Each node in the graph represents a quadrilateral, which has specific characteristics such as the length (l) of the median axis, the angles of two vectors (v1, v2), the width of each side (w1, w2), and an area of influence Additionally, all arcs are associated with a label that signifies the type of topological relationship (L-junction, S-junction, T-junction, X-intersection, or P-parallelism) between neighboring quadrilaterals.
Figure 7: La zone influence de quadrilatère et le graphe correspondant, source [45]
Et voici un exemple de construction d’un graphe à base cette approche
Figure 8: exemple de construction d’un graphe basé sur les relations topologique, source [35]
Les methodes de mise en correspondances des graphes
Cette approche permet de trouver un isomorphisme de sous-graphe à partir d'un symbole pour un dessin sur une représentation compacte de la base de données du symbole.
The main idea of this approach is to identify common substructures among symbols and represent them in terms of these substructures This involves breaking down the symbol into its components, with the smallest component being a simple line For each component, isomorphisms of subgraphs are identified between the component and the drawing The outcome of this process is a set of isomorphic subgraphs, where the editing cost is below a specified threshold value, t.
La fonction de cỏt pour des opérations d’édition est définie comme suit :
- Le cỏt de substitution d’un angle α 1 à un angle α 2 est (α 1 – α 2 ) 2
- Le cỏt d’insertion d’un arc avec un angle α 1 entre deux lignes avec la distance d et angle α 2 est (α 1 – α 2 ) 2 ∗ d
- Le cỏt d’insertion d’un nœud dans le graphe de dessin est comme un variable constante de 3
- Le cỏt de fusion de deux nœuds qui représente deux lignes segmentées en un seul nœud (qui représente une segment de droite) est comme une variable constante de zéro.
This approach identifies error-tolerant isomorphic subgraphs between the model graph and the input graph The isomorphism is determined based on the minimum cost of the edit sequence needed to transform one RAG into another, by defining three cost functions.
The substitution cost involves replacing a node \( r_M \) (model region) with a node \( r_I \) (input region), denoted as \( r_M \rightarrow r_I \) This operation's cost is determined by the modification of the distance between two chains.
Le cỏt de changement de structure (Shift cost) : pour mesurer la préservation de la structure d’inter région.
Le cỏt d’échelle (scaling) : pour préserver le facteur d'échelle lorsque d’une nouvelle région est intégrée dans la mise en correspondance.
This approach offers the advantage of matching degraded graphs in a computation time that is nearly polynomial, even though its theoretical complexity remains exponential Solutions can be found in just a few seconds for graphical models with fewer than 10 regions, as well as for graphs containing several hundred regions.
The primary concept of this method is to identify sections of a graph that may correspond to symbols without prior knowledge of the document type These nodes and arcs form what are known as "symbol seeds." Subsequently, these seeds will be analyzed and clustered to create subgraphs that potentially represent symbols within the image document.
Pour comparer deux graphes étiquetés avec des attributs numériques sur les nœuds et des arcs, ils proposent de calculer le score de similarité entre deux graphes (Mp) :
In a graph G, let m represent the total number of corresponding nodes and n the total number of arcs between them The weights associated with the split division of the i-th and j-th nodes in graphs G and G' are denoted as ω i and ω' j, respectively Additionally, ΔV i and ΔE j indicate the normalized distance between two mapped nodes and arcs, scaled between 0 and 1.
The article presents seven hypotheses for constructing a graphical symbol recognition system: symbols consist of small segments; the segments forming a symbol have comparable lengths; two successive segments with a relative angle far from 90° are more likely to be part of a symbol; symbols often comprise parallel segments; a symbol is rarely connected to more than three other segments; and the shortest loops often correspond to symbols This system is effective primarily with graphic documents such as electronic circuits, logic diagrams, and architectural maps However, documents containing symbols that do not adhere to these hypotheses cannot be analyzed using the proposed system.
This approach employs the FSG algorithm to identify frequent subgraphs, which are then utilized to create a document image representation based on a bag-of-symbols model.
A distance metric is established to compare the representations of two document images, A and B, represented as A = (a1, a2, , at) and B = (b1, b2, , bt), where t denotes the total number of symbols in the lexicon formed during the frequent subgraph search phase The measure d(A, B) is defined accordingly.
Cosine similarity measures the similarity between two representations based on the cosine of the angle between their vectors When the vectors of representations A and B are oriented in the same direction, indicating proportional weights for each symbol, the similarity score d(A, B) equals 1 Conversely, a score of d(A, B) equal to 0 indicates that the two documents share no common symbols, as their weights are either positive or zero.
Ses travaux proposent une nouvelle approche pour la classification et l'indexation d'images de document Cette approche utilise des techniques de fouille de données pour l'extraction de connaissances.
The results are quite promising and demonstrate that the approach enables image indexing based on the symbols present, even when these symbols are linked to other elements.
Our approach introduces a novel method for constructing graphs based on k-nearest neighbors Each node is treated as a connected component, from which we extract features using Hu moments and Shape Statistics Nodes are automatically labeled through the k-Means clustering algorithm based on these features Edges are labeled automatically using bidimensional Allen relations or the distance between regions The symbol recognition problem is transformed into a subgraph isomorphism question to identify subgraphs that correspond to graphical symbols We extract the planar graph into subgraphs of length l.
Our application produces a set of isomorphic subgraphs based on the distance between the subgraphs and the query symbol graph, provided the distance is below a specified threshold We introduce a graph matching method that utilizes the assignment of subgraphs of length l to compute the distance between two graphs, as detailed in the following section.
The advantage of our approach lies in the use of Hu moments and statistical shapes, which ensure that two connected components (nodes) within the plane and symbol share the same morphology, necessitating consistent labeling.
De plus, l’étiquetage des arcs basé sur les relations d'Allen bi-dimensionnelles adaptées pour maintenir une invariance de la représentation aux transformations d'image.
Récaputulation des méthodes
Nœud Arc Distance Application specifique Complexité
- relation d'adjacence entre les segmentations
- cỏt d’édition : substitution, insertion, fusion le dessin Sous-linéaire
- chaợne de la frontière de région
- lié entre deux régions adjacentes
- chaợne commun entre deux régions adjacentes trois fonctions de cỏt : Substitution, Shift cost, le cỏt d’échelle dessinés à la main Exponentielle
- sans étiquetage score de similarité entre deux graphes circuits électroniques, la logique des diagrammes et des cartes d'architecture
- relation topologique (L- jonction, S- jonction, jonction en T, X- intersection ou P- parallélisme) mesure de similarité basée sur le cosinus des deux représentations
Electronique, schémas d'architecture, cartes d'ingénierie
- Voisinage basé sur k plus proches voisins
- les relations d'Allen bidimensionnelles ou la distance entre des régions méthode de mise en correspondance de graphes fondée sur l’assignement de sous- graphes basée sur la
- n 1 est le nombre de composantes connexes
- n 2 est le nombre de nœuds des sous-graphes d’ộdition ằ PMD ED et basée sur le ô Graphe Probing ằ PMD GP
In conclusion, we have presented examples of graph families that are context-dependent, with each representation tailored to a specific application, making it impossible to create a general application Additionally, the method of establishing spatial relationships among components varies; for instance, in references [31][35], arcs between nodes indicate topological relationships among graphical primitives, while reference [34] relies on a distance threshold Our approach, on the other hand, is based on a neighborhood of k nearest neighbors In the following section, we will address the problem of graph matching based on the assignment of subgraphs.
4 Une méthode de mise en correspondance de graphes fondée sur l’assignement de sous-graphes
Définition : Décomposition en sous-graphes
Figure 9: La décomposition en sous-graphes p1, p2, p3, p4 est des sous-graphes d’extractions de longueur 1 qui associés à chaque nœuds du graphe G
Let G be a labeled graph with edge labels from the finite set {l1, l2, , la} P represents a collection of extraction subgraphs of length l, associated with each node in graph G A subgraph p is defined as a pair , where Hi consists of the edges and their corresponding terminal vertices originating from a root vertex.
In this context, a subgraph represents local information structured around a root node The alignment of these subgraphs should facilitate graph matching Subgraph extraction is achieved through graph analysis, which can be performed in linear time using an adjacency matrix The decomposition subgraph is illustrated in Figure 9.
La correspondance de sous-graphes
Let G1 (V1, E1) and G2 (V2, E2) be two attributed graphs Without loss of generality, we assume that |P1| ≥ |P2|, where P1 and P2 are sets of subgraphs of length l associated with each node in graphs G1 and G2, respectively The complete bipartite graph is considered in this context.
In graph theory, the graph G em is defined as G em (V em = P 1 ∪ P 2 ∪ ∆, P 1 × (P2 ∪ ∆)), where ∆ represents an empty subgraph value The subgraph matching between G 1 and G 2 is characterized by the maximum correspondence of G em The distance between G 1 and G 2, denoted as PMD (G 1 , G 2), represents the minimum cost required to match the subgraphs of G 1 and G 2 according to the cost function c This optimal assignment results in a unique vertex correspondence between G 1 and G 2, ensuring that the PMD function minimizes the matching cost of the subgraphs However, the approximation relies on the fact that the matched subgraphs only consider local information, limited to the neighborhoods of the nodes Node matching is constrained by the assumption of close neighborhood imposed by the concept of subgraphs An illustrative example of graph correspondence is presented in Figure 10.
Figure 10: à partir deux graphes G 1 , G 2 (a), on extrait des sous-graphes de longueur 1 (a), (b) Le graphe bipartite complet G em obtenu par P 1 et P 2
Le cỏt de fonction (c) pour la correspondance des signatures
Let p1 and p2 be two subgraphs; the cost function can be expressed as the sum of modification operations required to transform p1 into p2 In the specific context of length-1 subgraphs, the edit distance is applied to trees containing symbols Consequently, the set of editing paths for transforming p1 into p2 is relatively limited While the graph edit distance is known to be NP-complete, its application to length-1 subgraphs can be executed in linear time relative to the cardinality |p| The edit distance serves as a metric, and the cost function c is defined as the sum of the edit operations necessary to convert p1 into p2.
Avec γ ( p 1 , p 2 ) désignant l'ensemble des chemins d’édition pour transformer p 1 en p 2 , et edit désigne la fonction de cỏt associée aux opérations de modification (e i ).
Sous graphe de longueur ι
Soit n1 est un nœud du graphe G = (V, E),
Le sous graphe G’(V’, E’) de longueur ι est obtenu à partir du nœud n1 par opération d’extraction soit : n1 ∈ E
V’ = {v | DEPTH (v, n1) < ι } avec DEPTH est la profondeur de v et n1 E’ = {(v1, v2) | v1, v2 ∈ V’ v1, v2 ∈ V,
(*)(**) pour éviter le cas (v1, v2) est un arc de G, et DEPTH (v1, n1) = ι , DEPTH (v2, n1) = ι
Le sous graphe obtenu par l’opération d’extraction de nœud 1 qui ne contient l’arc (2, 3) malgré DEPTH(1, 2) = 1 et DEPTH(1, 3) = 1.
Voici c’est le pseudo codage pour extraire les sous graphe de longueur ι
Algorithm – Extraction Input : Graph representation of a graphic document (G), extract length ι
Output: a List of sub-graphs (SG) for all nodes of G(n1) begin new G’(V’, E’) V’ = {n1}
E’ = {φ} for i = 1 ι for all nodes of G’ (n2) begin
{n3} all nodes adjacent from node n2 E’ = E’ ∪ {(n2, n3)}
Figure 11: (a) un graph G(V, E), à partir du nœud 1, on extrait les sous graphes avec (b)longueur=1,
The length value is automatically determined from the query graph As shown in Figure 11, the minimum length is 2, indicating that the subgraph G’ obtained through the extraction operation of length ι is also part of the supergraph G To achieve this, the graph G is extracted at lengths ι = 1 |V|, resulting in a set of subgraphs G’ 1,i, G’ 2,i, …, G’ |V|,i, where i ranges from 1 to |V|.
Construction de matrice de cỏts
In [24], the cost matrix is established by enumerating the costs of all possible editing operations between the nodes of graphs G1 and G2 Let G1 = (V1, E1, a1, ξ1) represent the source graph and G2 = (V2, E2, a2, ξ2) denote the target graph, where V1 = (u1, , un) and V2 = (v1, , vm) The cost matrix C is defined as follows:
Matrice 1 : La matrice de cỏt C
In this context, c_i,j represents the cost of substituting a node, c_i,ε indicates the cost of deleting a node (u_i → ε), and c_ε,j denotes the cost of inserting a node (ε → v_j) Additionally, it is essential to consider the arcs associated with the nodes, necessitating an extension of the cost matrix For each entity c_i,j, which corresponds to the substitution of a node, the substitution cost of a node (u_i → v_j) is augmented by the minimum costs of editing operations on the arcs The entity c_i,ε reflects the cost of node deletion, including the costs for removing all adjacent arcs of u_i, while the entity c_ε,j represents the cost of node insertion, incorporating the costs for inserting all adjacent arcs of v_j This definition is contingent upon the chosen method.
"distance d’édition", car l'idée était de proposer une approximation de la distance d’édition
Au contraire, dans notre approche, la matrice de cỏt C’ est une matrice de taille m×n.
Matrice 2: La matrice de cỏt C'
In this article, we define the cost between two signatures, allowing us to create a smaller cost matrix compared to the one established in matrix 1 Since the signature is defined as a subgraph of length "1," any distance between trees or graphs can serve as a similarity measure to construct the cost matrix Our method is not limited to edit distance; any graph distance can be utilized for graph matching Previous work has proposed an approximation of edit distance, while we also evaluate a subgraph distance based on Graph Probing We denote PMD ED for subgraph matching based on edit distance and PMD GP for that based on Graph Probing When referring to PMD without specification, it will pertain to the cost function in use.
This article presents an example of subgraph matching by representing the cost matrix Consider two graphs, G1 with vertices V1 = (I, F, I) and G2 with vertices V2 = (L, 3, I), as illustrated in Figure 12 We extract subgraphs of length ô1 from both G1 and G2 Notably, (L) is identified as a subgraph of G2, obtained through the node extraction operation (L) Subsequently, we construct the cost matrix by calculating the edit distance between the subgraphs of G1 and G2, as detailed in Table 10.
Table 10 : La matrice de cỏts entre deux graphes G 1 , G 2
Puis nous utilisons l'algorithme hongrois avec les données entrées est cette matrice de cỏts pour trouver le cỏt de la meilleure association entre des sous-graphes de G 1 et G 2
Figure 12: un exemple de la correspondance de graphe, (a), (b) les sous-graphes d’extraction de longueur
1, (c) la correspondance de sous-graphe selon distance d’édition (ED)
Dans ce cas, la distance entre deux graphes G 1 , G 2 est 5
5 Représentation de l’information contenue dans une image
The field of computer vision leverages graph-based tools for tasks such as pattern recognition, indexing, and information spotting This involves the extraction and organization of information within an image, structuring it into a graph format.
Constitution de l'ensemble des nœuds
The configuration of all nodes is often task-dependent based on the specific application domain However, in this context, we address the issue in a generic manner while distinguishing between color images and black-and-white images.
Organisation de l’information Un graphe
Schéma 1 : le bloc fonctionnel de représentation de l’information contunue dans une image par un graphe
Voici le bloc fonctionnel de pas d’extraction d’information
We will subsequently refine our graph-based representation to address the unique characteristics of technical documents Although this report will not cover color images, this aspect could be implicitly addressed by replacing the information extraction functional block with a color segmentation algorithm (SMR).
Extraction des composantes connexes
Les composantes connexes sont des parties d'une image représentant une information de forme dans un document graphique noir et blanc
Figure 13: Analyse des composantes connexes
Étiquetage des composantes connexes
Extraction de caractéristiques
Dans le cas des images numériques, une fonction image (ou image) est une fonction I(x, y) Ν
Le moment géométrique mp,q d'une image I(x, y) ó p et q sont des entiers non négatifs et ó (p+q) est le rang (ou ordre) du moment est défini par :
Dans ce cadre, m 0,0 définit l'aire de l'objet et peut être utilisé pour les normalisations relatives au changement d'échelle.
Le moment central μ p,q est défini par : dy dx y x f y y x x p q q p , = + ∞ − ∫ ∞ + ∞ − ∫ ∞ ( − 0 ) ( − 0 ) ( , ) à avec (x 0 , y 0 ) le centre de gravité de I(x, y)
Le moment centré et normalisé η p, q peut être défini par :
Les moments centrés et normalisés sont invariants à la translation et au changement d'échelle.
Invariants de Hu a proposé six invariants aux transformations de rotation, translation et changement d'échelle basés sur des moments centraux du deuxième et du troisième ordre.
Statistique de la forme
Compacité (compactness) : elle est définie comme le rapport de l'aire d'un objet à l'aire d'un cercle avec le même périmètre.
La mesure prend la valeur de 1 pour un cercle.
Convexity is a measure that can be calculated by taking the ratio of the perimeter of a convex hull surrounding an object to the perimeter of the object itself This relationship defines the concept of convexity in geometric terms, providing insight into the shape and characteristics of the object.
Il prendra la valeur de 1 pour un objet convexe, et peut être inférieur à 1 si l'objet n'est pas convexe.
Roundness is a measure that quantifies the smoothness of an object's shape, excluding local irregularities It can be determined by comparing the surface area of the object to that of a convex circle with the same perimeter.
Comme avec la mesure de la compacité, elle est égale à 1 pour un objet circulaire et est inférieur à 1 pour un objet qui s'éloigne de la circularité. Élongation (elongation)
Another commonly used statistic to describe shape is a measure of elongation, which can be defined in various ways One method calculates elongation by taking the ratio of an object's length to its width, expressed as: elongation = length / breadth.
Figure 14: Mesure de l'élongation, comme le ratio de la longueur-largeur
Une autre mesure de l'élongation est donnée par le rapport du deuxième ordre moments de l'objet selon ses axes majeurs et mineurs:
' 20 1 tan 2 2 1 cos sin 2 sin cos cos sin 2 cos sin à à à à à à à à λ à à à λ
Classification non supervisée des caractéristiques morphologiques
The common goal of unsupervised classification algorithms is to organize a dataset into coherent clusters, where items within the same cluster exhibit high similarity, while items in different clusters demonstrate significant dissimilarity.
En considérant un ensemble X d'objets
La classification non supervisée partitionnelle cherche une K-partition de X
Organisation de l’information : Construction d’un Graphe de voisinage
Relations d'Allen bidimensionnelles
Allen's interval algebra is a mathematical framework for temporal reasoning introduced by James F Allen in 1983 To incorporate these considerations and integrate their properties into structural representations, the Allen relations are used to label arcs modeling neighborhood relationships A restricted set of five relations is employed, which includes disjoint, overlaps, during, during inverse, and equals.
Figure 16: Jeu restreint de relations d'Allen
To ensure rotational invariance, these two-dimensional relationships are established concerning a local coordinate system associated with the described object This coordinate system is directly linked to the object's two principal axes of inertia, as illustrated in Figure 17.
La figure 17 montre le résultat de la détermination de ce système de coordonnées pour quelques composantes connexes.
Figure 17: (a) deux composantes connesxes, (b) détermination du système de coordonnées lié aux composantes connexes (c) résultats des relations d'Allen bi-dimensionnelles (dj_o est l'abbréviation de disjoint_overlaps)
Intervalle basé sur les distances entre deux régions
The challenge we face is identifying the locations of a symbol within a plan, which involves two key components: a training phrase for the plan and a testing phrase for the symbol The output from these phrases generates the training graph and the test graph To ensure that the node and arc labels are more similar, we must utilize the common variables present in both phrases.
In this arc labeling method based on the distances between two regions, we calculate the maximum distance value between connected components This value serves as a common reference for both the learning and testing phases, having been computed during the information extraction stage of the learning phase The distance between two connected components is analogous to the distance between their centroids.
D’après d’avoir la variable distance maximale (d-max), nous divisons de 0 à d-max en n intervalles L’étiquetage entre des arcs va déterminer basé sur sa distance et n intervalle
Figure 18: L’image à gauche : représentation de la distance entre deux composantes connexes, d-max =
39 Le graphe droit obtenu par n = 10 (n est le nombre d’intervalles)
Protocole
Test en classification
Dans notre contexte de classification de graphes, nous avons utilisé un classifieur de type K-
To evaluate the performance of our graph matching method based on the assignment of subgraphs of length (l), we utilized two databases: Letter and Mutagenicity 2.
Soit X = (x 1 , , x n ) est un ensemble des données d’apprentissage Nous supposons que X contient au moins un graphe avec son étiquette de classe c, 1