public abstract class AbstractCELA extends AbstractComponent implements ClassExpressionLearningAlgorithm, StoppableLearningAlgorithm
| Modifier and Type | Field and Description | 
|---|---|
static int | 
MAX_NR_OF_RESULTS
This is the maximum number of results, which the learning
 algorithms are asked to store. 
 | 
| Constructor and Description | 
|---|
AbstractCELA()
Default Constructor 
 | 
AbstractCELA(AbstractClassExpressionLearningProblem learningProblem,
            AbstractReasonerComponent reasoningService)
Each learning algorithm gets a learning problem and
 a reasoner as input. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
void | 
changeLearningProblem(AbstractClassExpressionLearningProblem learningProblem)
Call this when you want to change the learning problem, but
 leave everything else as is. 
 | 
void | 
changeReasonerComponent(AbstractReasonerComponent reasoningService)
Call this when you want to change the reasoning service, but
 leave everything else as is. 
 | 
Set<org.semanticweb.owlapi.model.OWLClass> | 
getAllowedConcepts()  | 
Set<org.semanticweb.owlapi.model.OWLDataProperty> | 
getAllowedDataProperties()  | 
Set<org.semanticweb.owlapi.model.OWLObjectProperty> | 
getAllowedObjectProperties()  | 
org.semanticweb.owlapi.model.OWLClassExpression | 
getCurrentlyBestDescription()  | 
List<org.semanticweb.owlapi.model.OWLClassExpression> | 
getCurrentlyBestDescriptions()  | 
List<org.semanticweb.owlapi.model.OWLClassExpression> | 
getCurrentlyBestDescriptions(int nrOfDescriptions)  | 
List<org.semanticweb.owlapi.model.OWLClassExpression> | 
getCurrentlyBestDescriptions(int nrOfDescriptions,
                            boolean filterNonMinimalDescriptions)  | 
EvaluatedDescription<? extends Score> | 
getCurrentlyBestEvaluatedDescription()
Returns the best descriptions obtained so far. 
 | 
NavigableSet<? extends EvaluatedDescription<? extends Score>> | 
getCurrentlyBestEvaluatedDescriptions()
Returns a sorted set of the best descriptions found so far. 
 | 
List<? extends EvaluatedDescription<? extends Score>> | 
getCurrentlyBestEvaluatedDescriptions(double accuracyThreshold)
Returns a fraction of class descriptions with sufficiently high accuracy. 
 | 
List<? extends EvaluatedDescription<? extends Score>> | 
getCurrentlyBestEvaluatedDescriptions(int nrOfDescriptions)
Return the best currently found concepts up to some maximum
 count (no minimality filter used). 
 | 
List<? extends EvaluatedDescription<? extends Score>> | 
getCurrentlyBestEvaluatedDescriptions(int nrOfDescriptions,
                                     double accuracyThreshold,
                                     boolean filterNonMinimalDescriptions)
Returns a filtered list of currently best class descriptions. 
 | 
List<? extends EvaluatedDescription<? extends Score>> | 
getCurrentlyBestMostGeneralEvaluatedDescriptions()  | 
Set<org.semanticweb.owlapi.model.OWLClass> | 
getIgnoredConcepts()  | 
Set<org.semanticweb.owlapi.model.OWLDataProperty> | 
getIgnoredDataProperties()  | 
Set<org.semanticweb.owlapi.model.OWLObjectProperty> | 
getIgnoredObjectProperties()  | 
AbstractClassExpressionLearningProblem<? extends Score> | 
getLearningProblem()
The learning problem variable, which must be used by
 all learning algorithm implementations. 
 | 
long | 
getMaxExecutionTimeInSeconds()  | 
AbstractReasonerComponent | 
getReasoner()
The reasoning service variable, which must be used by
 all learning algorithm implementations. 
 | 
boolean | 
isRunning()
Returns whether the learning algorithm is running. 
 | 
