Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit a15a791

Browse files
Tweaks
Signed-off-by: AlexDBlack <blacka101@gmail.com>
1 parent 1dee8b8 commit a15a791

File tree

1 file changed

+15
-11
lines changed

1 file changed

+15
-11
lines changed

‎cpu.md‎

Lines changed: 15 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,22 +6,24 @@ layout: default
66
redirect_from: "/cpu"
77
---
88

9+
# ND4J - CPU (nd4j-native) AVX Configuration
910

1011
### What is AVX, and why does it matter?
1112

12-
AVX (Advanced Vector Extensions) is a set of CPU instructions for accelerating numerical computations.
13-
AVX only applies to nd4j-native (CPU) backend for x86 devices, not GPUs and not ARM/PPC devices.
13+
AVX (Advanced Vector Extensions) is a set of CPU instructions for accelerating numerical computations. See [Wikipedia](https://en.wikipedia.org/wiki/Advanced_Vector_Extensions) for more details.
1414

15-
Why AVX matters: performance.
15+
Note that AVX only applies to nd4j-native (CPU) backend for x86 devices, not GPUs and not ARM/PPC devices.
1616

17-
You want to use the highest level of AVX supported by your system.
17+
Why AVX matters: performance. You want to use the version of ND4J compiled with the highest level of AVX supported by your system.
1818

19-
AVX support - summary:
19+
20+
AVX support for different CPUs - summary:
2021
* Most modern x86 CPUs: AVX2 is supported
2122
* Some high-end server CPUs: AVX512 may be supported
2223
* Old CPUs (pre 2012) and low power x86 (Atom, Celeron): No AVX support (usually)
2324

24-
AVX is backward compatible, so it's possible run a generic x86 or AVX2 binary on a system supporting AVX512.
25+
AVX is backward compatible, so for example it's possible run a generic x86 or AVX2 binary on a system supporting AVX512.
26+
However it is not possible to run
2527

2628
Note on current snapshots (and in future releases, after 1.0.0-beta5) you may get a warning as follows, if AVX is not configured optimally:
2729
```
@@ -35,20 +37,22 @@ o.n.l.c.n.CpuNDArrayFactory - **************************************************
3537

3638
### Configuring AVX in ND4J/DL4J
3739

38-
Defaults:
40+
As noted earlier, for best performance you should use the version of ND4J that matches your CPU's supported AVX level.
41+
42+
ND4J defaults configuration (when just including the nd4j-native or nd4j-native-platform dependencies without maven classifier configuration):
3943
* 1.0.0-beta5 and earlier: "generic x86" (no AVX) is the default for nd4j/nd4j-platform dependencies
4044
* Current snapshots and later versions of ND4J: AVX2 is the default
4145

4246

4347
To configure AVX2 and AVX512, you need to specify a classifier for the appropriate architecture.
4448

45-
The following binaries are provided for x86 architectures:
49+
The following binaries (nd4j-native classifiers) are provided for x86 architectures:
4650
* Generic x86 (no AVX): `linux-x86_64`, `windows-x86_64`, `macosx-x86_64`
4751
* AVX2: `linux-x86_64-avx2`, `windows-x86_64-avx2`, `macosx-x86_64-avx2`
4852
* AVX512: `linux-x86_64-avx512`
4953

5054

51-
Example: AVX2 on Windows (Maven pom.xml)
55+
**Example: Configuring AVX2 on Windows (Maven pom.xml)**
5256
```
5357
<dependency>
5458
<groupId>org.nd4j</groupId>
@@ -65,7 +69,7 @@ Example: AVX2 on Windows (Maven pom.xml)
6569
```
6670

6771

68-
Example: AVX512 on Linux (Maven pom.xml)
72+
**Example: Configuring AVX512 on Linux (Maven pom.xml)**
6973
```
7074
<dependency>
7175
<groupId>org.nd4j</groupId>
@@ -81,4 +85,4 @@ Example: AVX512 on Linux (Maven pom.xml)
8185
</dependency>
8286
```
8387

84-
Note that you need *both* dependencies - with and without the classifier.
88+
Note that you need *both* nd4j-native dependencies - with and without the classifier.

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /