Skip to content

Commit

Permalink
add skip_tf_cpu decorator
Browse files Browse the repository at this point in the history
Signed-off-by: hwangdeyu <dejack953@outlook.com>
Co-authored-by: Guenther Schmuelling <guschmue@microsoft.com>
Co-authored-by: fatcat-z <jiz@microsoft.com>
  • Loading branch information
3 people committed Dec 23, 2021
1 parent 8633ba0 commit ebd2c10
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 7 deletions.
9 changes: 6 additions & 3 deletions tests/test_backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -741,20 +741,23 @@ def func(x):
graph_validator=lambda g: check_op_count(g, "Reshape", 0, disabled=False))

@check_tf_min_version("1.15")
@skip_tf_cpu("only tf_gpu can run conv2d with NCHW format")
def test_conv2d_biasadd_rewriter(self):
x_shape = [2, 3, 32, 16]
x_val = make_xval(x_shape)
def func(x):
middles = tf.keras.layers.ZeroPadding2D(padding=(0, 4),
middles = tf.keras.layers.ZeroPadding2D(
padding=(0, 4),
data_format="channels_first",
name="padding")(x)
name="padding"
)(x)
t = tf.keras.layers.Conv2D(
filters=768,
kernel_size=3,
strides=1,
use_bias=True,
data_format="channels_first",
name="conv2d",
name="conv2d"
)(middles)
return tf.identity(t, name=_TFOUTPUT)
self._run_test_case(func, [_OUTPUT], {_INPUT: x_val}, rtol=1e-04, atol=1e-2, as_session=True,
Expand Down
6 changes: 2 additions & 4 deletions tf2onnx/version.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
# SPDX-License-Identifier: Apache-2.0


version = '1.8.0'
git_version = '24080398ff4793ed8aac028ffa4b714a4803d7fb'
version = '1.10.0'
git_version = '219e00c073f6e73fba7335630dcf1f96cc82c983'

0 comments on commit ebd2c10

Please sign in to comment.