aboutsummaryrefslogtreecommitdiffhomepage
path: root/tensorflow/java/BUILD
diff options
context:
space:
mode:
authorGravatar Asim Shankar <ashankar@google.com>2016-12-05 16:02:11 -0800
committerGravatar TensorFlower Gardener <gardener@tensorflow.org>2016-12-05 16:29:50 -0800
commit6de74f8502c0fae1a7ddeeb5c02496e2452774f5 (patch)
tree698ff39fb3e1b2a97118e4cbed0a356a038818fd /tensorflow/java/BUILD
parent8f332c0aae50563726d36cc809548dabd02bab31 (diff)
Java: Add a Graph class and the ability to import/export GraphDefs.
Also link in op definitions into libtensorflow-jni.so Another step in the journey that is #5. Change: 141113176
Diffstat (limited to 'tensorflow/java/BUILD')
-rw-r--r--tensorflow/java/BUILD29
1 files changed, 29 insertions, 0 deletions
diff --git a/tensorflow/java/BUILD b/tensorflow/java/BUILD
index 69766caf3d..d130a3d8a0 100644
--- a/tensorflow/java/BUILD
+++ b/tensorflow/java/BUILD
@@ -13,6 +13,35 @@ java_library(
)
java_test(
+ name = "GraphTest",
+ size = "small",
+ srcs = ["src/test/java/org/tensorflow/GraphTest.java"],
+ data = [":test_graph_def"],
+ test_class = "org.tensorflow.GraphTest",
+ deps = [
+ ":tensorflow",
+ "//external:junit",
+ ],
+)
+
+# Temporary targets to assist with unittests till the Java API becomes
+# expressive enough. Delete this target and corresponding python source code
+# when the Java API can construct graphs.
+genrule(
+ name = "test_graph_def",
+ outs = [":test_graph_def.data"],
+ cmd = "$(location :graphdef) $@",
+ tools = [":graphdef"],
+)
+
+py_binary(
+ name = "graphdef",
+ srcs = ["src/test/python/graphdef.py"],
+ srcs_version = "PY2AND3",
+ deps = ["//tensorflow:tensorflow_py"],
+)
+
+java_test(
name = "TensorFlowTest",
size = "small",
srcs = ["src/test/java/org/tensorflow/TensorFlowTest.java"],