broadcast_shape¶
- paddle. broadcast_shape ( x_shape, y_shape ) [source]
- 
         The function returns the shape of doing operation with broadcasting on tensors of x_shape and y_shape, please refer to user_guide_broadcasting for more details. - Parameters
- 
           - x_shape (list[int]|tuple[int]) – A shape of tensor. 
- y_shape (list[int]|tuple[int]) – A shape of tensor. 
 
- Returns
- 
           list[int], the result shape. 
 Examples import paddle shape = paddle.broadcast_shape([2, 1, 3], [1, 3, 1]) # [2, 3, 3] # shape = paddle.broadcast_shape([2, 1, 3], [3, 3, 1]) # ValueError (terminated with error message). 
