[ 仅参数名不一致 ]torch.broadcast_to

torch.broadcast_to

torch.broadcast_to(input,
                   shape)

paddle.broadcast_to

paddle.broadcast_to(x,
                    shape,
                    name=None)

两者功能一致且参数用法一致,仅参数名不同,具体如下:

参数映射

| PyTorch | PaddlePaddle | 备注 | | ————- | ———— | —————————————————— | | input| x | 表示输入的 Tensor ,仅参数名不一致。 | | shape | shape | 表示扩展后 Tensor 的 shape 。 |