working on Eigen 3.3

83 views
Skip to first unread message

Bob Carpenter

unread,
Oct 5, 2016, 6:09:31 PM10/5/16
to stan...@googlegroups.com
It's introducing a world of hurt.

The Householder code we use in log_determinant won't even
compile for double matrices in a simple test case due to ambiguities
in their Assginment template class. I asked about it
on StackOverflow because their mailing list is broken.

The Eigen_NumTraits.hpp code in rev/mat/fun and fwd/mat/fun
is broken for two reasons:

1. They changed how they deal with
printing number of digits (think I have the latter sorted) and
eliminated other Eigen::internal code we were leaning on and replaced
it with digits10() in Eigen::NumTraits.

2. They added more template arguments to general_matrix_vector_product
and general_matrix_matrix_product and I'm not even sure having the latter
delegate to the former is going to be workable given that they changed
the template parameters differently for both cases. I think I may be
able to fix both of these, but I'm currently blocked on our code not
compiling until we can sort out the Householder thing.

- Bob

Daniel Lee

unread,
Oct 12, 2016, 11:08:48 PM10/12/16
to stan-dev mailing list
Bob, I just ran against the latest version of their latest default branch and I'm getting past their compiler errors. I downloaded from here: https://bitbucket.org/eigen/eigen/src

I'm now getting runtime errors with something like:
./runTests.py test/unit/math/rev/mat/fun/cholesky_decompose_test.cpp

We'll need to figure out what behavior has changed and how to work around it safely.


Daniel



- Bob

--
You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Rob Trangucci

unread,
Oct 12, 2016, 11:20:41 PM10/12/16
to stan...@googlegroups.com
What are the runtime errors for cholesky_decompose.hpp?


Rob

Daniel Lee

unread,
Oct 12, 2016, 11:28:51 PM10/12/16
to stan-dev mailing list
Here's the full output:


~/dev/math2 (feature/0187-eigen-3.3)> ./runTests.py test/unit/math/rev/mat/fun/cholesky_decompose_test.cpp 
------------------------------------------------------------
make test/unit/math/rev/mat/fun/cholesky_decompose_test
make: `test/unit/math/rev/mat/fun/cholesky_decompose_test' is up to date.
------------------------------------------------------------
test/unit/math/rev/mat/fun/cholesky_decompose_test --gtest_output="xml:test/unit/math/rev/mat/fun/cholesky_decompose_test.xml"
Running main() from gtest_main.cc
[==========] Running 3 tests from 1 test case.
[----------] Global test environment set-up.
[----------] 3 tests from AgradRevMatrix
[ RUN      ] AgradRevMatrix.mat_cholesky
test/unit/math/rev/mat/fun/cholesky_decompose_test.cpp:183: Failure
Value of: LL_trans(0,0).val()
  Actual: inf
Expected: a.val()
Which is: 3
test/unit/math/rev/mat/fun/cholesky_decompose_test.cpp:184: Failure
Value of: LL_trans(0,1).val()
  Actual: -inf
Expected: b.val()
Which is: -1
test/unit/math/rev/mat/fun/cholesky_decompose_test.cpp:185: Failure
Value of: LL_trans(1,0).val()
  Actual: -inf
Expected: c.val()
Which is: -1
[  FAILED  ] AgradRevMatrix.mat_cholesky (0 ms)
[ RUN      ] AgradRevMatrix.exception_mat_cholesky
[       OK ] AgradRevMatrix.exception_mat_cholesky (0 ms)
[ RUN      ] AgradRevMatrix.mat_cholesky_1st_deriv
[       OK ] AgradRevMatrix.mat_cholesky_1st_deriv (538 ms)
[----------] 3 tests from AgradRevMatrix (538 ms total)

[----------] Global test environment tear-down
[==========] 3 tests from 1 test case ran. (538 ms total)
[  PASSED  ] 2 tests.
[  FAILED  ] 1 test, listed below:
[  FAILED  ] AgradRevMatrix.mat_cholesky

 1 FAILED TEST
test/unit/math/rev/mat/fun/cholesky_decompose_test --gtest_output="xml:test/unit/math/rev/mat/fun/cholesky_decompose_test.xml" failed
exit now (10/12/16 23:08:12 EDT)

Bob Carpenter

unread,
Oct 13, 2016, 4:46:39 PM10/13/16
to stan...@googlegroups.com
It's all on the stan-dev/math branch:

feature/0187-eigen-3.3

- Bob
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+u...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+u...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+u...@googlegroups.com.

Daniel Lee

unread,
Oct 13, 2016, 4:50:34 PM10/13/16
to stan-dev mailing list
Just pushed to the branch with an updated version of Eigen.

> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+unsubscribe@googlegroups.com.

> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+unsubscribe@googlegroups.com.

> For more options, visit https://groups.google.com/d/optout.
>
>
> --
> You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+unsubscribe@googlegroups.com.

> For more options, visit https://groups.google.com/d/optout.

--
You received this message because you are subscribed to the Google Groups "stan development mailing list" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stan-dev+unsubscribe@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages