Re: [buildcheapeeg] BWView

From: Doug Sutherland (wearable_at_earthlink.net)
Date: 2002-03-01 08:40:42


Hi Dave,

> I have spent this evening trying to resolve the display
> disparity between Jim-P's binary version and mine

What is the display disparity? Did you try adjusting the
brightness, this is key, as outlined in Jim's tutorial.
When I first tried BWView all I saw was darkness, with
just a bit of grey here and there. From the tutorial:

When the data first appears, you probably won't see
much. You need to start by adjusting the brightness.
Try 'b9' or 'b0' and work down from there. You'll
also probably need to adjust the gain for the signal
level display so that you can see it properly. Use
's' and then digits until that looks okay.

> I also have both gcc 2.95 and 3.0 installed on my system

Youch.

> it really looks like a completely new data set is being
> displayed

Perhaps the settings need to be tweaked per the tutorial.

> I read the FFTW docs, looking for references to the 64-bit
> library you mentioned. Except for the mention of different
> integer sizes, I do not see where they make a distinction
> between 32-bit/64-bit compilations. Can this really be the
> problem? I would think your build and mine are from the
> same vanilla setup -- ./configure, make, make install.

According to Jim's instructions, when you build FFTW ...

./configure --enable-float --enable-i386-hacks

This is required because I use the 32-bit floating
point version of the library, rather than the
default 64-bit one.

Dave, see this section of the FFTW FAQ:
http://www.fftw.org/doc/fftw_6.html

By default, FFTW is compiled for double-precision
transforms. To work in single precision rather than
double precision, #define the symbol FFTW_ENABLE_FLOAT
in fftw.h (in the fftw directory) and (re)compile FFTW.
These libraries should be linked with any program that
uses the corresponding transforms. The required header
files, fftw.h and rfftw.h, are located in the fftw and
rfftw directories respectively; you may want to put
them with the libraries, or wherever header files
normally go on your system.

A note for Jim: there is apparently a way to install FFTW
for BOTH single and double precision on the same machine,
as long as you don't use both in the SAME program.

http://www.fftw.org/doc/fftw_6.html#SEC69

It says that both can be installed like this:

./configure --enable-type-prefix [ other options ]
make
make install
make clean
./configure --enable-float --enable-type-prefix [ other options ]
make install

Also see this section on pentium hacks (enable-i386-hacks)
http://www.fftw.org/doc/fftw_6.html#SEC70

In principle, these hacks are no longer required under gcc
versions 2.95 and later, which automatically align the stack
correctly (see -mpreferred-stack-boundary in the gcc manual).
However, we have encountered a bug in the stack alignment of
versions 2.95.[012] that causes FFTW's stack to be misaligned
under some circumstances. The configure script automatically
detects this bug and disables gcc's stack alignment in favor
of our own hacks when --enable-i386-hacks is used. The fftw_test
program outputs speed measurements that you can use to see if
these hacks are beneficial.

Dave, did you try running the FFTW tests? After installation
just do make check ...

> So... now the favor from both of you. I have uploaded two
> binaries to my web site (these are Linux-only, folks). Could
> you run these on your systems and see if your results match
> the original binary that you, Jim, included in your release?

The binaries will only work if we are on same major kernel
revision and same glibc version. Jim's binary would not
run on my system because I'm using Glibc 2.1.3 and Jim is
using Glibc 2.2. So what kernel and Glibc version are you
using, and what version of the compiler?

> So I recompiled FFTW so that it created the sharable libraries,
> and compiled a new BWView binary (bwview-dave-shared-fftw).
> Notice the size difference.

Good stuff, we should be working on shared libraries.

> In order to compile the sharable libs, you'll need to
> make clean
> ./configure --enable-shared
> make
> make install
> and then 'mk' to get a new BWView binary.

Cool, I will try making mine a shared version of FFTW.

> If bwview-dave-shared-fftw works, but bwview-dave-static-fftw
> does not, then we have identified FFTW as the problem.

I still don't understand what the disparity is. I will try
your binaries but I'm guessing they will screech to a halt
due to incompatibilites in libraries.

-- Doug



This archive was generated by hypermail 2.1.4 : 2002-07-27 12:28:39 BST