pytorch判断tensor是否有脏数据NaN

更新时间:2023-06-12 23:05:25 阅读: 评论:0

pytorch判断tensor是否有脏数据NaN You can always leverage the fact that nan != nan:
内蒙古大草原>>> x = sor([1, 2, np.nan])
tensor([  1.,  2., nan.])
收到假钞怎么办
排球传球>>> x != x
tensor([ 0,  0,  1], dtype=torch.uint8)
党员可以出国吗>惠灵顿牛排的做法>三只小猪ppt知识树With pytorch 0.4 there is also :浙江高考时间
>>> torch.isnan(x)
tensor([ 0,  0,  1], dtype=torch.uint8)

本文发布于:2023-06-12 23:05:25,感谢您对本站的认可!

本文链接:https://www.wtabcd.cn/fanwen/fan/82/940562.html

版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。

标签:出国   做法   牛排
相关文章
留言与评论(共有 0 条评论)
   
验证码:
推荐文章
排行榜
Copyright ©2019-2022 Comsenz Inc.Powered by © 专利检索| 网站地图