Re: [eigen] operator= in SparseMatrixBase

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]


Hi,

I attached some simple code that results in the assertion.

Regards,
Jens

Gael Guennebaud wrote:
> Hi,
> 
> this is an internal error, so a bug in Eigen. In order to solve it,
> could you give me the piece of code at the origin of this assert (the
> line with the assignment and the declaration of each variable
> involved) ?
> 
> Cheers,
> Gael.
> 
> On Thu, Apr 30, 2009 at 10:42 AM, Jens Mueller <jens.k.mueller@xxxxxx> wrote:
> > Hi,
> >
> > I updated my trunk and hit an assertion. I'm getting the assertion "the
> > transpose operation is supposed to be handled in
> > SparseMatrix::operator=" defined on line 156 in SparseMatrixBase.h in
> > the assignGeneric method. And I don't get the rationale behind. The
> > assertion grantees that no transpose is needed saying the transpose is
> > handled in operator=. But in case a transpose is needed operator= just
> > passes the derived. I must be missing something.
> >
> > Regards,
> > Jens
> >
> >
> >
> 
#include <Eigen/Sparse>

int main() {
	Eigen::SparseMatrix<int, Eigen::RowMajor> m(10,10);

	for (int row = 0; row < m.rows(); ++row) {
		// the following line results in the assertion
		// only happens, if m is RowMajor
		Eigen::SparseVector<int> vec(m.row(row));
	}
}


Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/