How to Use Intel® DAAL in Java Applications

签署人: Zhang Zhang

已发布:07/23/2015   最后更新时间:07/23/2015

Intel® Data Analytics Acceleration Library (Intel® DAAL) provides a Java API and the ease-of-use for Java programmers. This article discusses how to build and run applications with the Eclipse IDE (one of the most popular Java IDEs). The procedures outlined in this article should also be applicable to other Java IDEs. 

If you want to build and run Java applications from the command line, see instructions from Getting Started with Intel Data Analytics Acceleration Library.

Import Intel DAAL Java Packages

To make Intel DAAL classes and methods available to your application, we need to import necessary Intel DAAL packages. For example,


Configure Java Build Path

Java build path configuration can be accessed from Properties (right-clicking the project name).

  • Step 1. Make sure the Intel DAAL Java native library is included as part of source by setting Native library location to the directory containing JavaAPI.dll. The picture below shows an example on Windows. On Linux or OS X, set it to the directory containing
  • Step 2. Make sure the Libraries tab contains daal.jar on the build path, as shown below. 

Configure Run/Debug Settings

Run/Debug settings are also accessible from project Properties.

  • Step 1. Create a new launch configuration and give it a name.

  • Step 2. In the Edit Configuration pop-up window, make sure the Main class on the Main tab is properly set.

  • Step 3. Still in the Edit Configuration pop-up window, go to the Classpath tab and make sure daal.jar is included. 

  • Step 4. At last, go to the Environment tab and add a PATH environment variable and set its value to be the directories containing, respectively, DAAL runtime library, OpenMP runtime library, and Intel TBB runtime library. Here's an example on Windows:
    C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.0.110\windows\redist\intel64\daal;
    C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.0.110\windows\redist\intel64\compiler;
    C:\Program Files (x86)\IntelSWTools\compilers_and_libraries_2016.0.110\windows\redist\intel64\tbb\vc_mt

    Note on Linux and OS X, the environment variable to be added should be LD_LIBRARY_PATH; and similarly its value should be the paths containing the DAAL runtime library, the OpenMP runtime library, and the Intel TBB runtime library.

    Make sure Append environment to native environment is selected, and click Apply to save the changes.

These are the settings specifically necessary for using Intel DAAL in our Java project. We should now be able to build, run, and debug our project from within Eclipse. Refer to the online documentation to learn more about Intel DAAL.



英特尔的编译器针对非英特尔微处理器的优化程度可能与英特尔微处理器相同(或不同)。这些优化包括 SSE2、SSE3 和 SSSE3 指令集和其他优化。对于在非英特尔制造的微处理器上进行的优化,英特尔不对相应的可用性、功能或有效性提供担保。该产品中依赖于微处理器的优化仅适用于英特尔微处理器。某些非特定于英特尔微架构的优化保留用于英特尔微处理器。关于此通知涵盖的特定指令集的更多信息,请参阅适用产品的用户指南和参考指南。

通知版本 #20110804