From 289af050cc8f85f782af7c525977689d34f96f61 Mon Sep 17 00:00:00 2001 From: Cesar Crusius Date: Fri, 20 Mar 2020 11:57:09 -0700 Subject: [PATCH] Internal Copybara change. PiperOrigin-RevId: 302071704 Change-Id: If250e336a66aa462b09881cf9a8f6eb4e6ccc3a7 --- tensorflow/core/kernels/eigen_contraction_kernel.cc | 10 ++++++++-- tensorflow/core/platform/strcat.h | 2 +- tensorflow/lite/delegates/gpu/gl/kernels/resize.cc | 2 +- tensorflow/lite/delegates/gpu/metal/kernels/resize.cc | 2 +- 4 files changed, 11 insertions(+), 5 deletions(-) diff --git a/tensorflow/core/kernels/eigen_contraction_kernel.cc b/tensorflow/core/kernels/eigen_contraction_kernel.cc index aa6cb4b9cb9..4959651569c 100644 --- a/tensorflow/core/kernels/eigen_contraction_kernel.cc +++ b/tensorflow/core/kernels/eigen_contraction_kernel.cc @@ -28,7 +28,9 @@ limitations under the License. // the configuration through the environment variable. // // Example: -// bazel test --test_env=TENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL=false //test +// bazel test \ +// --test_env=TENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL=false \ +// //path/to:test #if defined(TENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL) @@ -37,7 +39,11 @@ namespace internal { // TODO(ezhulenev): This is a temporary workaround for disabling custom kernels // at runtime in tests. We should always rely on compile time flags for that. -// Example: ... --test_env=TENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL=false //test +// +// Example: +// bazel test \ +// --test_env=TENSORFLOW_USE_CUSTOM_CONTRACTION_KERNEL=false \ +// //path/to:test EIGEN_DEVICE_FUNC EIGEN_DONT_INLINE bool UseCustomContractionKernels() { static bool use_custom_contraction_kernel = true; diff --git a/tensorflow/core/platform/strcat.h b/tensorflow/core/platform/strcat.h index 6b435dceca3..640355c9ea5 100644 --- a/tensorflow/core/platform/strcat.h +++ b/tensorflow/core/platform/strcat.h @@ -33,7 +33,7 @@ limitations under the License. // to your function, your callers will automatically convert bools, integers, // and floating point values to strings for you. // -// NOTE: Use of AlphaNum outside of the //strings package is unsupported except +// NOTE: Use of AlphaNum outside of the "strings" package is unsupported except // for the specific case of function parameters of type "AlphaNum" or "const // AlphaNum &". In particular, instantiating AlphaNum directly as a stack // variable is not supported. diff --git a/tensorflow/lite/delegates/gpu/gl/kernels/resize.cc b/tensorflow/lite/delegates/gpu/gl/kernels/resize.cc index b8949e41426..33d59518987 100644 --- a/tensorflow/lite/delegates/gpu/gl/kernels/resize.cc +++ b/tensorflow/lite/delegates/gpu/gl/kernels/resize.cc @@ -93,7 +93,7 @@ class Resize : public NodeShader { st.xy = max(icoord_floor, ivec2(0, 0)); st.zw = min(icoord_floor + ivec2(1, 1), borders); - vec2 t = coord - coord_floor; //interpolating factors + vec2 t = coord - coord_floor; // interpolating factors vec4 tex11 = $input_data_0[st.x, st.y, gid.z]$; vec4 tex21 = $input_data_0[st.z, st.y, gid.z]$; diff --git a/tensorflow/lite/delegates/gpu/metal/kernels/resize.cc b/tensorflow/lite/delegates/gpu/metal/kernels/resize.cc index 2ed75ad65b1..24d7bcf13bc 100644 --- a/tensorflow/lite/delegates/gpu/metal/kernels/resize.cc +++ b/tensorflow/lite/delegates/gpu/metal/kernels/resize.cc @@ -54,7 +54,7 @@ std::string GetResizeBilinearCode(bool half_pixel_centers) { int4 st; st.xy = max(itex_coord_floor, int2(0, 0)); st.zw = min(itex_coord_floor + int2(1, 1), borders); - const float2 t = tex_coord - tex_coord_floor; //interpolating factors + const float2 t = tex_coord - tex_coord_floor; // interpolating factors const int src_index0 = (gid.z * size.y + st.y) * size.x + st.x; const int src_index1 = (gid.z * size.y + st.y) * size.x + st.z; const int src_index2 = (gid.z * size.y + st.w) * size.x + st.x;