Boost logo

Ublas :

From: Michael Stevens (mail_at_[hidden])
Date: 2005-07-19 03:23:27


Hi Paul,

I am a bit confused. It would good if we could test against the pending Boost
1.33 release

On Sunday 17 July 2005 12:40, Paul C. Leopardi wrote:
> Hi again, all.
> I've been testing GluCat with Boost 1.32.0 and have noticed that GluCat now
> often produces incorrect results when it uses uBLAS. The same GluCat code
> when compile with Boost 1.31.0 produces correct results.
>
> Where is the best place to obtain a list of changes in uBLAS between Boost
> 1.31.0 and Boost 1.32.0? Is it CVS?

> I have used diff -rub to compare the two ublas directories Boost 1.31.0 vs
> Boost 1.32.0) and this results in a file with 32781 lines of raw
> differences. In order to understand what has gone wrong with GluCat/uBLAS I
> need to understand the changes in uBLAS at a higher level.

Raw diffs are probably not of any use due to code re-arrangements and a
multitude of minor syntax changes. The commit comments are more useful but
hard to extract out of CVS other then on a per file basis.

> It would also help if someone else could reproduce my results. GluCat
> 0.1.8, currently on SourceForge, is not compatible with Boost 1.32.0. I
> have attached to this message the relevant patches to GluCat 0.1.8 to
> enable it to compile with Boost 1.32.0. I call the patched version GluCat
> 0.1.9. The essential change in both configure and glucat.h is to remove the
> line containing
> #include <boost/numeric/ublas/config.hpp>
>
> Hopefully this investigation will come up with a set of assumptions made in
> GluCat which are violated in the Boost 1.32.0 version of uBLAS.

The most likely candidate for your problem is an uninitialised vector/matrix
element. uBLAS now NEVER initialises Dense Vector or Matrix elements. This
change happened with the cleanup of the Storage Concept.
Since I always derive my own vector/matrix types from uBLAS bases I find the
following idiom very handy to track down uninitialised elements.

        explicit FMVec(typename VecBase::size_type size) : VecBase(size)
        { // Sized constructor
                assign (ublas::scalar_vector<value_type>(size,
std::numeric_limits<value_type>::signaling_NaN()));
        }

 
> This may be useful for further uBLAS or uBLAS Wiki development.
I want to get as much of this 'release notes' type information into the uBLAS
Wiki. It would be nice to prepare people for the Boost 1.33 release.

All the best,

Michael

-- 
___________________________________
Michael Stevens Systems Engineering
34128 Kassel, Germany
Phone/Fax: +49 561 5218038
Navigation Systems, Estimation  and
                 Bayesian Filtering
    http://bayesclasses.sf.net
___________________________________