From 1a595d8e90ece62298acf3982c17d3a30487d081 Mon Sep 17 00:00:00 2001 From: Yang Zhang Date: Fri, 21 Feb 2020 10:41:00 +0800 Subject: [PATCH] Remove `no_grad_set` usage from "conv_shift" op tests (#22683) --- python/paddle/fluid/tests/unittests/test_conv_shift_op.py | 6 ++---- .../tests/unittests/white_list/no_grad_set_white_list.py | 1 - 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/python/paddle/fluid/tests/unittests/test_conv_shift_op.py b/python/paddle/fluid/tests/unittests/test_conv_shift_op.py index c4dbf4c3e22..59241a40869 100644 --- a/python/paddle/fluid/tests/unittests/test_conv_shift_op.py +++ b/python/paddle/fluid/tests/unittests/test_conv_shift_op.py @@ -51,12 +51,10 @@ class TestConvShiftOp(OpTest): self.check_grad(['X', 'Y'], 'Out') def test_check_grad_ignore_x(self): - self.check_grad( - ['Y'], 'Out', max_relative_error=0.05, no_grad_set=set("X")) + self.check_grad(['Y'], 'Out') def test_check_grad_ignore_y(self): - self.check_grad( - ['X'], 'Out', max_relative_error=0.05, no_grad_set=set('Y')) + self.check_grad(['X'], 'Out') if __name__ == '__main__': diff --git a/python/paddle/fluid/tests/unittests/white_list/no_grad_set_white_list.py b/python/paddle/fluid/tests/unittests/white_list/no_grad_set_white_list.py index 29eeb590f65..d926a26c1a7 100644 --- a/python/paddle/fluid/tests/unittests/white_list/no_grad_set_white_list.py +++ b/python/paddle/fluid/tests/unittests/white_list/no_grad_set_white_list.py @@ -23,7 +23,6 @@ NEED_TO_FIX_OP_LIST = [ 'affine_grid', 'backward', 'batch_norm', - 'conv_shift', 'conv2d', 'conv2d_transpose', 'conv3d', -- GitLab