diff options
author | A. Unique TensorFlower <gardener@tensorflow.org> | 2017-11-21 23:55:59 -0800 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2017-11-22 00:01:14 -0800 |
commit | d0a3b2d3983b970b750329088013dc5cb67d96f9 (patch) | |
tree | 17cc584c4568e4e64a4bdd6bbee0be0b9d96f62c /tensorflow/core/kernels/mkl_tfconv_op.h | |
parent | c6d603f02e1a98f871912cda6716cdcbed6b439e (diff) |
Merged commit includes the following changes:
176617057 by yifeif:
Internal change.
--
176615737 by yifeif:
Fix internal tests.
--
PiperOrigin-RevId: 176617057
Diffstat (limited to 'tensorflow/core/kernels/mkl_tfconv_op.h')
-rw-r--r-- | tensorflow/core/kernels/mkl_tfconv_op.h | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/tensorflow/core/kernels/mkl_tfconv_op.h b/tensorflow/core/kernels/mkl_tfconv_op.h index 0a5be4fec9..c4d5a45d3c 100644 --- a/tensorflow/core/kernels/mkl_tfconv_op.h +++ b/tensorflow/core/kernels/mkl_tfconv_op.h @@ -101,8 +101,8 @@ class MklToTfOp : public OpKernel { // Allocate output tensor. TensorShape output_shape = input_shape.GetTfShape(); Tensor* output_tensor = NULL; - OP_REQUIRES_OK(context, context->allocate_output(input_number, - output_shape, &output_tensor)); + OP_REQUIRES_OK(context, context->allocate_output( + input_number, output_shape, &output_tensor)); CHECK_NOTNULL(output_tensor); // Do we need to reorder Mkl layout into TensorFlow layout? @@ -116,13 +116,13 @@ class MklToTfOp : public OpKernel { // If not, just forward input tensor to output tensor. CHECK(output_tensor->CopyFrom(input_tensor, output_shape)); } - } catch (mkldnn::error &e) { + } catch (mkldnn::error& e) { string error_msg = "Status: " + std::to_string(e.status) + - ", message: " + std::string(e.message) + - ", in file " + std::string(__FILE__) + ":" + - std::to_string(__LINE__); - OP_REQUIRES_OK(context, - errors::Aborted("Operation received an exception:", error_msg)); + ", message: " + std::string(e.message) + ", in file " + + std::string(__FILE__) + ":" + std::to_string(__LINE__); + OP_REQUIRES_OK( + context, + errors::Aborted("Operation received an exception:", error_msg)); } } #else @@ -160,8 +160,8 @@ class MklToTfOp : public OpKernel { // Allocate output tensor. Tensor* output_tensor = NULL; - OP_REQUIRES_OK(context, context->allocate_output(input_number, - output_shape, &output_tensor)); + OP_REQUIRES_OK(context, context->allocate_output(input_number, output_shape, + &output_tensor)); dnnLayout_t output_layout = static_cast<dnnLayout_t>(input_shape.GetTfLayout()); |