public class MultiSimilarity extends Similarity
This method will calculate all x all feature attributes, and then generate an aggregate score for the entity pair. This is done using a "sub-similarity" method.
For all best-matching attributes (in both directions) an additional "deep similarity" check is performed. Calculating this may be more computationally expensive than the method used to do the all by all comparison.
The final score is the average of all best-matching attributes by the sub-similarity method. TODO: also provide average of all best-matching by deep-sim method
This method is configurable.
By default, AsymmetricJaccardSimilarity is used to calculate all x all attributes for the entity pair.
ConjunctiveSetInformationContentRatioSimilarity is used for the "deep simularity" check - i.e. by default all the best matching attributes scored by AsymmetricJaccardSimilarity will be compared by ConjunctiveSetInformationContentRatioSimilarity.
The average of all ConjunctiveSetInformationContentRatioSimilarity scores for all best matches is similar to avgICCS in Washington et al. The difference is that ConjunctiveSetInformationContentRatioSimilarity can include dynamic LCSs.
This method can also be used to generate the maxIC - simply take the maximum of the IC of all reported ConjunctiveSetInformationContentRatioSimilarity values
Modifier and Type | Field and Description |
---|---|
double |
aScore |
double |
bScore |
String[] |
deepSimMethods |
Map<org.semanticweb.owlapi.model.OWLObject,Set<org.semanticweb.owlapi.model.OWLObject>> |
featureToAttributeMap |
String |
preSimMethod |
String |
subSimMethod |
minScore
Constructor and Description |
---|
MultiSimilarity() |
Modifier and Type | Method and Description |
---|---|
void |
calculate(SimEngine simEngine,
org.semanticweb.owlapi.model.OWLObject a,
org.semanticweb.owlapi.model.OWLObject b) |
String |
getPreSimMethod() |
String |
getSubSimMethod() |
void |
print(PrintStream s) |
void |
report(Reporter r) |
void |
setPreSimMethod(String preSimMethod) |
void |
setSubSimMethod(String subSimMethod) |
Set<org.semanticweb.owlapi.model.OWLObject> |
sortMapByScore(Map<org.semanticweb.owlapi.model.OWLObject,Similarity> map) |
protected void |
translateResultsToOWLAxioms(String id,
org.semanticweb.owlapi.model.OWLNamedIndividual result,
Set<org.semanticweb.owlapi.model.OWLAxiom> axioms)
adds additional axioms specific to this method.
|
addResultsToOWLOntology, annotationIRI, createOWLOntologyFromResults, getScore, isAboveMinScore, print, print, printDescription, printDescription, setScore, setScore, splitIRI, toString, translateResultsToOWLAxioms
public String[] deepSimMethods
public String subSimMethod
public String preSimMethod
public double aScore
public double bScore
public String getSubSimMethod()
public void setSubSimMethod(String subSimMethod)
public String getPreSimMethod()
public void setPreSimMethod(String preSimMethod)
public void calculate(SimEngine simEngine, org.semanticweb.owlapi.model.OWLObject a, org.semanticweb.owlapi.model.OWLObject b) throws SimEngine.SimilarityAlgorithmException
calculate
in class Similarity
SimEngine.SimilarityAlgorithmException
public Set<org.semanticweb.owlapi.model.OWLObject> sortMapByScore(Map<org.semanticweb.owlapi.model.OWLObject,Similarity> map)
public void report(Reporter r)
report
in class Similarity
public void print(PrintStream s)
print
in class Similarity
protected void translateResultsToOWLAxioms(String id, org.semanticweb.owlapi.model.OWLNamedIndividual result, Set<org.semanticweb.owlapi.model.OWLAxiom> axioms)
translateResultsToOWLAxioms
in class Similarity
id
- result
- axioms
- Copyright © 2010–2016. All rights reserved.