[go: nahoru, domu]

Skip to content

Commit

Permalink
Added standalone kernel_library and gen_op_wrapper_py targets
Browse files Browse the repository at this point in the history
for sdca_ops.
Change: 117884415
  • Loading branch information
keveman authored and tensorflower-gardener committed Mar 23, 2016
1 parent f4afb66 commit b7babfd
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 1 deletion.
25 changes: 24 additions & 1 deletion tensorflow/contrib/linear_optimizer/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,10 @@ exports_files(["LICENSE"])

package(default_visibility = ["//tensorflow:__subpackages__"])

load("//tensorflow:tensorflow.bzl", "tf_custom_op_library")
load("//tensorflow:tensorflow.bzl", "tf_gen_op_libs")
load("//tensorflow:tensorflow.bzl", "tf_gen_op_wrapper_py")
load("//tensorflow:tensorflow.bzl", "tf_custom_op_library")
load("//tensorflow:tensorflow.bzl", "tf_kernel_library")

tf_custom_op_library(
# TODO(sibyl-Mooth6ku): Understand why 'python/ops/_' is needed and fix it.
Expand All @@ -23,6 +24,27 @@ tf_custom_op_library(
],
)

tf_gen_op_libs(
op_lib_names = ["sdca_ops"],
)

tf_gen_op_wrapper_py(
name = "sdca_ops",
deps = ["//tensorflow/contrib/linear_optimizer:sdca_ops_op_lib"],
)

tf_kernel_library(
name = "sdca_op_kernels",
srcs = [
"ops/sdca_ops.cc",
],
deps = [
"//tensorflow/contrib/linear_optimizer/kernels:sdca_ops",
"//tensorflow/core:framework",
],
alwayslink = 1,
)

py_library(
name = "sdca_ops_py",
srcs = [
Expand All @@ -31,6 +53,7 @@ py_library(
],
data = [":python/ops/_sdca_ops.so"],
srcs_version = "PY2AND3",
deps = [":sdca_ops"],
)

py_test(
Expand Down
1 change: 1 addition & 0 deletions tensorflow/contrib/linear_optimizer/python/ops/sdca_ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@

from six.moves import range # pylint: disable=redefined-builtin

from tensorflow.contrib.linear_optimizer.ops import gen_sdca_ops
from tensorflow.python.framework import dtypes
from tensorflow.python.framework import ops
from tensorflow.python.framework.load_library import load_op_library
Expand Down

0 comments on commit b7babfd

Please sign in to comment.