From 2c995bda2b90511766ce1b28af8b5f1a2dc08565 Mon Sep 17 00:00:00 2001 From: Yi Situ Date: Thu, 18 Feb 2021 17:20:20 -0800 Subject: [PATCH] Change TPU_LOAD_LIBRARY to accept 1/0 instead of true/false. PiperOrigin-RevId: 358300004 Change-Id: I93059c5e8fa32463be8a7e598009219a450b498e --- tensorflow/core/tpu/tpu_initializer_helper.cc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tensorflow/core/tpu/tpu_initializer_helper.cc b/tensorflow/core/tpu/tpu_initializer_helper.cc index 218ff510aff..61501332658 100644 --- a/tensorflow/core/tpu/tpu_initializer_helper.cc +++ b/tensorflow/core/tpu/tpu_initializer_helper.cc @@ -39,11 +39,11 @@ bool TryAcquireTpuLock() { if (!attempted_file_open) { std::string load_library_override = - absl::StringCat(getenv("TPU_LOAD_LIBRARY")); + absl::StrCat(getenv("TPU_LOAD_LIBRARY")); - if (load_library_override == "true") { + if (load_library_override == "1") { return true; - } else if (load_library_override == "false") { + } else if (load_library_override == "0") { return false; } should_load_library = true;