mirror of
https://github.com/ROCm/jax.git
synced 2025-04-17 04:16:07 +00:00

* LU decomposition * Symmetric (Hermitian) eigendecomposition * Singular value decomposition. Make LU decomposition tests less sensitive to the exact decomposition; check that we have a decomposition, not precisely the same one scipy returns.
83 lines
2.4 KiB
Python
83 lines
2.4 KiB
Python
# 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
|
|
|
|
load("@org_tensorflow//tensorflow/core:platform/default/build_config.bzl", "pyx_library")
|
|
load("@org_tensorflow//tensorflow:tensorflow.bzl", "tf_pybind_extension")
|
|
|
|
licenses(["notice"]) # Apache 2
|
|
|
|
package(default_visibility = ["//visibility:public"])
|
|
|
|
pyx_library(
|
|
name = "lapack",
|
|
srcs = ["lapack.pyx"],
|
|
py_deps = ["@org_tensorflow//third_party/py/numpy"],
|
|
)
|
|
|
|
py_library(
|
|
name = "jaxlib",
|
|
srcs = [
|
|
"cusolver.py",
|
|
"version.py"
|
|
],
|
|
)
|
|
|
|
tf_pybind_extension(
|
|
name = "pytree",
|
|
srcs = ["pytree.cc"],
|
|
copts = [
|
|
"-fexceptions",
|
|
"-fno-strict-aliasing",
|
|
"-Wno-c++98-c++11-compat",
|
|
],
|
|
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",
|
|
],
|
|
)
|
|
|
|
tf_pybind_extension(
|
|
name = "cusolver_kernels",
|
|
srcs = ["cusolver.cc"],
|
|
copts = [
|
|
"-fexceptions",
|
|
"-fno-strict-aliasing",
|
|
"-Wno-c++98-c++11-compat",
|
|
],
|
|
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:cudart",
|
|
"@local_config_cuda//cuda:cuda_headers",
|
|
"@local_config_cuda//cuda:cusolver",
|
|
"@pybind11",
|
|
],
|
|
) |