You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Only one dependency can be added per platform, meaning that you cannot add native dependencies to both `linux-x86_64` and
@@ -135,20 +136,20 @@ For Ubuntu 24.04, you can install them with the following command:
135
136
In some cases, it might be preferable to add a single dependency that includes transitively all the artifacts
136
137
required to run TensorFlow Java on any [supported platforms](README.md#individual-dependencies)
137
138
138
-
-`tensorflow-core-platform`: Includes `tensorflow-core-api`, plus native artifacts for `linux-x86_64`, `linux-x86_64-arm64`, `macosx-arm64`and `windows-x86_64`
139
+
-`tensorflow-core-platform`: Includes `tensorflow-core-api`, plus native artifacts for `linux-x86_64`, `linux-arm64`, and `macosx-arm64`
139
140
140
141
For example, to run TensorFlow Java on any CPU platform for which a binary is being distributed by this project, you can
TensorFlow-Java is built on top of the native TensorFlow library, and uses [JavaCPP](https://github.com/bytedeco/javacpp)
203
+
to call that library which in turn uses the Java Native Interface (JNI). In [Java 24 and newer](https://openjdk.org/jeps/472)
204
+
uses of JNI trigger a warning of the form:
205
+
```
206
+
WARNING: A restricted method in java.lang.System has been called
207
+
WARNING: java.lang.System::loadLibrary has been called by org.bytedeco.javacpp.Loader in an unnamed module (file:/.../.m2/repository/org/bytedeco/javacpp/1.5.12/javacpp-1.5.12.jar)
208
+
WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
209
+
WARNING: Restricted methods will be blocked in a future release unless native access is enabled
210
+
```
211
+
This is expected, and adding the `--enable-native-access=ALL-UNNAMED` flag to enable JNI will suppress it. In a future
212
+
Java version this warning may be turned into an error and the flag will be required to use TensorFlow-Java.
213
+
199
214
## TensorFlow/Java Version Support
200
215
201
216
This table shows the mapping between TensorFlow, TensorFlow Java and minimum supported Java versions.
202
217
203
218
| TensorFlow Java Version | TensorFlow Version | Minimum Java Version |
0 commit comments