|
|
|
@ -29,7 +29,7 @@ class TestElementwiseMulDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -56,7 +56,7 @@ class TestElementwiseMulBroadcastDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -83,7 +83,7 @@ class TestElementwiseAddDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -110,7 +110,7 @@ class TestElementwiseAddBroadcastDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -137,7 +137,7 @@ class TestElementwiseSubDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -164,7 +164,7 @@ class TestElementwiseSubBroadcastDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.005
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -191,7 +191,7 @@ class TestElementwiseDivDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.0001
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
@ -219,7 +219,7 @@ class TestElementwiseDivBroadcastDoubleGradCheck(unittest.TestCase):
|
|
|
|
|
@prog_scope()
|
|
|
|
|
def func(self, place):
|
|
|
|
|
# the shape of input variable should be clearly specified, not inlcude -1.
|
|
|
|
|
shape = [2, 3, 7, 9]
|
|
|
|
|
shape = [2, 3, 4, 5]
|
|
|
|
|
eps = 0.0001
|
|
|
|
|
dtype = np.float64
|
|
|
|
|
|
|
|
|
|