boolean | 
isUseMinimizer()  | 
void | 
setAllowedConcepts(Set<org.semanticweb.owlapi.model.OWLClass> allowedConcepts)  | 
void | 
setAllowedDataProperties(Set<org.semanticweb.owlapi.model.OWLDataProperty> allowedDataProperties)  | 
void | 
setAllowedObjectProperties(Set<org.semanticweb.owlapi.model.OWLObjectProperty> allowedObjectProperties)  | 
void | 
setIgnoredConcepts(Set<org.semanticweb.owlapi.model.OWLClass> ignoredConcepts)  | 
void | 
setIgnoredDataProperties(Set<org.semanticweb.owlapi.model.OWLDataProperty> ignoredDataProperties)  | 
void | 
setIgnoredObjectProperties(Set<org.semanticweb.owlapi.model.OWLObjectProperty> ignoredObjectProperties)  | 
void | 
setLearningProblem(LearningProblem learningProblem)
Set the learning problem, which the algorithm should solve. 
 | 
void | 
setMaxExecutionTime(long maxExecutionTime,
                   TimeUnit timeUnit)
Set the max. 
 | 
void | 
setMaxExecutionTimeInSeconds(long maxExecutionTimeInSeconds)
Set the max. 
 | 
void | 
setReasoner(AbstractReasonerComponent reasoner)  | 
void | 
setRenderer(org.semanticweb.owlapi.io.OWLObjectRenderer renderer)  | 
void | 
setUseMinimizer(boolean useMinimizer)  | 
void | 
stop()
Stops the algorithm gracefully. 
 | 
static Collection<Class<? extends AbstractClassExpressionLearningProblem>> | 
supportedLearningProblems()
Returns all learning problems supported by this component. 
 | 
isInitializedequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitstartpublic static final int MAX_NR_OF_RESULTS
public AbstractCELA()
public AbstractCELA(AbstractClassExpressionLearningProblem learningProblem, AbstractReasonerComponent reasoningService)
learningProblem - The learning problem to solve.reasoningService - The reasoner connecting to the
 underlying knowledge base.public void changeLearningProblem(AbstractClassExpressionLearningProblem learningProblem)
learningProblem - The new learning problem.public void changeReasonerComponent(AbstractReasonerComponent reasoningService)
reasoningService - The new reasoning service.public org.semanticweb.owlapi.model.OWLClassExpression getCurrentlyBestDescription()
getCurrentlyBestEvaluatedDescription()public List<org.semanticweb.owlapi.model.OWLClassExpression> getCurrentlyBestDescriptions()
getCurrentlyBestEvaluatedDescriptions()public List<org.semanticweb.owlapi.model.OWLClassExpression> getCurrentlyBestDescriptions(int nrOfDescriptions)
getCurrentlyBestDescriptions in interface ClassExpressionLearningAlgorithmnrOfDescriptions - Limit for the number or returned descriptions.getCurrentlyBestEvaluatedDescriptions(int)public List<org.semanticweb.owlapi.model.OWLClassExpression> getCurrentlyBestDescriptions(int nrOfDescriptions, boolean filterNonMinimalDescriptions)
nrOfDescriptions - Limit for the number or returned descriptions.filterNonMinimalDescriptions - Remove non-minimal descriptions (e.g. those which can be shortened
 to an equivalent concept) from the returned set.getCurrentlyBestEvaluatedDescriptions(int,double,boolean)public EvaluatedDescription<? extends Score> getCurrentlyBestEvaluatedDescription()
public NavigableSet<? extends EvaluatedDescription<? extends Score>> getCurrentlyBestEvaluatedDescriptions()
public List<? extends EvaluatedDescription<? extends Score>> getCurrentlyBestEvaluatedDescriptions(int nrOfDescriptions, double accuracyThreshold, boolean filterNonMinimalDescriptions)
nrOfDescriptions - Maximum number of restrictions. Use Integer.MAX_VALUE
 if you do not want this filter to be active.accuracyThreshold - Minimum accuracy. All class descriptions with lower
 accuracy are disregarded. Specify a value between 0.0 and 1.0. Use 0.0 if
 you do not want this filter to be active.filterNonMinimalDescriptions - If true, non-minimal descriptions are
 filtered, e.g. ALL r.TOP (being equivalent to TOP), male AND male (can be
 shortened to male). Currently, non-minimal descriptions are just skipped,
 i.e. they are completely omitted from the return list. Later, implementation
 might be changed to return shortened versions of those descriptions.public List<? extends EvaluatedDescription<? extends Score>> getCurrentlyBestEvaluatedDescriptions(int nrOfDescriptions)
