This simple code crashes (on Xcode/MacOSX): Eigen::SparseMatrix<float> sm(10, 10); sm.row(0); it crashes in XprHelper.h, line 53: explicit variable_if_dynamic(T v) { EIGEN_ONLY_USED_FOR_DEBUG(v); assert(v == T(Value)); } note that sm.col(0) works fine.
Indeed, patch coming soon. Meanwhile you can use sm.block(i,0,1,cols)
There appears to be a problem (only in 3.2) that SparseMatrix::row() will always be RowMajor, even if the original matrix is not. I guess Gael is quicker in resolving that. If you do, could you please re-activate the out-commented unit-tests in sparse_basic?
Fixed: https://bitbucket.org/eigen/eigen/commits/3fcd51f0b38a/ Changeset: 3fcd51f0b38a Branch: 3.2 User: ggael Date: 2015-03-13 14:13:58+00:00 Summary: Bug 980: fix taking a row (resp. column) of a column-major (resp. row-major) sparse matrix and add missing coeff/coeffRef members.
-- GitLab Migration Automatic Message -- This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/980.