未验证 提交 3fd2e765 编写于 作者: L LyndonKong 提交者: GitHub

Fix sample code of poisson_nll_loss (#53551)

上级 acefdeb7
...@@ -1541,7 +1541,7 @@ def poisson_nll_loss( ...@@ -1541,7 +1541,7 @@ def poisson_nll_loss(
input = paddle.randn([5, 2], dtype=paddle.float32) input = paddle.randn([5, 2], dtype=paddle.float32)
label = paddle.randn([5, 2], dtype=paddle.float32) label = paddle.randn([5, 2], dtype=paddle.float32)
loss = F.poisson_nll_loss(input, label, log_input=True, reduction='None') loss = F.poisson_nll_loss(input, label, log_input=True, reduction='none')
print(loss) print(loss)
loss = F.poisson_nll_loss(input, label, reduction='mean') loss = F.poisson_nll_loss(input, label, reduction='mean')
print(loss) print(loss)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册