getCurrentlyBestEvaluatedDescriptions in interface ClassExpressionLearningAlgorithmnrOfDescriptions - Maximum number of descriptions returned.public List<? extends EvaluatedDescription<? extends Score>> getCurrentlyBestEvaluatedDescriptions(double accuracyThreshold)
accuracyThreshold - Only return solutions with this accuracy or higher.public List<? extends EvaluatedDescription<? extends Score>> getCurrentlyBestMostGeneralEvaluatedDescriptions()
public static Collection<Class<? extends AbstractClassExpressionLearningProblem>> supportedLearningProblems()
public AbstractClassExpressionLearningProblem<? extends Score> getLearningProblem()
getLearningProblem in interface LearningAlgorithm@Autowired public void setLearningProblem(LearningProblem learningProblem)
LearningAlgorithmsetLearningProblem in interface LearningAlgorithmlearningProblem - The learning problem to solve.public AbstractReasonerComponent getReasoner()
@Autowired public void setReasoner(AbstractReasonerComponent reasoner)
public void stop()
StoppableLearningAlgorithmstop in interface StoppableLearningAlgorithmpublic boolean isRunning()
StoppableLearningAlgorithmisRunning in interface StoppableLearningAlgorithmpublic Set<org.semanticweb.owlapi.model.OWLClass> getAllowedConcepts()
public void setAllowedConcepts(Set<org.semanticweb.owlapi.model.OWLClass> allowedConcepts)
public Set<org.semanticweb.owlapi.model.OWLClass> getIgnoredConcepts()
public void setIgnoredConcepts(Set<org.semanticweb.owlapi.model.OWLClass> ignoredConcepts)
public void setAllowedObjectProperties(Set<org.semanticweb.owlapi.model.OWLObjectProperty> allowedObjectProperties)
allowedObjectProperties - the allowed object properties to setpublic Set<org.semanticweb.owlapi.model.OWLObjectProperty> getAllowedObjectProperties()
public void setIgnoredObjectProperties(Set<org.semanticweb.owlapi.model.OWLObjectProperty> ignoredObjectProperties)
ignoredObjectProperties - the ignored object properties to setpublic Set<org.semanticweb.owlapi.model.OWLObjectProperty> getIgnoredObjectProperties()
public void setAllowedDataProperties(Set<org.semanticweb.owlapi.model.OWLDataProperty> allowedDataProperties)
allowedDataProperties - the allowed data properties to setpublic Set<org.semanticweb.owlapi.model.OWLDataProperty> getAllowedDataProperties()
public void setIgnoredDataProperties(Set<org.semanticweb.owlapi.model.OWLDataProperty> ignoredDataProperties)
ignoredDataProperties - the ignored data properties to setpublic Set<org.semanticweb.owlapi.model.OWLDataProperty> getIgnoredDataProperties()
public boolean isUseMinimizer()
public void setUseMinimizer(boolean useMinimizer)
public long getMaxExecutionTimeInSeconds()
public void setMaxExecutionTimeInSeconds(long maxExecutionTimeInSeconds)
maxExecutionTimeInSeconds - max. execution time in secondspublic void setMaxExecutionTime(long maxExecutionTime, TimeUnit timeUnit)
maxExecutionTime - max. execution timetimeUnit - the time unitpublic void setRenderer(org.semanticweb.owlapi.io.OWLObjectRenderer renderer)
renderer - the renderer of OWL objects to set
 DL-Learner is licenced 						under the terms of the GNU General Public License.
Copyright © 2007-2019 Jens Lehmann