Skip to content

Instantly share code, notes, and snippets.

@abarya
Last active February 16, 2018 14:27
Show Gist options
  • Save abarya/490789d9716d0f07f3fbab771e96548a to your computer and use it in GitHub Desktop.
Save abarya/490789d9716d0f07f3fbab771e96548a to your computer and use it in GitHub Desktop.
This gist contains the important points related to functional programming in javascript.

A smartbeing project that contains the implementation of the person-recognition module for the smart home device Whohoo...

Setting up the project

  1. Fork and clone this repo within your home folder.
  2. The second step is to download and install the fftw3 library from here which is used for Fourier computation.
    • Download the latest version(3.3.7) of fftw3 library.
    • Navigate to fftw-3.3.7/ and run the following comands:
      ./configure
      make
      sudo make install
      
    • This will install the fftw3 library on your system.
  3. Also, make sure that you have opencv installed on your system.
  4. In this project, for calculating GIST descriptor, LibGIST has been used. Now, you need to configure LibGIST project that has been supplied with my project so as tell it where exactly fftw3 is installed on your system.
    • Open the file path/to/project/LibGIST/CmakeLists.txt and look for the line set(FFTW3_DIR /home/arya/fftw-3.3.7) in it. Here, change the path to the location where you installed the fftw3 library.
    • Now, change the directory to LibGIST and create a build directory inside the folder LibGIST by running:
      cd LibGIST
      mkdir build
      
    • After this, open the file path/to/project/LibGIST/src/CMakeLists.txt and look for the line install(TARGETS gist DESTINATION /home/arya/Documents/sb_intern/LibGIST/build) and change the path to path/to/project/LibGIST/build.
    • Now, run the following commands to build LibGIST on your machine as well as to install to install the shared library libgist:
      cd build
      cmake ..
      make
      sudo make install
      
  5. Now, open the file path/to/project/person_recog/CMakeLists.txt and look for the lines link_directories(/home/arya/Documents/sb_intern/LibGIST/build) and include_directories(/home/arya/Documents/sb_intern/LibGIST/include) and change the path to /path/to/project/LibGIST/build and /path/to/project/LibGIST/include.
  6. Navigate to the directory person_recog and create a folder and name it build. Now , run the following commands:
    cd build
    cmake ..
    make
    

Now, everything is set up :).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment