Class LigerRefinementOperator

    • Field Detail

      • logger

        protected static final org.apache.log4j.Logger logger
    • Constructor Detail

    • Method Detail

      • optimize

        public void optimize()
        Implements the basic idea of LIGER: Link Discovery with Guaranteed Recall. The algorithm's main loop starts and run until the total optimization time has exceeded maxOpt, the buffer or unrefined specification is empty or the selectivity of the best subsumed LS is equal to the desired selectivity. At the beginning of each iteration, the first element of the buffer queue is popped out and the algorithm checks if it receives a better run time score compared to the best specification's runtime estimation. If the new specifications achieves a better runtime estimation, the algorithm assigns it as the best specification. If the new best specification has achieved the desired selectivity, the algorithm terminates. Then, LIGER calls the function refine(), which implements the refinement operator. A new subsumed specification resulted from the refinement is stored iff it does not already exists in total set and its selectivity is higher or equal to the desired selectivity. Finally, the algorithm performs a hierarchical ordering of the specifications in the buffer queue with respect to runtime estimations.
        Specified by:
        optimize in class PartialRecallRefinementOperator
      • addSpecifications

        public void addSpecifications​(List<LinkSpecification> specs)
        Creates the set of to-be-refined nodes by adding specification that does not already exists in total set and their selectivity is higher or equal to the desired selectivity.
        Parameters:
        specs - , the input set of unchecked specifications
      • refine

        public List<LinkSpecification> refine​(LinkSpecification currentSpec)
        Implements the refinement operator for guaranteed recall.
        Parameters:
        currentSpec - , an input specification
        Returns:
        a list of refined specifications
      • refineAtomicLinkSpecification

        public LinkSpecification refineAtomicLinkSpecification​(LinkSpecification currentSpec)
        Refines an atomic link specification by calling the next(threshold) function.
        Parameters:
        currentSpec - ,an input specification
        Returns:
        null if the currentSpec can not be refine anymore, or a refined atomic specification
      • merge

        public List<LinkSpecification> merge​(LinkSpecification parent,
                                             List<LinkSpecification> leftChildren,
                                             List<LinkSpecification> rightChildren,
                                             boolean isLeft)
        Creates a set of new specification by cloning the input specification, keeping one child specification as is, and substitutes the other child specification with the set of specification retrieved by refining the other child.
        Parameters:
        parent - , an input specification
        leftChildren - , a set of left (refined) children specifications
        rightChildren - , a set of right (refined) children specifications
        isLeft - , flag that indicates with child, left or right, has been refined previously
        Returns:
        a set of specifications subsumed by the parent specification