torch.nn.Softmin(dim=None)
Paddle 无此 API,需要组合实现。
# PyTorch 写法 module = torch.nn.Softmin(dim=1) module(input) # Paddle 写法 module = paddle.nn.Softmax(axis=1) module(-1. * input) # 使用负输入与 Softmax 组合来实现 Softmin