Curvelets

From FarsightWiki
Jump to: navigation, search

Curvelets is a powerful preprocessing algorithm with a difficult build instruction.

Contents

Building Curvelets

Curvelets depends on two separate versions of the FFTW library. You will need to follow the instructions in both of these sections.

FFTW 2.1.5

Included in the Farsight repository is a zip file containing the source for FFTW 2.1.5. You can find it in:

  • Trunk
    • Tracing
      • Preprocessing
        • CurveletFiltering
          • fdct_wrapping_cpp
            • src
              • fftw-2.1.5.zip

Yes we know it's buried. We're sorry. Make a new FFTW directory in your build structure and extract it there.

Using Cmake, configure.

Change CMAKE_INSTALL_PREFIX to a directory with no spaces in it.

Generate.

Open the resulting vcproj, and build.

Make sure you're in release mode, and build the INSTALL project. This will place the FFTW 2.1.5 libraries in the directory you specified.

Now, open up FARSIGHT in Cmake.

Configure with BUILD_Preprocessing on to create the following variables:

  • FFTW_INCLUDE_PATH - point this to the include subdirectory in the fftw install path CMAKE_INSTALL_PREFIX/include
  • FFTW_LIB_SEARCH - point this to CMAKE_INSTALL_PREFIX/lib/libfftw215.lib
  • FFTW_THREADS_LIB_SEARCH - point this to CMAKE_INSTALL_PREFIX/lib/libfftw215_threads.lib
  • RFFTW_LIB_SEARCH - point this to CMAKE_INSTALL_PREFIX/lib/librfftw215.lib

FFTW 3.3

The FFTW 3.3 libraries are already precompiled, we just need to download and do a bit of linking wizardy.

The best source for these libraries is fftw.org. Download the zip file with the latest precompiled 64-bit DLLs and extract them somewhere semi-permanent, again with no spaces in the directory listing.

Open up the Visual Studio command line: Start->All Programs->Microsoft Visual Studio 2008->Visual Studio Tools->Visual Studio 2008 64-bit Command Line

Browse to the directory with the extracted FFTW libraries.

Call:

  • lib /machine:x64 /def:libfftw3-3.def
  • lib /machine:x64 /def:libfftw3f-3.def
  • lib /machine:x64 /def:libfftw3l-3.def

That should have spawned a bunch of .lib files in that directory.

Go back to FARSIGHT in Cmake.

Edit the FFTW3_LIB_SEARCH directories to point to the corresponding lib files, and set FFTW3_INCLUDE_PATH to the directory containing them all.

Other Build Steps

Once the above sections are completed, everythign should be linked properly. Cross your fingers and hit Configure/Generate, then enjoy your new curvelet-enabled Farsight!

Personal tools