[mlpack] arma::colvec behaving as arma::mat

Ryan Curtin ryan at ratml.org
Fri Mar 3 10:39:01 EST 2017

On Thu, Mar 02, 2017 at 10:38:37PM +0530, Lakshya Agrawal wrote:
> Is this a specified behavior or I am doing something wrong.
> It turns out that In the test files  arma::colvec and arma::rowvec
> are treated as arma::mat. So even arma::colvec is able to load matrices
> rather than just column vector.
> I have tried out something like this in "load_save_test.cpp"
> arma::mat A(5,5, fill::randu);
> arma::colvec coltest(A)
> It should throw an std::logic_error while doing this.
> But gives no error .In fact I also tried printing "coltest" and it gets
> printed same as A.
> I have tried Googling around on how to fix this error but nothing seems to
> work.
> Thank You !!!

Hi Lakshya,

I just saw the bug you opened:


I'll respond there.



Ryan Curtin    | "Exterminate all rational thought."
ryan at ratml.org |   - Bill Lee

More information about the mlpack mailing list