Class Weighting

java.lang.Object
eu.qualimaster.easy.extension.internal.Weighting
All Implemented Interfaces:
net.ssehub.easy.instantiation.core.model.vilTypes.IVilType

public class Weighting extends Object implements net.ssehub.easy.instantiation.core.model.vilTypes.IVilType
Weighting functions.
Author:
Holger Eichelberger
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    private static interface 
    A prediction processor.
    private static class 
    Implements a maximum prediction processor, i.e., collects the maximum values of the predictions.
    private static class 
    Implements an update processor calculating the weighted predictions.
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    private static void
    processPredictions(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, Weighting.IPredictionProcessor processor)
    Processes predictions.
    static net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,Double>
    weightAll(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting)
    Implements a weighting for mass predictions.
    static net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,Double>
    weightAll(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, net.ssehub.easy.instantiation.core.model.vilTypes.Set<eu.qualimaster.observables.IObservable> costs)
    Implements a weighting for mass predictions.
    static Map<String,Double>
    weightAllImpl(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, net.ssehub.easy.instantiation.core.model.vilTypes.Set<eu.qualimaster.observables.IObservable> costs)
    Implements a weighting of mass predictions.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • Weighting

      public Weighting()
  • Method Details

    • weightAll

      public static net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,Double> weightAll(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting)
      Implements a weighting for mass predictions.
      Parameters:
      predictions - the predictions given as name-observable-prediction mapping, may be null, entries may be null
      weighting - the weighting of the observables, negative weights invert the value by subtracting from the respective maximum
      Returns:
      the "best" solution in terms of the name as maximum of weighted average sums
    • weightAll

      public static net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,Double> weightAll(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, net.ssehub.easy.instantiation.core.model.vilTypes.Set<eu.qualimaster.observables.IObservable> costs)
      Implements a weighting for mass predictions.
      Parameters:
      predictions - the predictions given as name-observable-prediction mapping, may be null, entries may be null
      weighting - the weighting of the observables, negative weights invert the value by subtracting from the respective maximum
      costs - the costs, i.e., observables to be counted negative
      Returns:
      the "best" solution in terms of the name as maximum of weighted average sums
    • weightAllImpl

      public static Map<String,Double> weightAllImpl(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, net.ssehub.easy.instantiation.core.model.vilTypes.Set<eu.qualimaster.observables.IObservable> costs)
      Implements a weighting of mass predictions.
      Parameters:
      predictions - the predictions given as name-observable-prediction mapping, may be null, entries may be null
      weighting - the weighting of the observables, negative weights invert the value by subtracting from the respective maximum
      costs - the costs, i.e., observables to be counted negative (may be null for no costs)
      Returns:
      the "best" solution in terms of the name as the maximum the average weighted value if no costs, the maximum weighted sum if costs
    • processPredictions

      private static void processPredictions(net.ssehub.easy.instantiation.core.model.vilTypes.Map<String,net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double>> predictions, net.ssehub.easy.instantiation.core.model.vilTypes.Map<eu.qualimaster.observables.IObservable,Double> weighting, Weighting.IPredictionProcessor processor)
      Processes predictions.
      Parameters:
      predictions - the predictions
      weighting - the weighting, negative weights invert the value by subtracting from the respective maximum
      processor - the prediction processor