Boost logo

Ublas :

Subject: Re: [ublas] [bindings] gbmv error
From: Michael Lehn (michael.lehn_at_[hidden])
Date: 2012-10-10 11:12:56


I think what you guys really need is an external (F77)BLAS interface so that
you can use the BLAS test suite for testing uBLAS and the bindings.

Cheers,

Michael

Am 10.10.2012 um 16:56 schrieb Rutger ter Borg:

>
> Hello all,
>
> after some further testing of the gbmv blas routine, I have encountered something that is a bug, but I am a bit puzzled by it. The tests are doing basic multiplying, see below. Matrix is 10x10 with contents shown, vector V is a unit vector.
>
> I'm puzzled, because BLAS doesn't return an error, the numbers are really close to what they should be, and the errors only occur if column_major banded matrices are used, and all arguments to the backend seem to make sense. See the ublas/bindings comparison below 'WRONG'.
>
> I've attached the test case, and I've committed the necessary upgrades to bindings::trans.
>
> Any ideas?
>
> Cheers,
>
> Rutger
>
>
>
>
> THIRD TEST CASE: banded matrices with column major storage
>
> row 0 [10](0,0,0,0,0,0,0,0,0,0)
> row 1 [10](1,1,1,0,0,0,0,0,0,0)
> row 2 [10](0,1,1,1,0,0,0,0,0,0)
> row 3 [10](0,0,1,1,1,0,0,0,0,0)
> row 4 [10](0,0,0,1,1,1,0,0,0,0)
> row 5 [10](0,0,0,0,1,1,1,0,0,0)
> row 6 [10](0,0,0,0,0,1,1,1,0,0)
> row 7 [10](0,0,0,0,0,0,1,1,1,0)
> row 8 [10](0,0,0,0,0,0,0,1,1,1)
> row 9 [10](0,0,0,0,0,0,0,0,1,1)
>
> gemv: CORRECT
> ublas: [10](0,3,3,3,3,3,3,3,3,2)
> bindings: [10](0,3,3,3,3,3,3,3,3,2)
>
> gbmv: WRONG
> ublas: [10](0,3,3,3,3,3,3,3,3,2)
> bindings: [10](1,3,3,2,3,3,3,3,3,2)
>
> T R A N S P O S E
>
> gemv with trans: CORRECT
> ublas: [10](1,2,3,3,3,3,3,3,3,2)
> bindings: [10](1,2,3,3,3,3,3,3,3,2)
>
> gbmv with trans: WRONG
> ublas: [10](1,2,3,3,3,3,3,3,3,2)
> bindings: [10](1,3,3,2,3,3,3,3,3,2)
>
>
> FOURTH TEST CASE: banded matrices with row major storage
>
> row 0 [10](0,0,0,0,0,0,0,0,0,0)
> row 1 [10](1,1,1,0,0,0,0,0,0,0)
> row 2 [10](0,1,1,1,0,0,0,0,0,0)
> row 3 [10](0,0,1,1,1,0,0,0,0,0)
> row 4 [10](0,0,0,1,1,1,0,0,0,0)
> row 5 [10](0,0,0,0,1,1,1,0,0,0)
> row 6 [10](0,0,0,0,0,1,1,1,0,0)
> row 7 [10](0,0,0,0,0,0,1,1,1,0)
> row 8 [10](0,0,0,0,0,0,0,1,1,1)
> row 9 [10](0,0,0,0,0,0,0,0,1,1)
>
> gemv: CORRECT
> ublas: [10](0,3,3,3,3,3,3,3,3,2)
> bindings: [10](0,3,3,3,3,3,3,3,3,2)
>
> gbmv: CORRECT
> ublas: [10](0,3,3,3,3,3,3,3,3,2)
> bindings: [10](0,3,3,3,3,3,3,3,3,2)
>
> T R A N S P O S E
>
> gemv with trans: CORRECT
> ublas: [10](1,2,3,3,3,3,3,3,3,2)
> bindings: [10](1,2,3,3,3,3,3,3,3,2)
>
> gbmv with trans: CORRECT
> ublas: [10](1,2,3,3,3,3,3,3,3,2)
> bindings: [10](1,2,3,3,3,3,3,3,3,2)
>
>
> <test_gbmv.cpp>_______________________________________________
> ublas mailing list
> ublas_at_[hidden]
> http://lists.boost.org/mailman/listinfo.cgi/ublas
> Sent to: michael.lehn_at_[hidden]