Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

matlab won't be able to read your yml files, but chances are better with a simple .csv format here, so:

ofstream os("my.csv");
for (int i = 1; i <= 6; i++ )
        sprintf_s(filename, "VocabularyLBP/Dictionary%d.yml", i);
        Mat feature;
        FileStorage fs(filename, FileStorage::READ);
        fs["vocabulary"] >> feature;
        feature.convertTo(feature, CV_32FC1); 
        feature = feature.reshape(1, 1);

        os << format(feature,  cv::Formatter::FMT_CSV);