|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object Facemorph.aam.CLMLR
public class CLMLR
CLM logistic regression method
Constructor Summary | |
---|---|
CLMLR()
|
Method Summary | |
---|---|
void |
build(java.lang.String file,
HaarReader haar)
Build a CLMLR model from the images listed in file using the haar face detector |
Template |
delineate(java.awt.image.BufferedImage bimg,
HaarReader haar,
Template template,
ImageZoomPanel izp)
Delineate am image using this CLMLR and the convex quadratic fitting method (CQF) |
Template |
delineateELS(java.awt.image.BufferedImage bimg,
HaarReader haar,
Template template,
ImageZoomPanel izp)
Delineate am image using this CLMLR using the exhaustive local search (ELS) method |
FloatImage[] |
getStrip(Template tem,
FloatImage fimg,
java.awt.Rectangle rect,
int minOffset,
int maxOffset)
Gets the patches from all points arranged in a strip |
static void |
main(java.lang.String[] args)
Main method used for generating a random split of the data |
boolean |
processPatches(java.util.ArrayList<FloatImage[]> patches,
java.util.ArrayList<FloatImage[]> negativePatches,
boolean doCV)
Build the LR model from the patches |
void |
read(java.lang.String file)
Reads PCI data from a directory |
void |
write(java.lang.String file)
Writes CLMSVM data to a directory |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CLMLR()
Method Detail |
---|
public void build(java.lang.String file, HaarReader haar) throws java.io.FileNotFoundException, java.io.IOException
file
- the name of the file containing the imageshaar
- the haar wavelet face detector
java.io.FileNotFoundException
java.io.IOException
public Template delineateELS(java.awt.image.BufferedImage bimg, HaarReader haar, Template template, ImageZoomPanel izp) throws PowellException
bimg
- the image to delineatehaar
- the face detectortemplate
- used to initialise if not nullizp
- the image zoom panel to use if animating the searcg
PowellException
public Template delineate(java.awt.image.BufferedImage bimg, HaarReader haar, Template template, ImageZoomPanel izp) throws PowellException
bimg
- the image to delineatehaar
- the face detectortemplate
- used to initialise if not nullizp
- the image zoom panel to use if animating the searcg
PowellException
public FloatImage[] getStrip(Template tem, FloatImage fimg, java.awt.Rectangle rect, int minOffset, int maxOffset)
tem
- the current templatefimg
- the image to sample the patches fromrect
- the face detection rectangle, if not null this indicates that the priors should be updatedminOffset
- the minimum offset used when building an enriched training setmaxOffset
- the maximum offset used when building an enriched training set
public boolean processPatches(java.util.ArrayList<FloatImage[]> patches, java.util.ArrayList<FloatImage[]> negativePatches, boolean doCV) throws java.io.IOException
patches
- the positive example patchesnegativePatches
- the negative example patchesdoCV
- not currently used
java.io.IOException
public void read(java.lang.String file) throws java.io.IOException
file
- The text file containing the names of the image component files and their variance
java.io.IOException
- if the file can't be readpublic void write(java.lang.String file) throws java.io.IOException
file
- The text file containing the names of the image component files and their variance
java.io.IOException
- throws IOException if problem writing filepublic static void main(java.lang.String[] args) throws java.io.FileNotFoundException, java.io.IOException
args
- args[0] = name of file to read, args[1] = fraction to put in file1, args[2] = output file1, args[3] = output file2
java.io.FileNotFoundException
java.io.IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |