File tree Expand file tree Collapse file tree 5 files changed +26
-0
lines changed
tensorflow_addons/custom_ops Expand file tree Collapse file tree 5 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -23,8 +23,14 @@ limitations under the License.
2323#include " tensorflow/core/framework/op_kernel.h"
2424#include " tensorflow/core/framework/register_types.h"
2525#include " tensorflow/core/framework/types.h"
26+ #include " tensorflow/core/public/version.h"
27+ #if TF_MAJOR_VERSION == 2 && TF_MINOR_VERSION >= 16
28+ #include " Eigen/Core"
29+ #include " unsupported/Eigen/CXX11/Tensor"
30+ #else
2631#include " third_party/eigen3/Eigen/Core"
2732#include " third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
33+ #endif
2834
2935namespace tensorflow {
3036namespace addons {
Original file line number Diff line number Diff line change @@ -26,8 +26,13 @@ limitations under the License.
2626#include " tensorflow/core/framework/op_kernel.h"
2727#include " tensorflow/core/framework/tensor_types.h"
2828#include " tensorflow/core/platform/types.h"
29+ #include " tensorflow/core/public/version.h"
2930#include " tensorflow/core/util/work_sharder.h"
31+ #if TF_MAJOR_VERSION == 2 && TF_MINOR_VERSION >= 16
32+ #include " unsupported/Eigen/CXX11/Tensor"
33+ #else
3034#include " third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
35+ #endif
3136
3237namespace tensorflow {
3338namespace addons {
Original file line number Diff line number Diff line change @@ -21,7 +21,12 @@ limitations under the License.
2121#include " tensorflow/core/framework/op_kernel.h"
2222#include " tensorflow/core/framework/tensor_types.h"
2323#include " tensorflow/core/platform/types.h"
24+ #include " tensorflow/core/public/version.h"
25+ #if TF_MAJOR_VERSION == 2 && TF_MINOR_VERSION >= 16
26+ #include " unsupported/Eigen/CXX11/Tensor"
27+ #else
2428#include " third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
29+ #endif
2530
2631namespace tensorflow {
2732namespace addons {
Original file line number Diff line number Diff line change @@ -32,8 +32,13 @@ limitations under the License.
3232#include " tensorflow/core/framework/types.h"
3333#include " tensorflow/core/platform/logging.h"
3434#include " tensorflow/core/platform/macros.h"
35+ #include " tensorflow/core/public/version.h"
3536#include " tensorflow/core/util/work_sharder.h"
37+ #if TF_MAJOR_VERSION == 2 && TF_MINOR_VERSION >= 16
38+ #include " unsupported/Eigen/CXX11/Tensor"
39+ #else
3640#include " third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
41+ #endif
3742
3843namespace tensorflow {
3944namespace addons {
Original file line number Diff line number Diff line change @@ -18,7 +18,12 @@ limitations under the License.
1818
1919#include " tensorflow/core/framework/tensor_types.h"
2020#include " tensorflow/core/platform/types.h"
21+ #include " tensorflow/core/public/version.h"
22+ #if TF_MAJOR_VERSION == 2 && TF_MINOR_VERSION >= 16
23+ #include " unsupported/Eigen/CXX11/Tensor"
24+ #else
2125#include " third_party/eigen3/unsupported/Eigen/CXX11/Tensor"
26+ #endif
2227
2328namespace tensorflow {
2429class OpKernelContext ;
You can’t perform that action at this time.
0 commit comments