2018-12-17 14:36:21 -05:00
|
|
|
# Copyright 2018 Google LLC
|
|
|
|
#
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
# you may not use this file except in compliance with the License.
|
|
|
|
# You may obtain a copy of the License at
|
|
|
|
#
|
|
|
|
# https://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
#
|
|
|
|
# Unless required by applicable law or agreed to in writing, software
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
# See the License for the specific language governing permissions and
|
|
|
|
# limitations under the License.
|
|
|
|
|
|
|
|
# JAX is Autograd and XLA
|
|
|
|
|
2019-08-07 12:55:09 -04:00
|
|
|
load("@org_tensorflow//tensorflow/core/platform:default/build_config.bzl", "pyx_library")
|
2019-08-09 15:37:54 -04:00
|
|
|
load("@org_tensorflow//tensorflow:tensorflow.bzl", "pybind_extension")
|
2018-12-17 14:36:21 -05:00
|
|
|
|
2019-09-26 14:51:24 -07:00
|
|
|
licenses(["notice"])
|
2018-12-17 14:36:21 -05:00
|
|
|
|
|
|
|
package(default_visibility = ["//visibility:public"])
|
|
|
|
|
|
|
|
pyx_library(
|
|
|
|
name = "lapack",
|
|
|
|
srcs = ["lapack.pyx"],
|
2018-12-19 14:51:46 -05:00
|
|
|
py_deps = ["@org_tensorflow//third_party/py/numpy"],
|
2018-12-17 14:36:21 -05:00
|
|
|
)
|
2019-04-01 08:21:22 -07:00
|
|
|
|
|
|
|
py_library(
|
|
|
|
name = "jaxlib",
|
2019-08-02 11:16:15 -04:00
|
|
|
srcs = [
|
2019-08-02 13:29:52 -04:00
|
|
|
"cusolver.py",
|
2019-08-02 13:32:14 -04:00
|
|
|
"version.py",
|
2019-08-02 11:16:15 -04:00
|
|
|
],
|
2019-04-01 08:23:02 -07:00
|
|
|
)
|
2019-07-29 15:06:05 -04:00
|
|
|
|
2019-08-09 15:37:54 -04:00
|
|
|
pybind_extension(
|
2019-07-29 15:06:05 -04:00
|
|
|
name = "pytree",
|
|
|
|
srcs = ["pytree.cc"],
|
|
|
|
copts = [
|
|
|
|
"-fexceptions",
|
|
|
|
"-fno-strict-aliasing",
|
|
|
|
],
|
|
|
|
features = ["-use_header_modules"],
|
|
|
|
module_name = "pytree",
|
|
|
|
deps = [
|
|
|
|
"@com_google_absl//absl/algorithm:container",
|
|
|
|
"@com_google_absl//absl/container:flat_hash_map",
|
|
|
|
"@com_google_absl//absl/hash",
|
|
|
|
"@com_google_absl//absl/memory",
|
|
|
|
"@com_google_absl//absl/strings",
|
|
|
|
"@com_google_absl//absl/strings:str_format",
|
|
|
|
"@pybind11",
|
|
|
|
],
|
2019-07-30 10:15:37 -04:00
|
|
|
)
|
2019-08-02 11:16:15 -04:00
|
|
|
|
2019-08-09 15:37:54 -04:00
|
|
|
pybind_extension(
|
2019-08-08 11:50:31 -04:00
|
|
|
name = "cublas_kernels",
|
|
|
|
srcs = ["cublas.cc"],
|
|
|
|
copts = [
|
|
|
|
"-fexceptions",
|
|
|
|
"-fno-strict-aliasing",
|
|
|
|
],
|
|
|
|
features = ["-use_header_modules"],
|
|
|
|
module_name = "cublas_kernels",
|
|
|
|
deps = [
|
|
|
|
"@com_google_absl//absl/algorithm:container",
|
|
|
|
"@com_google_absl//absl/base",
|
|
|
|
"@com_google_absl//absl/container:flat_hash_map",
|
|
|
|
"@com_google_absl//absl/hash",
|
|
|
|
"@com_google_absl//absl/memory",
|
|
|
|
"@com_google_absl//absl/strings",
|
|
|
|
"@com_google_absl//absl/strings:str_format",
|
|
|
|
"@com_google_absl//absl/synchronization",
|
|
|
|
"@local_config_cuda//cuda:cublas",
|
|
|
|
"@local_config_cuda//cuda:cublas_headers",
|
|
|
|
"@local_config_cuda//cuda:cuda_headers",
|
|
|
|
"@local_config_cuda//cuda:cudart",
|
|
|
|
"@pybind11",
|
|
|
|
],
|
|
|
|
)
|
|
|
|
|
2019-08-09 15:37:54 -04:00
|
|
|
pybind_extension(
|
2019-08-02 11:16:15 -04:00
|
|
|
name = "cusolver_kernels",
|
|
|
|
srcs = ["cusolver.cc"],
|
|
|
|
copts = [
|
|
|
|
"-fexceptions",
|
|
|
|
"-fno-strict-aliasing",
|
|
|
|
],
|
|
|
|
features = ["-use_header_modules"],
|
|
|
|
module_name = "cusolver_kernels",
|
|
|
|
deps = [
|
|
|
|
"@com_google_absl//absl/algorithm:container",
|
|
|
|
"@com_google_absl//absl/base",
|
|
|
|
"@com_google_absl//absl/container:flat_hash_map",
|
|
|
|
"@com_google_absl//absl/hash",
|
|
|
|
"@com_google_absl//absl/memory",
|
|
|
|
"@com_google_absl//absl/strings",
|
|
|
|
"@com_google_absl//absl/strings:str_format",
|
|
|
|
"@com_google_absl//absl/synchronization",
|
|
|
|
"@local_config_cuda//cuda:cuda_headers",
|
2019-08-02 13:29:52 -04:00
|
|
|
"@local_config_cuda//cuda:cudart",
|
2019-08-02 11:16:15 -04:00
|
|
|
"@local_config_cuda//cuda:cusolver",
|
|
|
|
"@pybind11",
|
|
|
|
],
|
2019-08-08 16:33:04 -04:00
|
|
|
)
|