1 | initial version |
if you're using opencv3 (it won't work with 2.4), you can do it easily like this:
String xml = "<xml> ....";
FileStorage fs( xml, FileStorage::MEMORY );
CascadeClassifier cascade;
cascade.read( fs.getFirstTopLevelNode() );
2 | No.2 Revision |
if you're using opencv3 a cascade made from train_cascade
(it won't work with 2.4), the older ones from haar_training
), you can do it easily like this:
String xml = "<xml> ....";
FileStorage fs( xml, FileStorage::MEMORY );
CascadeClassifier cascade;
cascade.read( fs.getFirstTopLevelNode() );