Skip to content

Commit

Permalink
[Fix] use ITEX_LAYOUT_OPT in UTs (#2679)
Browse files Browse the repository at this point in the history
  • Loading branch information
yitingw1 committed Apr 23, 2024
1 parent dc5cd48 commit 72a05fd
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion test/sanity/nn/test_fused_batchnorm.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
from tensorflow.python.ops import nn_impl
from tensorflow.python.ops import nn_ops

os.environ['ITEX_ENABLE_ONEDNN_LAYOUT_OPT']="0"
os.environ['ITEX_LAYOUT_OPT']="0"

class BatchNormalizationTest(test.TestCase):
def _test_training_bwd(self,
Expand Down
2 changes: 1 addition & 1 deletion test/sanity/quantization/native_quantized_concat_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@

import tensorflow as tf

os.environ["ITEX_ENABLE_ONEDNN_LAYOUT_OPT"] = "0"
os.environ["ITEX_LAYOUT_OPT"] = "0"
os.environ["ITEX_NATIVE_FORMAT"] = "1"

class QuantizedConcat(test.TestCase):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

import tensorflow as tf

os.environ["ITEX_ENABLE_ONEDNN_LAYOUT_OPT"] = "0"
os.environ["ITEX_LAYOUT_OPT"] = "0"
os.environ["ITEX_NATIVE_FORMAT"] = "1"

class QuantizedFusedBatchNorm(test.TestCase):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
from tensorflow.python.ops import nn_ops
from tensorflow.python.ops.gen_nn_ops import quantized_max_pool

os.environ["ITEX_ENABLE_ONEDNN_LAYOUT_OPT"] = "1"
os.environ["ITEX_LAYOUT_OPT"] = "1"

# TODO(itex): Test Quantize op in eager mode (non-block-layout pass),
# when we support it
Expand Down
2 changes: 1 addition & 1 deletion test/tensorflow/python/kernel_tests/conv_ops_3d_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
from tensorflow.python.eager import context

# Test plain format
os.environ['ITEX_ENABLE_ONEDNN_LAYOUT_OPT']="0"
os.environ['ITEX_LAYOUT_OPT']="0"

def GetTestConfigs():
"""Get all the valid tests configs to run.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@

import tensorflow as tf

os.environ["ITEX_ENABLE_ONEDNN_LAYOUT_OPT"] = "0"
os.environ["ITEX_LAYOUT_OPT"] = "0"
os.environ["ITEX_NATIVE_FORMAT"] = "1"

class QuantizedPoolingTest(test.TestCase):
Expand Down

0 comments on commit 72a05fd

Please sign in to comment.