14 fro._nameer">
当前位置:   article > 正文

name ‘_C‘ is not defined(pytorch1.9.0在jupyter notebook上报错)_nameerror: name '_c' is not defined

nameerror: name '_c' is not defined
  1. NameError Traceback (most recent call last) in 1 from algorithms import Argparser ----> 2 from algorithms import Session 3 def main(): 4 print("main started") 5 args = Argparser.parse()
  2. D:\git\stav\stav-rl\algorithms\Session.py in 12 13 ---> 14 from algorithms.Episode import Episode 15 from algorithms.Agent import Agent 16 import torch
  3. D:\git\stav\stav-rl\algorithms\Episode.py in 1 author = 'Noam' 2 ----> 3 import torch 4 import numpy as np 5 import cv2
  4. c:\anaconda3\envs\threadartrl\lib\site-packages\torch__init__.py in 84 from torch._C import * 85 ---> 86 all += [name for name in dir(C) 87 if name[0] != '' and 88 not name.endswith('Base')]
  5. NameError: name '_C' is not defined

建议从pytorch官网的历史版本中下载1.9.0之前版本,实测1.4.0可以解决

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/Gausst松鼠会/article/detail/359329
推荐阅读
相关标签
  

闽ICP备14008679号