|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object Facemorph.mdl.SpecificityImageTest
public class SpecificityImageTest
Spcificity test for image (only) model
Constructor Summary | |
---|---|
SpecificityImageTest(java.util.ArrayList<java.awt.image.BufferedImage> bimages)
Constructor for SpecificityImageTest |
Method Summary | |
---|---|
double |
calculateError(FloatImage[] img1,
FloatImage[] img2)
Calculates the error between two Ts |
double[] |
calculateSpecificity(int comps,
int trials)
Calculates the specitivity of the model |
double |
findMinError(FloatImage[] testImg)
Find the minimum error from the set of Ts |
static void |
main(java.lang.String[] args)
Main method runs the tests |
FloatImage[] |
makeRandom(int comps)
Makes a random T from the model |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SpecificityImageTest(java.util.ArrayList<java.awt.image.BufferedImage> bimages) throws java.io.FileNotFoundException, java.io.IOException
bimages
- the images to test with
java.io.FileNotFoundException
java.io.IOException
Method Detail |
---|
public FloatImage[] makeRandom(int comps)
SpecificityTest
makeRandom
in interface SpecificityTest<FloatImage[]>
comps
- the number of model components to use
public double calculateError(FloatImage[] img1, FloatImage[] img2)
SpecificityTest
calculateError
in interface SpecificityTest<FloatImage[]>
img1
- first Timg2
- second T
public double findMinError(FloatImage[] testImg) throws java.io.IOException
SpecificityTest
findMinError
in interface SpecificityTest<FloatImage[]>
testImg
- the test template
java.io.IOException
- may be thrown if data is readpublic double[] calculateSpecificity(int comps, int trials) throws java.io.IOException
SpecificityTest
calculateSpecificity
in interface SpecificityTest<FloatImage[]>
comps
- the number of model components to usetrials
- the number of trials to performs
java.io.IOException
- may be thrown if data is readpublic static void main(java.lang.String[] args) throws java.io.FileNotFoundException, java.io.IOException
args
- args[0] = number of warps (all named "warp"+i+".warp"), args[1] is the average template, args [2] = file to write results to
java.io.FileNotFoundException
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |