赞
踩
since pytorch 1.2, there is a dtype torch.bool and associated BoolTensor. The bitwise operators aka numpy (and &, or |, xor ^ and not ~) all work on these as logical operations.
BoolTensor在pytorch1.2后引入,针对BoolTensor才有了如下逻辑运算(dtype为bool型)
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。