pytorch错误:RuntimeError: received 0 items of ancdata解决

2022/4/25 6:12:46

本文主要是介绍pytorch错误:RuntimeError: received 0 items of ancdata解决,对大家解决编程问题具有一定的参考价值,需要的程序猿们随着小编来一起学习吧!

https://www.cnblogs.com/zhengbiqing/p/10478311.html

https://blog.csdn.net/chen1234520nnn/article/details/103935825

 

https://github.com/pytorch/pytorch/issues/973

1)修改多线程的tensor方式为file_system(默认方式为file_descriptor,受限于open files数量):

#训练python脚本中import torch后,加上下面这句。 
torch.multiprocessing.set_sharing_strategy('file_system')

  



这篇关于pytorch错误:RuntimeError: received 0 items of ancdata解决的文章就介绍到这儿,希望我们推荐的文章对大家有所帮助,也希望大家多多支持为之网!


扫一扫关注最新编程教程