37 lines
1.1 KiB
Python
37 lines
1.1 KiB
Python
load("@xla//third_party/rules_python/python:py_library.bzl", "py_library")
|
|
load("//tensorflow:tensorflow.default.bzl", "cuda_py_strict_test")
|
|
|
|
package(
|
|
# copybara:uncomment default_applicable_licenses = ["//tensorflow:license"],
|
|
default_visibility = ["//visibility:private"],
|
|
licenses = ["notice"],
|
|
)
|
|
|
|
py_library(
|
|
name = "dlpack",
|
|
srcs = ["dlpack.py"],
|
|
strict_deps = True,
|
|
visibility = ["//tensorflow:__subpackages__"],
|
|
deps = [
|
|
"//tensorflow/python:pywrap_tfe",
|
|
"//tensorflow/python/eager:context",
|
|
"//tensorflow/python/util:tf_export",
|
|
],
|
|
)
|
|
|
|
cuda_py_strict_test(
|
|
name = "dlpack_test",
|
|
srcs = ["dlpack_test.py"],
|
|
deps = [
|
|
":dlpack",
|
|
"//tensorflow/python/eager:context",
|
|
"//tensorflow/python/framework:constant_op",
|
|
"//tensorflow/python/framework:dtypes",
|
|
"//tensorflow/python/framework:errors",
|
|
"//tensorflow/python/framework:ops",
|
|
"//tensorflow/python/ops:array_ops",
|
|
"//tensorflow/python/platform:client_testlib",
|
|
"@absl_py//absl/testing:parameterized",
|
|
],
|
|
)
|