Skip to content
This repository was archived by the owner on Dec 31, 2020. It is now read-only.

Commit 2397581

Browse files
authored
Update README.md
1 parent 31fb4fc commit 2397581

File tree

1 file changed

+15
-11
lines changed

1 file changed

+15
-11
lines changed

README.md

+15-11
Original file line numberDiff line numberDiff line change
@@ -3,26 +3,30 @@
33

44
## Building
55

6-
### Build TensorFlow
7-
8-
Please refer to TensorFlow for general instructions.
9-
10-
Additional steps are required to use the new TensorFlow Java library. Here's how to
11-
build and install the library to the local Maven repository:
12-
6+
## Build Example
7+
A set of examples are provided as a ready-to-run JAR file. To build:
138
```sh
14-
$ cd $TENSORFLOW_HOME
15-
$ bazel build //tensorflow/java:tensorflow //tensorflow/java:pom
16-
mvn install:install-file -Dfile=bazel-bin/tensorflow/java/libtensorflow.jar -DpomFile=bazel-bin/tensorflow/java/pom.xml
9+
$ mvn clean package
1710
```
1811

12+
The build file is located at: `flink-tensorflow-examples/target/flink-tensorflow-examples_2.11-0.1-SNAPSHOT.jar`
13+
1914
### Run Tests
2015
The project uses JUnit and the Maven Surefire plugin. Be sure to add the
2116
the native tensorflow library to the Java native library path.
2217

2318
To run the tests:
2419

2520
```sh
26-
$ mvn surefire:test -DargLine="-Djava.library.path=$TF_HOME/bazel-bin/tensorflow/java"
21+
$ mvn surefire:test
2722
```
2823

24+
## Running the Examples
25+
_Prerequisite: install and run Apache Flink 1.2._
26+
27+
### Inception
28+
1. Download the inception5h model.
29+
2. Launch the inception demo:
30+
```
31+
$ flink run -c org.apache.flink.contrib.tensorflow.examples.inception.Inception flink-tensorflow-examples/target/flink-tensorflow-examples_2.11-0.1-SNAPSHOT.jar <path-to-inception5h> <path-to-image-files>
32+
```

0 commit comments

Comments
 (0)