   A simplified C implemenation of Scale Invariant Feature Transform (SIFT)
                                by
         ZhenyuYe <z.ye@tue.nl> and Dongrui She <d.she@tue.nl>
-------------------------------------------------------------------------------
Disclaimer:
       THIS SOFTWARE IS PROVIDED ''AS IS'' AND WITHOUT ANY EXPRESS OR
       IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
       WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
-------------------------------------------------------------------------------

1. Overview:
This implementation is for the GPU assignment of the 5kk73 Embedded Computer
Architecture course. More details about the assignment can be found on the
assignment website: https://sites.google.com/site/5kk73gpu2011/.

1.1 Source Tree Layout
sift/
  +-README: this file
  +-CMakeLists.txt: CMake project file
  +-FindCUT.cmake: CMake module for finding CUDA SDK util library
  +-src/: folder that contains all the SIFT related source codes
  +-util/: folder that contains util codes, not directly related to SIFT

2. Compile:
CMake is used to compile the codes. It is recommend to perform a so-called
out-of-source build. To do that, first configure in a build directory:

$mkdir build
$cd build
$cmake ..

If some errors regarding CUDA or CUDA SDK occur, set CUDA_TOOLKIT_ROOT_DIR
to the CUDA toolkit path and NVSDKCOMPUTE_ROOT to the CUDA SDK path.

After that an executable eca-sift can be created by running:

$make

2.2 Controling Intermediate Output
If you want to have some intermediate output, change the preprocessor
definitions at the beginning of sfit.c:
* Define DUMP_OCTAVE if want to get the downscaled images for each octave
* Define DUMP_SCALESPACE if you want to get the whole scale space
* Define DUMP_DOG if you want to get all difference of Gaussians results

3. Run SIFT:
To run SIFT, use the following command:

$./eca-sift /path/to/input/image.pgm /path/to/output/image.ppm

A file called skey containing all keypoints is created upon successful
execution of the program.

4. Version Control with Mercurial
If you clone the code form a repository, you can use Mercurial (HG) for
version control.
For more information, please visit http://mercurial.selenic.com/guide/

Note: you can also use TortoiseHG, a very nice GUI for Mercurial.
