Xml and yml read
Hi,
I have saved two files one in xml and the other in yml using same method void ParametreOperation::write(cv::FileStorage& fs) const . Now I want to read it :
#include <opencv2/opencv.hpp>
#include <iostream>
#include <map>
#include <fstream>
using namespace cv;
int main (int argc,char **argv)
{
FileStorage fsx("test.xml", FileStorage::READ);
FileStorage fsy("test.yml", FileStorage::READ);
}
I have got an exception for fsy :
OpenCV Error: Parsing error (test.yml(5): Incorrect indentation) in icvYMLParseValue, fi le ......\modules\core\src\persistence.cpp, line 1327
What's wrong in this file ?
Thanks you for your help
I am not sure, have you saved it in yml format, or it is hand-made (written by you or someone else)? Try to open it with another yml library...
thanks for your answer To save it
I can read my data using xml data without problem. It looks like a bug in yml parser. But I'm not sure. have you got same exception with my data?
I have not tested, not enough time ... :(