public abstract class ScaleFeature extends java.lang.Object implements Feature
Modifier and Type | Class and Description |
---|---|
private static class |
ScaleFeature.MultFeature |
Modifier and Type | Field and Description |
---|---|
private Feature |
feature
the base feature
|
Modifier | Constructor and Description |
---|---|
protected |
ScaleFeature(Feature p_feature) |
Modifier and Type | Method and Description |
---|---|
static Feature |
createAffine(Feature f,
double coeff,
long offset)
Create a feature that applies an affine transformation to the result of
the base feature.
|
static Feature |
createAffine(Feature f,
RuleAppCost dom0,
RuleAppCost dom1,
RuleAppCost img0,
RuleAppCost img1)
Create a feature that applies an affine transformation to the result of
the base feature.
|
static Feature |
createScaled(Feature f,
double coeff)
Create a feature that scales the result of the base feature.
|
private static Feature |
firstDomInfty(Feature f,
RuleAppCost dom1,
RuleAppCost img0,
RuleAppCost img1) |
private static Feature |
firstImgInfty(Feature f,
RuleAppCost dom0,
RuleAppCost dom1,
RuleAppCost img1) |
protected Feature |
getFeature() |
private static long |
getValue(RuleAppCost cost) |
protected static void |
illegalCostError(RuleAppCost cost) |
protected static boolean |
isZero(double p) |
static Feature |
realAffine(Feature f,
RuleAppCost dom0,
RuleAppCost dom1,
RuleAppCost img0,
RuleAppCost img1) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
computeCost
private final Feature feature
protected ScaleFeature(Feature p_feature)
public static Feature createScaled(Feature f, double coeff)
f
- the base featurecoeff
- the coefficient to be applied to the result of
f
public static Feature createAffine(Feature f, double coeff, long offset)
f
- the base featurecoeff
- the coefficient to be applied to the result of
f
offset
- the offset to be added to the result of f
(after multiplication with coeff
)public static Feature createAffine(Feature f, RuleAppCost dom0, RuleAppCost dom1, RuleAppCost img0, RuleAppCost img1)
f
- the base featuredom0
- point 0 in the domaindom1
- point 1 in the domainimg0
- point 0 in the imageimg1
- point 1 in the imageprivate static Feature firstDomInfty(Feature f, RuleAppCost dom1, RuleAppCost img0, RuleAppCost img1)
private static Feature firstImgInfty(Feature f, RuleAppCost dom0, RuleAppCost dom1, RuleAppCost img1)
public static Feature realAffine(Feature f, RuleAppCost dom0, RuleAppCost dom1, RuleAppCost img0, RuleAppCost img1)
private static long getValue(RuleAppCost cost)
cost
- protected static void illegalCostError(RuleAppCost cost)
protected Feature getFeature()
protected static boolean isZero(double p)