Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

needs quite some shuffeling, but doable:

vector<vector<mat>> vvm = ...
Mat res; // initially empty

for (size_t i=0; i<vvm.size(); i++) {
    Mat row; // empty
    for (size_t j=0; j<vvm[0].size(); j++) {
        Mat m = vvm[i][j];
        row.push_back(m.resize(1,1)); // 1 x 100
    }
    res.push_back(row.reshape(1,1)); //1 x 2000
}