public class MetricSDNMEntropyBasedInformationLoss extends AbstractMetricSingleDimensional
Metric.AggregateFunction
Constructor and Description |
---|
MetricSDNMEntropyBasedInformationLoss()
Creates a new instance.
|
MetricSDNMEntropyBasedInformationLoss(double gsFactor)
Creates a new instance.
|
Modifier and Type | Method and Description |
---|---|
ILSingleDimensional |
createMaxInformationLoss()
Returns an instance of the maximal value.
|
ILSingleDimensional |
createMinInformationLoss()
Returns an instance of the minimal value.
|
MetricConfiguration |
getConfiguration()
Returns the configuration of this metric.
|
static double |
getEntropyBasedInformationLoss(Transformation transformation,
HashGroupifyEntry entry,
DomainShare[] shares,
DistributionAggregateFunction[] microaggregationFunctions,
int microaggregationStartIndex,
double maxIL)
Implements the entropy-based IL model.
|
protected ILSingleDimensionalWithBound |
getInformationLossInternal(Transformation transformation,
HashGroupify g)
Evaluates the metric for the given node.
|
protected InformationLossWithBound<ILSingleDimensional> |
getInformationLossInternal(Transformation transformation,
HashGroupifyEntry entry)
Returns the information loss that would be induced by suppressing the given entry.
|
protected ILSingleDimensional |
getLowerBoundInternal(Transformation transformation)
Returns a lower bound for the information loss for the given node.
|
protected ILSingleDimensional |
getLowerBoundInternal(Transformation transformation,
HashGroupify groupify)
Returns a lower bound for the information loss for the given node.
|
static double |
getMaximalEntropyBasedInformationLoss(DomainShare[] domainShares,
int[] domainSizes)
Returns the maximal entropy-based information loss
|
java.lang.String |
getName()
Returns the name of metric.
|
protected DomainShare[] |
getShares()
For subclasses.
|
protected void |
initializeInternal(DataManager manager,
DataDefinition definition,
Data input,
GeneralizationHierarchy[] hierarchies,
ARXConfiguration config)
Implement this to initialize the metric.
|
boolean |
isAbleToHandleMicroaggregation()
Returns whether this metric handles microaggregation
|
boolean |
isGSFactorSupported()
Returns whether a generalization/suppression factor is supported
|
ElementData |
render(ARXConfiguration config)
Renders the privacy model
|
java.lang.String |
toString()
Returns the name of metric.
|
createInformationLoss, createInformationLoss, getDimensions, getDimensionsAggregated, getDimensionsGeneralized, getMicroaggregationDomainSizes, getMicroaggregationFunctions, getMicroaggregationStartIndex, getNumTuples, setNumTuples
createAECSMetric, createAECSMetric, createAmbiguityMetric, createDiscernabilityMetric, createDiscernabilityMetric, createEntropyBasedInformationLossMetric, createEntropyBasedInformationLossMetric, createEntropyMetric, createEntropyMetric, createEntropyMetric, createEntropyMetric, createEntropyMetric, createEntropyMetric, createHeightMetric, createHeightMetric, createInstanceOfHighestScore, createInstanceOfLowestScore, createKLDivergenceMetric, createLossMetric, createLossMetric, createLossMetric, createLossMetric, createMetric, createNormalizedEntropyMetric, createNormalizedEntropyMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecisionMetric, createPrecomputedEntropyMetric, createPrecomputedEntropyMetric, createPrecomputedEntropyMetric, createPrecomputedEntropyMetric, createPrecomputedEntropyMetric, createPrecomputedEntropyMetric, createPrecomputedLossMetric, createPrecomputedLossMetric, createPrecomputedLossMetric, createPrecomputedLossMetric, createPrecomputedNormalizedEntropyMetric, createPrecomputedNormalizedEntropyMetric, createPublisherPayoutMetric, createPublisherPayoutMetric, createStaticMetric, createStaticMetric, getAggregateFunction, getDescription, getDescription, getGeneralizationFactor, getGeneralizationSuppressionFactor, getInformationLoss, getInformationLoss, getLowerBound, getLowerBound, getNumRecords, getSubset, getSuppressionFactor, initialize, isIndependent, isMonotonic, isMonotonicWithGeneralization, isMonotonicWithSuppression, isMultiDimensional, isPrecomputed, isWeighted, list, round
public MetricSDNMEntropyBasedInformationLoss()
public MetricSDNMEntropyBasedInformationLoss(double gsFactor)
gsFactor
- A factor [0,1] weighting generalization and suppression.
The default value is 0.5, which means that generalization
and suppression will be treated equally. A factor of 0
will favor suppression, and a factor of 1 will favor
generalization. The values in between can be used for
balancing both methods.public static double getEntropyBasedInformationLoss(Transformation transformation, HashGroupifyEntry entry, DomainShare[] shares, DistributionAggregateFunction[] microaggregationFunctions, int microaggregationStartIndex, double maxIL)
transformation
- entry
- shares
- functions
- microaggregationStartIndex
- maxIL
- public static double getMaximalEntropyBasedInformationLoss(DomainShare[] domainShares, int[] domainSizes)
domainShares
- For generalized attributesdomainSizes
- For microaggregated attributespublic ILSingleDimensional createMaxInformationLoss()
Metric
createMaxInformationLoss
in class AbstractMetricSingleDimensional
public ILSingleDimensional createMinInformationLoss()
Metric
createMinInformationLoss
in class AbstractMetricSingleDimensional
public MetricConfiguration getConfiguration()
getConfiguration
in class Metric<ILSingleDimensional>
public java.lang.String getName()
Metric
getName
in class Metric<ILSingleDimensional>
public boolean isAbleToHandleMicroaggregation()
Metric
isAbleToHandleMicroaggregation
in class Metric<ILSingleDimensional>
public boolean isGSFactorSupported()
Metric
isGSFactorSupported
in class Metric<ILSingleDimensional>
public ElementData render(ARXConfiguration config)
Metric
render
in class Metric<ILSingleDimensional>
public java.lang.String toString()
Metric
toString
in class Metric<ILSingleDimensional>
protected ILSingleDimensionalWithBound getInformationLossInternal(Transformation transformation, HashGroupify g)
Metric
getInformationLossInternal
in class Metric<ILSingleDimensional>
transformation
- The node for which to compute the information lossg
- The groupify operator of the previous checkprotected InformationLossWithBound<ILSingleDimensional> getInformationLossInternal(Transformation transformation, HashGroupifyEntry entry)
Metric
getInformationLoss(node, groupify)
but is guaranteed to be comparable for
different entries from the same groupify operator.getInformationLossInternal
in class Metric<ILSingleDimensional>
protected ILSingleDimensional getLowerBoundInternal(Transformation transformation)
Metric
null
.getLowerBoundInternal
in class Metric<ILSingleDimensional>
protected ILSingleDimensional getLowerBoundInternal(Transformation transformation, HashGroupify groupify)
Metric
null
. getLowerBoundInternal
in class Metric<ILSingleDimensional>
protected DomainShare[] getShares()
protected void initializeInternal(DataManager manager, DataDefinition definition, Data input, GeneralizationHierarchy[] hierarchies, ARXConfiguration config)
Metric
initializeInternal
in class AbstractMetricSingleDimensional