From 187404eac001d67e8f0b3a7aeac2fc2b2ba65e0a Mon Sep 17 00:00:00 2001 From: Benoit Steiner Date: Wed, 7 Jun 2017 16:51:01 -0700 Subject: Setup the env to since ops such as MatchFileOp rely on it. PiperOrigin-RevId: 158336344 --- tensorflow/core/grappler/optimizers/constant_folding.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tensorflow/core/grappler/optimizers/constant_folding.cc b/tensorflow/core/grappler/optimizers/constant_folding.cc index 8bf6a081e3..33b0e16093 100644 --- a/tensorflow/core/grappler/optimizers/constant_folding.cc +++ b/tensorflow/core/grappler/optimizers/constant_folding.cc @@ -30,6 +30,7 @@ limitations under the License. #include "tensorflow/core/lib/gtl/inlined_vector.h" #include "tensorflow/core/lib/strings/numbers.h" #include "tensorflow/core/lib/strings/strcat.h" +#include "tensorflow/core/platform/env.h" #include "tensorflow/core/public/version.h" namespace tensorflow { @@ -53,7 +54,7 @@ class EigenThreadPoolWrapper : public Eigen::ThreadPoolInterface { class DeviceSimple : public DeviceBase { public: - DeviceSimple() : DeviceBase(nullptr) { + DeviceSimple() : DeviceBase(Env::Default()) { eigen_worker_threads_.num_threads = 1; eigen_worker_threads_.workers = new thread::ThreadPool( Env::Default(), "constant_folding", eigen_worker_threads_.num_threads); -- cgit v1.2.3