PERSON
- type representing a person or classIMAGE
- type of image containing the face of each personFACE
- type of DetectedFace
@Experiment(author="Jonathon Hare", dateCreated="2012-07-26", description="Face recognition cross validation experiment") public class CrossValidationBenchmark<PERSON,IMAGE extends Image<?,IMAGE>,FACE extends DetectedFace> extends Object implements RunnableExperiment
RunnableExperiment
for performing cross-validation experiments on
face recognisers & classifiers.Modifier and Type | Field and Description |
---|---|
protected CrossValidator<GroupedDataset<PERSON,ListDataset<FACE>,FACE>> |
crossValidator |
protected GroupedDataset<PERSON,? extends ListDataset<IMAGE>,IMAGE> |
dataset |
protected FaceRecogniserProvider<FACE,PERSON> |
engine |
protected FaceDetector<FACE,IMAGE> |
faceDetector |
protected AggregatedCMResult<PERSON> |
result |
Constructor and Description |
---|
CrossValidationBenchmark(CrossValidator<GroupedDataset<PERSON,ListDataset<FACE>,FACE>> crossValidator,
GroupedDataset<PERSON,? extends ListDataset<IMAGE>,IMAGE> dataset,
FaceDetector<FACE,IMAGE> faceDetector,
FaceRecogniserProvider<FACE,PERSON> engine)
Construct the
CrossValidationBenchmark experiment with the given
dependent variables. |
Modifier and Type | Method and Description |
---|---|
void |
finish(ExperimentContext context)
Finalise the experiment, possibly writing the results, cleaning up, etc.
|
void |
perform()
Perform the experiment
|
void |
setup()
Setup of the experiment
|
@IndependentVariable protected CrossValidator<GroupedDataset<PERSON,ListDataset<FACE extends DetectedFace>,FACE extends DetectedFace>> crossValidator
@IndependentVariable protected GroupedDataset<PERSON,? extends ListDataset<IMAGE extends Image<?,IMAGE>>,IMAGE extends Image<?,IMAGE>> dataset
@IndependentVariable protected FaceDetector<FACE extends DetectedFace,IMAGE extends Image<?,IMAGE>> faceDetector
@IndependentVariable protected FaceRecogniserProvider<FACE extends DetectedFace,PERSON> engine
@DependentVariable protected AggregatedCMResult<PERSON> result
public CrossValidationBenchmark(CrossValidator<GroupedDataset<PERSON,ListDataset<FACE>,FACE>> crossValidator, GroupedDataset<PERSON,? extends ListDataset<IMAGE>,IMAGE> dataset, FaceDetector<FACE,IMAGE> faceDetector, FaceRecogniserProvider<FACE,PERSON> engine)
CrossValidationBenchmark
experiment with the given
dependent variables.dataset
- the datasetcrossValidator
- the cross-validatorfaceDetector
- the face detectorengine
- the recogniserpublic void perform()
RunnableExperiment
perform
in interface RunnableExperiment
public void setup()
RunnableExperiment
setup
in interface RunnableExperiment
public void finish(ExperimentContext context)
RunnableExperiment
ExperimentRunner
is provided so that
RunnableExperiment
implementations can access information for
generating their reports.
Note that at the point the context is provided,
it is not "locked" and is still recording. The ExperimentRunner
returns a completed locked context after the experiment has been completely
run.
finish
in interface RunnableExperiment
context
- the context provided by the ExperimentRunner