blob: 052a46c0ca04412783ff409c64cc5ec060c6fdde [file] [log] [blame]
<?php require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/app.class.php"); require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/nav.class.php"); require_once($_SERVER['DOCUMENT_ROOT'] . "/eclipse.org-common/system/menu.class.php"); $App = new App(); $Nav = new Nav(); $Menu = new Menu(); include($App->getProjectCommon()); # All on the same line to unclutter the user's desktop'
#*****************************************************************************
#
# AMW_Match_SF_doc.php
#
# Author: Marcos Didonet Del Fabro
# Date: 2005-07-24
#
# Description: Type your page comments here - these are not sent to the browser
#
#
#****************************************************************************
#
# Begin: page-specific settings. Change these.
$pageTitle = "Equality matching and similarity flooding";
$pageKeywords = "";
$pageAuthor = "Marcos Didonet Del Fabro";
# Paste your HTML content between the EOHTML markers!
$html = <<<EOHTML
<!-- Main part -->
<div id="midcolumn">
<table width="100%">
<tr>
<td width="50%">
<h1>$pageTitle</h1>
</td>
</tr>
</table>
<p>
This example contains a set of matching transformations used to produce a weaving
model. The example is an implementation of an adapted version of the Similarity
Flooding algorithm <a href="#melnik">[1]</a>
The example contains three transformations:
<ul class="midlist">
<li>The first transformation calculates similarity
values between model elements and creates a propagation graph.
</li>
<li>
The second transformation propagates the similarity values through nodes that are
connected (neighbors).
</li>
<li>
The third transformation
selects the best matching results and creates a weaving model.
</li>
</ul>
<p/>
<h4>Accuracy of the weaving model</h4>
The final output weaving model contains links generated automatically by the matching transformations.
The accuracy of the weaving model depends basically on two factors: how the similarities are calculated,
and how to select the best similarity values.<br/>
In this simple example, the main matching criteria is the
name equality between elements (e.g., author = author, title = title, etc.).
There are many other criteria that are not covered in this example (dictionaries, string matching, etc.).
The best results are selected by looping over all the elements of the left model and by choosing the right element
with the best corresponding similarity value.
<h2>Instructions</h2>
<h4>Executing the transformations</h4>
<p/>
There is an Ant Script (scripts/executeAll.xml) that produces a weaving model
(models/mw_refined_match.ecore) between two KM3 models (models/Book-KM3.ecore and models/Publication-KM3.ecore).
The script executes the following actions:
<ul class="midlist">
<li>
Executes the PropagationGraph.atl transformation. This transformation creates the cartesian product
between the elements of the input models and it calculates a similarity value between every pair of elements.
The similarities are calculated using the name, cardinality and type.
The output is a propagation model (models/propagation_model.ecore) conforming
to metamodels/propagation_graph.ecore.
</li>
<li>
Executes the SimilarityFlood.atl transformation. It propagates the similarity values
calculated by PropagationGraph.atl through the elements that are connected. This transformation may be executed
more than one time.
</li>
<li>
Executes the Selects_SF_amw.atl transformation. This transformation selects a set of nodes with the best
similarity values and creates a weaving model (models/mw_refined_match.ecore) with equality mappings.
</li>
</ul>
<p/>
<h4>Loading the weaving model into AMW:</h4>
The weaving model (models/mw_refined_match.ecore) can be loaded by double-clicking on the
file or by using the wizard.
<p/>
<b>Remarks:</b></br>
<ul class="midlist">
<li>
The ATL transformations can also be executed separatedly by using the corresponding launch configuration scripts.
</li>
<li>
The PropagationGraph.atl transformation contains rules that match more than one input element. This
is a new feature that uses the ATL 2006 compiler.
Instructions about how to install it are available <a href="http://wiki.eclipse.org/index.php/AMW_Examples_HowTo">here</a>.
</li>
<li>
The "for" task that executes the SimilarityFlooding.atl transformation several times is not a
standard Ant task, but a task available at the <a href="http://ant-contrib.sourceforge.net/">Ant Contrib project</a>.
It is necessary to install the "for" task as described
<a href="http://ant-contrib.sourceforge.net/tasks/index.html">here</a>.
</li>
<li>
The SimilarityFlood.atl transformation has some performance issues when matching large models.
</li>
</ul>
<p/>
<b>References:</b></br>
<a name = #melnik> 1</a>. Melnik, S. Generic Model Management: Concepts and Algorithms, Ph.D. Dissertation, University of Leipzig, Springer LNCS 2967, 2004
</div>
EOHTML;
# Generate the web page
$App->generatePage($theme, $Menu, $Nav, $pageAuthor, $pageKeywords, $pageTitle, $html);
?>