MPTK 0.5.8 Installation on Mac OS X 10.6.4

Since June 24, 2010, Matching Pursuit Toolkit version 0.5.8 has been available. So today I decided to upgrade from 0.5.6. In the process I ran into some curious issues. First a little background information on my computer:

My machine, a.k.a., the “Sparse Approximation Station (SpASt)”, is a small theater-sized iMac with a 3.33 GHz Intel Core 2 Duo processor, 8 GB ram, and a 2 terabyte hard drive. I am running Snow Leopard 10.6.4.


I was happy to see that there exists a binary DMG package, so I
downloaded it and installed. Several binaries (mpd, mpf, mpr, …) were
installed in “/usr/local/bin”, along with a “path.xml” file necessary
for MPTK to find the necessary atom plugins, and several libraries. However, there are two problems:

  1. Instead of setting my environment variable as it describes in the help, I had to set it to (in my “.bash_profile” in my home directory):

    export MPTK_CONFIG_FILENAME=”/usr/local/mptk/path.xml”

  2. The binaries are built on a 32 bit machine, and thus won’t work with my 64 bit libsndfile or fftw installations.

So, I downloaded the MPTK 0.5.8 source code, ran the following code:

cmake ../MPTK-Source-0.5.8/

and edited the file “CMakeCache.txt” in the following ways

//Enable building Matlab MEX files.
BUILD_MATLAB_MEX_FILES:BOOL=ON

//Flags used by the compiler during all build types.
CMAKE_CXX_FLAGS:STRING=-arch x86_64

//Flags used by the compiler during all build types.
CMAKE_C_FLAGS:STRING=-arch x86_64

//Build architectures for OSX
CMAKE_OSX_ARCHITECTURES:STRING=x86_64

Everything compiled to 100%! Never before have I seen that with MPTK, with that mysterious 73% finished before errors were thrown.
Now my data is decomposing, and the MATLAB utilities are working! (Don’t forget to add to your path in MATLAB, which I do with the following command: path(path,’/usr/local/mptk/matlab’);) Progress is so nice!

Thank you to Boris Mailhé for pointing out the correct path for the MPTK environment.

For Google and other persons searching for my particular error messages, here they are:

mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC++.6.2.0.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC++.6.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC++.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC.8.2.0.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC.8.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libFLAC.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libogg.0.5.3.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libogg.0.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libogg.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libsndfile.1.dylib’ shared library.
mptk WARNING — MP_Dll_Manager::load_dll – No registry symbol in ‘/usr/local/lib/libsndfile.dylib’ shared library.
mptk ERROR — MPTK_Env_c::load_environment() – No block type was loaded,
even though plugins were found in the dll_directory ‘/usr/local/lib’
specified by the configuration file ‘/usr/local/bin/path.xml’
mptk INFO — – The most common reason is a configuration file which does not match the installed version of MPTK
mptk ERROR — MPTK_Env_c::load_environment_if_needed() – Could not load the MPTK environment.
mptk INFO — MPTK_Env_c::load_environment_if_needed() – The most common
reason is a missing or erroneous MPTK_CONFIG_FILENAME variable.
mptk INFO — MPTK_Env_c::load_environment_if_needed() – The current value is MPTK_CONFIG_FILENAME = [/usr/local/bin/path.xml].
mptk INFO — – The MPTK environment can be specified either by:
mptk INFO — – a) setting the MPTK_CONFIG_FILENAME environment variable
mptk INFO — – using e.g. ‘setenv MPTK_CONFIG_FILENAME <path_to_config_file.xml>’
mptk INFO — – in a shell terminal, or
mptk INFO — – ‘setenv(‘MPTK_CONFIG_FILENAME’,'<path to configuration file.xml>’)
mptk INFO — – from the Matlab command line
mptk INFO — – b) using the -C <path_to_configfile.xml> option in many MPTK command line utilities.

2 thoughts on “MPTK 0.5.8 Installation on Mac OS X 10.6.4

  1. Hi Igor,
    The build itself takes less than one minute. But parsing and understanding the different errors that were created by the fine details particular to my machine took me about five hours. (Hopefully someone having the same errors will find my help helpful.) The maintainers and distributors of MPTK are extremely helpful, as can be seen by the near immediacy of answers to my questions on the forum at the MPTK website. Once I had the correct compiler flags, I watched “make” produce everything with only a few warnings. So satisfying was this experience that I did a “make clean” and “make” again just to see. And then a final triumphant “sudo make install”.

    Like

Leave a comment