Class SimCalculatorSingleStrategy

  • All Implemented Interfaces:
    SimCalculatorStrategy

    public class SimCalculatorSingleStrategy
    extends Object
    implements SimCalculatorStrategy
    Computes similarities for the similarity cache by computing those similarities individually without using retrievers.
    Author:
    Maximilian Hoffmann
    • Constructor Detail

      • SimCalculatorSingleStrategy

        public SimCalculatorSingleStrategy()
    • Method Detail

      • computeSimilarities

        public long computeSimilarities​(DecimalFormat df,
                                        WriteableObjectPool queryPool,
                                        WriteableObjectPool casePool,
                                        AbstractSimilarityCacheMatrix similarityMatrix)
        Computes the similarities according to the strategy. Thereby, the implementation should use the given methods of this interface to enable printing of the progress and utilizing the cache functionality.
        Specified by:
        computeSimilarities in interface SimCalculatorStrategy
        Parameters:
        df - the decimal format to use
        queryPool - Pool of queries
        casePool - Pool of cases
        similarityMatrix - the similarity matrix to fill
        Returns:
        the overall time the procedure ran