I have a problem with my face recognition code. Everytime I run the code there will be error of :
Exception in thread "main" java.lang.RuntimeException: Uncompilable source code - cannot find symbol
symbol: variable AppearanceRecognition
location: class AppearanceRecognition.EigenFacesRunner
at AppearanceRecognition.EigenFacesRunner.main(EigenFacesRunner.java:42)
C:\Users\Adila\AppData\Local\NetBeans\Cache\8.2\executor-snippets\run.xml:53: Java returned: 1
BUILD FAILED (total time: 0 seconds)
I copy this code from somewhere but I didn't remember where so I find it very difficult for me to understand the code.
The code is: package AppearanceRecognition;
import java.net.URISyntaxException;
public class EigenFacesRunner {
private AppearanceRecognition.Visualizer visualizer;
private FaceFinder faceFinder;
EigenFacesRunner() throws URISyntaxException {
FaceFinder faceFinder = new FaceFinder();
Visualizer visualizer = new Visualizer(faceFinder);
//visualizer.setOkHandler(new AppearanceRecognition.OkHandler(visualizer, faceFinder));
}
// public static int exponent(int base, int power) {
// int ans = -1;
// if (power >= 0) {
// ans = 1;
// for (int i = 0; i < power; i++){
// ans *= base;
// }
// }
//
// return ans;
// }
//
// public static int exponentRec(int base, int power) {
// if (power == 0)
// return 1;
//
// return base * exponentRec(base, power - 1);
// }
public static void main(String [] args) throws URISyntaxException {
int power = 0;
int base = 3;
//System.out.println(base + "^" + power + " equals " + exponent(base, power));
//System.out.println(base + "^" + power + " equals " + exponentRec(base, power));
AppearanceRecognition.Visualizer visualizer = new AppearanceRecognition.Visualizer();
FaceFinder faceFinder = new FaceFinder();
EigenFacesRunner runner = new EigenFacesRunner();
}
public static void debug(String msg){
System.out.println(msg);
}
}