Hi everyone,
I was tring to implement the face detection example with opencv.js.
The problem is that there's no way of importing the necessary haar cascade.
My project structure is as follows:
- index.html
- js
- myjs.js
- opencv.js
- utils.js
- haar
- haarcascade_frontalface_default.xml
In "myjs.js" I try to load the cascade as shown in the example using my path to the cascade:
let classifier = new cv.CascadeClassifier();
classifier.load('../haar/haarcascade_frontalface_default.xml');
The function returns always false indicating the loading failure, independently if using the relative or the absolute path. Because of this I can't use the "detectMultiScale" function...
Can anyone help me please?