Fork me on GitHub

ND4J Backends: How They Work

ND4J works atop so-called backends, or linear-algebra libraries, such as Native nd4j-native and nd4j-cuda-7.5 (GPUs), which you can select by pasting the right dependency into your project’s POM.xml file.

A Java ServiceLoader, which is baked into the language itself, tells Java that the backend exists. It’s not necessary to concern yourself with how ND4J backends load and perform other basic functions, but you can explore how ND4J loads and selects backends, according to your OS, here.

The core configurations for each backend are specified in a properties file.

Alt text

A few more points: