0
$\begingroup$

Rosanswers logo

Hi All I just tried the new face recognition package but when i run Fserver i get the following error

[ INFO] [1325746855.901582077]: Could not load Haar cascade Face detection classifier in 'haarcascade_frontalface_alt.xml'.

I am using Ubuntu 10.4 32 bit and ros electric with vision opencv installed from debs


Originally posted by Peter Heim on ROS Answers with karma: 215 on 2012-01-04

Post score: 1


Original comments

Comment by tfoote on 2012-01-04:
Please post more information. There is not enough information here to reproduce your effrots. See http://www.ros.org/wiki/Support

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

Hi,

Fserver requires haarcascade_frontalface_alt.xml to be in the same directory as you run the Fserver. The file was missing in the package, but now It has been uploaded in the repository in the face_recognition directory.

Cheers, Pouyan


Originally posted by Pouyan with karma: 143 on 2012-01-05

This answer was ACCEPTED on the original site

Post score: 2


Original comments

Comment by joq on 2012-01-05:
No problem, I was just recommending a more general solution in a future release.

Comment by Pouyan on 2012-01-05:
Jog, Thanks for your comments, will consider that for the future, but for now cmd works.

Comment by Pouyan on 2012-01-05:
When you use cmd="node", the working directory is face_recognition/bin. If you put the files in the bin directory, should be no problem.

Comment by Peter Heim on 2012-01-05:
I just tried it and i cant get it to work it shows a error when i use the directory if i use node or ROS_HOME and put the file in those locations i get the file not found error

Comment by joq on 2012-01-05:
That is really not the recommended way to use roslaunch. I am not even sure it works. Have you tried it?

Comment by Pouyan on 2012-01-05:
As mentioned above, the program searches for its input files in its working directory which is not necessarily the package directory. In 'roslaunch', you can set the working directory using 'cwd' attribute to point to the directory in which necessary input files are placed.

Comment by joq on 2012-01-05:
Depending on the current directory being the package directory is very unfriendly for people using roslaunch. Perhaps a future release might provide a more flexible access mechanism?

Comment by Peter Heim on 2012-01-05:
Running from the installation directory was the key the server started and i was able to acquire a face Thanks

Comment by Pouyan on 2012-01-05:
You might also wish to put the data folder (containing sample pictures) and the train.txt file(which list the training examples) in the same directory. As all these are in the face_recognition directory by default, simply try : 1-roscd face_recognition 2-rosrun face_recognition Fserver

Comment by Pouyan on 2012-01-05:
rosmake in not necessary again. you should just run the Fserver from the directory in which haarcascade_frontface_alt.xml is placed. For example : 1- copy haarcascade_frontface_alt.xml to /home/new_dir 2-cd /home/new_dir 3-rosrun face_recognition Fserver. Let me know if it works :)

Comment by Peter Heim on 2012-01-05:
Hi Just updated and did a rosmake the new files is in the face_recognition directory but i still get the same error

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.