未验证 提交 1df2ee6c 编写于 作者: H Hui Zhang 提交者: GitHub

int32/int64 forward (#54687)

上级 2a56f4b3
......@@ -675,8 +675,8 @@ def logaddexp(x, y, name=None):
shape(X) = (2, 3, 4, 5), shape(Y) = (2, 1), with axis=0
Args:
x (Tensor): Tensor or LoDTensor of any dimensions. Its dtype should be float32, float64, float16.
y (Tensor): Tensor or LoDTensor of any dimensions. Its dtype should be float32, float64, float16.
x (Tensor): Tensor or LoDTensor of any dimensions. Its dtype should be int32, int64, float32, float64, float16.
y (Tensor): Tensor or LoDTensor of any dimensions. Its dtype should be int32, int64, float32, float64, float16.
name (string, optional): For details, please refer to :ref:`api_guide_Name`. Generally, no setting is required. Default: None.
Returns:
......
......@@ -66,6 +66,18 @@ class TestLogsumexpAPI(unittest.TestCase):
self.dtype = np.float32
self.api_case()
def test_api_int32(self):
self.xshape = [10, 200, 300]
self.yshape = [10, 200, 300]
self.dtype = np.int32
self.api_case()
def test_api_int64(self):
self.xshape = [10, 200, 300]
self.yshape = [10, 200, 300]
self.dtype = np.int64
self.api_case()
if __name__ == '__main__':
unittest.main()
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册