SmartDataAnalytics / DL-Learner

A tool for supervised Machine Learning in OWL and Description Logics
http://dl-learner.org
GNU General Public License v3.0
152 stars 34 forks source link

Horizontal expansion in DL-Learner/components-core/src/main/java/org/dllearner/algorithms/celoe/OENode.java #70

Closed aris-github closed 5 years ago

aris-github commented 5 years ago

In theory, the horizontal expansion shall be the upper bound on the length of child concepts. But in DL-Learner/components-core/src/main/java/org/dllearner/algorithms/celoe/OENode.java, the horizontal expansion is set to length-1 in the constructor:

    public OENode(OWLClassExpression description, double accuracy) {
        this.description = description;
        this.accuracy = accuracy;
        this.horizontalExpansion = OWLClassExpressionUtils.getLength(description) - 1;
    }

I wonder why this is necessary? Since later in the refinement step in CELOE (private TreeSet<OWLClassExpression> refineNode(OENode node)), this value is manually increased to enable refinement computation, otherwise, the upper bound of refinements is even smaller than the length of the current node:

    int horizExp = node.getHorizontalExpansion();
    TreeSet<OWLClassExpression> refinements = (TreeSet<OWLClassExpression>) operator.refine(node.getDescription(), horizExp+1);

On the other hand, this modification also affects the calculation of the heuristics, as the selection happens before refinement.

Am I getting something wrong?

SimonBin commented 5 years ago

Thanks for your issue report

SimonBin commented 5 years ago

fixed in c15cc4c0a