TFLite Rsqrt is converted to Div(Quantize(1), Sqrt(input)) in the hexagon graph. PiperOrigin-RevId: 349308872 Change-Id: Ic392af0f0e1eac4cf712775c5944ca650271ea4b
104 lines
2.9 KiB
Python
104 lines
2.9 KiB
Python
package(
|
|
default_visibility = [
|
|
"//visibility:public",
|
|
],
|
|
licenses = ["notice"], # Apache 2.0
|
|
)
|
|
|
|
cc_library(
|
|
name = "op_builder",
|
|
srcs = [
|
|
"activation_builder.cc",
|
|
"arg_min_max_builder.cc",
|
|
"arithmetic_builder.cc",
|
|
"batch_seq_builder.cc",
|
|
"cast_builder.cc",
|
|
"concat_builder.cc",
|
|
"conv_2d_builder.cc",
|
|
"conv_2d_helpers.cc",
|
|
"hardswish_builder.cc",
|
|
"l2_normalization_builder.cc",
|
|
"matmul_builder.cc",
|
|
"min_max_builder.cc",
|
|
"mirror_pad_builder.cc",
|
|
"neg_op_builder.cc",
|
|
"op_builder.cc",
|
|
"pack_builder.cc",
|
|
"pad_builder.cc",
|
|
"pool_2d_builder.cc",
|
|
"quantize_builder.cc",
|
|
"reduce_builder.cc",
|
|
"reshape_builder.cc",
|
|
"resize_bilinear_builder.cc",
|
|
"resize_nearest_neighbor_builder.cc",
|
|
"rsqrt_builder.cc",
|
|
"slice_builder.cc",
|
|
"softmax_builder.cc",
|
|
"space_to_depth_builder.cc",
|
|
"split_builder.cc",
|
|
"squared_difference.cc",
|
|
"strided_slice_builder.cc",
|
|
"transpose_builder.cc",
|
|
"transpose_conv_2d_builder.cc",
|
|
],
|
|
hdrs = [
|
|
"activation_builder.h",
|
|
"arg_min_max_builder.h",
|
|
"arithmetic_builder.h",
|
|
"batch_seq_builder.h",
|
|
"cast_builder.h",
|
|
"concat_builder.h",
|
|
"conv_2d_builder.h",
|
|
"hardswish_builder.h",
|
|
"l2_normalization_builder.h",
|
|
"matmul_builder.h",
|
|
"min_max_builder.h",
|
|
"mirror_pad_builder.h",
|
|
"neg_op_builder.h",
|
|
"op_builder.h",
|
|
"pack_builder.h",
|
|
"pad_builder.h",
|
|
"pool_2d_builder.h",
|
|
"quantize_builder.h",
|
|
"reduce_builder.h",
|
|
"reshape_builder.h",
|
|
"resize_bilinear_builder.h",
|
|
"resize_nearest_neighbor_builder.h",
|
|
"slice_builder.h",
|
|
"softmax_builder.h",
|
|
"space_to_depth_builder.h",
|
|
"split_builder.h",
|
|
"strided_slice_builder.h",
|
|
"transpose_builder.h",
|
|
"transpose_conv_2d_builder.h",
|
|
],
|
|
tags = [
|
|
"manual",
|
|
"nobuilder",
|
|
],
|
|
deps = [
|
|
":op_factory",
|
|
"//tensorflow/lite:kernel_api",
|
|
"//tensorflow/lite:util",
|
|
"//tensorflow/lite/c:common",
|
|
"//tensorflow/lite/delegates/hexagon:hexagon_implementation",
|
|
"//tensorflow/lite/delegates/hexagon/hexagon_nn:hexagon_nn_header",
|
|
"//tensorflow/lite/kernels:kernel_util",
|
|
"//tensorflow/lite/kernels:padding",
|
|
"//tensorflow/lite/kernels/internal:optimized_base",
|
|
"//tensorflow/lite/kernels/internal:tensor",
|
|
"@farmhash_archive//:farmhash",
|
|
"@hexagon_nn//:hexagon_nn_ops",
|
|
],
|
|
)
|
|
|
|
cc_library(
|
|
name = "op_factory",
|
|
hdrs = ["op_factory.h"],
|
|
tags = [
|
|
"manual",
|
|
"nobuilder",
|
|
],
|
|
deps = ["//tensorflow/lite/c:common"],
|
|
)
|