Klasse MetricMDNUEntropyPrecomputed

Alle implementierten Schnittstellen:
Serializable
Bekannte direkte Unterklassen:
MetricMDNUEntropy, MetricMDNUNMEntropyPrecomputed

public class MetricMDNUEntropyPrecomputed extends AbstractMetricMultiDimensional
This class provides an efficient implementation of the non-uniform entropy metric. It avoids a cell-by-cell process by utilizing a three-dimensional array that maps identifiers to their frequency for all quasi-identifiers and generalization levels. It further reduces the overhead induced by subsequent calls by caching the results for previous columns and generalization levels. See:
A. De Waal and L. Willenborg: "Information loss through global recoding and local suppression" Netherlands Off Stat, vol. 14, pp. 17–20, 1999.
Siehe auch:
  • Konstruktordetails

    • MetricMDNUEntropyPrecomputed

      public MetricMDNUEntropyPrecomputed(boolean monotonicWithGeneralization, boolean monotonicWithSuppression, boolean independent, double gsFactor, Metric.AggregateFunction function)
      Precomputed.
      Parameter:
      monotonicWithGeneralization -
      monotonicWithSuppression -
      independent -
      gsFactor -
      function -
    • MetricMDNUEntropyPrecomputed

      protected MetricMDNUEntropyPrecomputed()
      Creates a new instance.
    • MetricMDNUEntropyPrecomputed

      protected MetricMDNUEntropyPrecomputed(double gsFactor, Metric.AggregateFunction function)
      Creates a new instance.
      Parameter:
      gsFactor -
      function -
  • Methodendetails

    • getConfiguration

      public MetricConfiguration getConfiguration()
      Returns the configuration of this metric.
      Setzt außer Kraft:
      getConfiguration in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • getScore

      public ILScore getScore(org.deidentifier.arx.framework.lattice.Transformation<?> node, org.deidentifier.arx.framework.check.groupify.HashGroupify groupify)
      Beschreibung aus Klasse kopiert: Metric
      Calculates the score. Note: All score functions are expected to return a score value divided by the sensitivity of the score function.
      Setzt außer Kraft:
      getScore in Klasse Metric<AbstractILMultiDimensional>
      Parameter:
      node -
      groupify -
      Gibt zurück:
    • isGSFactorSupported

      public boolean isGSFactorSupported()
      Beschreibung aus Klasse kopiert: Metric
      Returns whether a generalization/suppression factor is supported
      Setzt außer Kraft:
      isGSFactorSupported in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • isPrecomputed

      public boolean isPrecomputed()
      Beschreibung aus Klasse kopiert: Metric
      Returns whether the metric is precomputed
      Setzt außer Kraft:
      isPrecomputed in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • isScoreFunctionSupported

      public boolean isScoreFunctionSupported()
      Beschreibung aus Klasse kopiert: Metric
      Returns whether the metric provides a score function
      Setzt außer Kraft:
      isScoreFunctionSupported in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • render

      public ElementData render(ARXConfiguration config)
      Beschreibung aus Klasse kopiert: Metric
      Renders the privacy model
      Angegeben von:
      render in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • toString

      public String toString()
      Beschreibung aus Klasse kopiert: Metric
      Returns the name of metric.
      Setzt außer Kraft:
      toString in Klasse Metric<AbstractILMultiDimensional>
      Gibt zurück:
    • getInformationLossInternal

      protected ILMultiDimensionalWithBound getInformationLossInternal(org.deidentifier.arx.framework.lattice.Transformation<?> node, org.deidentifier.arx.framework.check.groupify.HashGroupify g)
      Beschreibung aus Klasse kopiert: Metric
      Evaluates the metric for the given node.
      Angegeben von:
      getInformationLossInternal in Klasse Metric<AbstractILMultiDimensional>
      Parameter:
      node - The node for which to compute the information loss
      g - The groupify operator of the previous check
      Gibt zurück:
      the double
    • getInformationLossInternal

      protected ILMultiDimensionalWithBound getInformationLossInternal(org.deidentifier.arx.framework.lattice.Transformation<?> node, org.deidentifier.arx.framework.check.groupify.HashGroupifyEntry entry)
      Beschreibung aus Klasse kopiert: Metric
      Returns the information loss that would be induced by suppressing the given entry. The loss is not necessarily consistent with the loss that is computed by getInformationLoss(node, groupify) but is guaranteed to be comparable for different entries from the same groupify operator.
      Angegeben von:
      getInformationLossInternal in Klasse Metric<AbstractILMultiDimensional>
      Parameter:
      entry -
      Gibt zurück:
    • getInformationLossInternalRaw

      protected double[] getInformationLossInternalRaw(org.deidentifier.arx.framework.lattice.Transformation<?> node, org.deidentifier.arx.framework.check.groupify.HashGroupify g)
      Parameter:
      node -
      g -
      Gibt zurück:
    • getLowerBoundInternal

      protected AbstractILMultiDimensional getLowerBoundInternal(org.deidentifier.arx.framework.lattice.Transformation<?> node)
      Beschreibung aus Klasse kopiert: Metric
      Returns a lower bound for the information loss for the given node. This can be used to expose the results of monotonic shares of a metric, which can significantly speed-up the anonymization process. If no such metric exists, simply return null.
      Angegeben von:
      getLowerBoundInternal in Klasse Metric<AbstractILMultiDimensional>
      Parameter:
      node -
      Gibt zurück:
    • getLowerBoundInternal

      protected AbstractILMultiDimensional getLowerBoundInternal(org.deidentifier.arx.framework.lattice.Transformation<?> node, org.deidentifier.arx.framework.check.groupify.HashGroupify groupify)
      Beschreibung aus Klasse kopiert: Metric
      Returns a lower bound for the information loss for the given node. This can be used to expose the results of monotonic shares of a metric, which can significantly speed-up the anonymization process. If no such metric exists, simply return null.

      This variant of the method allows computing a monotonic share based on a groupified data representation. IMPORTANT NOTE: The groups may not have been classified correctly when the method is called, i.e., HashGroupifyEntry.isNotOutlier may not be set correctly!
      Angegeben von:
      getLowerBoundInternal in Klasse Metric<AbstractILMultiDimensional>
      Parameter:
      node -
      groupify -
      Gibt zurück:
    • getUpperBounds

      protected double[] getUpperBounds()
      Returns the upper bound of the entropy value per column
      Gibt zurück:
    • initialize

      protected void initialize(double[][] cache, int[][][] cardinalities, int[][][] hierarchies)
      For backwards compatibility.
      Parameter:
      cache -
      cardinalities -
      hierarchies -
    • initializeInternal

      protected void initializeInternal(org.deidentifier.arx.framework.data.DataManager manager, DataDefinition definition, org.deidentifier.arx.framework.data.Data input, org.deidentifier.arx.framework.data.GeneralizationHierarchy[] hierarchies, ARXConfiguration config)
      Beschreibung aus Klasse kopiert: Metric
      Implement this to initialize the metric.
      Setzt außer Kraft:
      initializeInternal in Klasse AbstractMetricMultiDimensional
      Parameter:
      manager -
      definition -
      input -
      hierarchies -
      config -