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 = ["//tensorflow:internal"], licenses = ["notice"], ) py_library( name = "test_util", srcs = ["test_util.py"], strict_deps = True, deps = [ "//tensorflow/core:protos_all_py", "//tensorflow/python/grappler:tf_optimizer", "//tensorflow/python/training:saver", ], ) cuda_py_strict_test( name = "dct_ops_test", srcs = ["dct_ops_test.py"], shard_count = 16, deps = [ "//tensorflow/python/eager:def_function", "//tensorflow/python/framework:tensor_spec", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops/signal:dct_ops", "//tensorflow/python/platform:client_testlib", "//tensorflow/python/platform:tf_logging", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "fft_ops_test", size = "medium", srcs = ["fft_ops_test.py"], shard_count = 2, tags = [ "optonly", ], deps = [ "//tensorflow/core:protos_all_py", "//tensorflow/python/eager:context", "//tensorflow/python/framework:config", "//tensorflow/python/framework:dtypes", "//tensorflow/python/framework:errors", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops:gradient_checker_v2", "//tensorflow/python/ops:math_ops", "//tensorflow/python/ops:spectral_ops_gen", "//tensorflow/python/ops/signal:fft_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "mel_ops_test", srcs = ["mel_ops_test.py"], deps = [ ":test_util", "//tensorflow/python/eager:context", "//tensorflow/python/framework:constant_op", "//tensorflow/python/framework:dtypes", "//tensorflow/python/framework:ops", "//tensorflow/python/framework:tensor_util", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops/signal:mel_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "mfcc_ops_test", srcs = ["mfcc_ops_test.py"], deps = [ "//tensorflow/python/eager:context", "//tensorflow/python/framework:for_generated_wrappers", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops:random_ops", "//tensorflow/python/ops/signal:mfcc_ops", "//tensorflow/python/platform:client_testlib", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "reconstruction_ops_test", srcs = ["reconstruction_ops_test.py"], deps = [ "//tensorflow/python/eager:context", "//tensorflow/python/framework:constant_op", "//tensorflow/python/framework:for_generated_wrappers", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops:array_ops_stack", "//tensorflow/python/ops:gradient_checker_v2", "//tensorflow/python/ops:gradients_impl", "//tensorflow/python/ops:math_ops", "//tensorflow/python/ops/signal:reconstruction_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "shape_ops_test", srcs = ["shape_ops_test.py"], deps = [ ":test_util", "//tensorflow/python/eager:context", "//tensorflow/python/framework:constant_op", "//tensorflow/python/framework:for_generated_wrappers", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops:math_ops", "//tensorflow/python/ops/signal:shape_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", ], ) cuda_py_strict_test( name = "spectral_ops_test", size = "large", srcs = ["spectral_ops_test.py"], tags = [ "no_rocm", "nomac", ], deps = [ "//tensorflow/python/eager:context", "//tensorflow/python/framework:for_generated_wrappers", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops:array_ops", "//tensorflow/python/ops:gradient_checker_v2", "//tensorflow/python/ops:gradients_impl", "//tensorflow/python/ops:math_ops", "//tensorflow/python/ops/signal:spectral_ops", "//tensorflow/python/ops/signal:window_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], ) cuda_py_strict_test( name = "window_ops_test", srcs = ["window_ops_test.py"], shard_count = 4, tags = [ "no_rocm", "no_windows_gpu", ], deps = [ ":test_util", "//tensorflow/python/eager:context", "//tensorflow/python/framework:for_generated_wrappers", "//tensorflow/python/framework:tensor_spec", "//tensorflow/python/framework:test_lib", "//tensorflow/python/ops/signal:window_ops", "//tensorflow/python/platform:client_testlib", "//third_party/py/numpy", "@absl_py//absl/testing:parameterized", ], )