Direct Graphical Models  v.1.5.3

Curently the DGM library may be installed only on Windows machines. It is also based on OpenCV library v.3.3.0.
In order to build the DGM library, the OpenCV library should be built and installed first.

Installing OpenCV

  1. Download the OpenCV library from sourcefourge
  2. Install the OpenCV library. You may follow the short installation guide or a deteiled installation in Windows guide

Installing DGM

  1. Download the DGM library from Project X Research
  2. Unzip it to your local folder (for example to disk C:\, so the library path will be C:\DGM\)
  3. In case you want to build the library follow these instructions, otherwise - skip this step
    1. Download and install CMake
    2. Run cmake-gui.exe
    3. In the “Where is the source code” field choose the DGM source directory: C:\DGM
      In the “Where to build the binaries” field choose directory for VS compiled DGM: C:\DGM\builds
    4. Press Configure button and choose Visual Studio 14 2015 or Visual Studio 14 2015 Win64 (or whatever) as building environment
    5. Be sure that the OpenCV_DIR is pointing to the OpenCV build directory (e.g. C:\OpenCV\build), where OpenCVConfig.cmake file is located
    6. Press one more time Configure and then Generate, so the VS project will be generated in the C:\DGM\builds
    7. Open the solution (C:\DGM\builds\DGM.sln file)
    8. Build ALL_BUILD and INSTALL projects first for Debug and then for Release configuration. That will copy DGM headers, binaries and demonstration applications to C:\DGM\builds\install
    9. (Optionally) you can copy the content of the C:\DGM\builds\install to another folder, e.g. C:\DGM\build
  4. Specify the following paths and library
    1. Add to Configuration Properties -> C/C++ -> General -> Additional Include Directories the path C:\DGM\build\include
    2. Add to Configuration Properties -> Linker -> General -> Additional Library Directories the path C:\DGM\build\lib for both Release and Debug configurations
    3. Add to Configuration Properties -> Linker -> Input -> Additional Dependencies the libraries dgm151.lib, fex151.lib, vis151.lib and dgm151d.lib, fex151d.lib, vis151d.lib for Release and Debug configurations accordingly
  5. Copy the DGM dll files dgm151.dll, dgm151d.dll and fex151.dll, fex151d.dll and vis151.dll, vis151d.dll from C:\DGM\build\bin to your project's Relese and Debug folders.