pytorch-lightning踩坑记录

pytorch-lightning踩坑记录,第1张

pytorch-lightning==1.5.10,python3.7,torch==1.10.0

20220421

1

module 'torchmetrics' has no attribute 'F1'

改成:

torchmetrics.F1Score()

 2

You have asked for `amp_level='O2'` but it's only supported with `amp_backend='apex'

尝试添加amp_backend: apex到Trainer里,出现:

You have asked for Apex AMP but you have not installed it. Install `apex` using this guide: https://github.com/NVIDIA/apex

参考这条安装:安装apex

expected scalar type Float but found Half

 输出数据类型是torch.float32明明!

跑不下去了,先放个坑

欢迎分享,转载请注明来源:内存溢出

原文地址: http://outofmemory.cn/langs/717606.html

(0)
打赏 微信扫一扫 微信扫一扫 支付宝扫一扫 支付宝扫一扫
上一篇 2022-04-25
下一篇 2022-04-25

发表评论

登录后才能评论

评论列表(0条)

保存