修改:进到torch._six源码,看看里面是PY的哪个对象,修改成这对象名试试

_six.py

即将PY3修改为PY37

AttributeError: module 'torch._six' has no attribute 'PY3'的更多相关文章

  1. AttributeError: module 'scipy.misc' has no attribute 'imread'

    运行python程序报错:AttributeError: module 'scipy.misc' has no attribute 'imread' 报错原因1:scipy版本过高 解决方案:降低sc ...

  2. ansible报错AttributeError: module 'urllib.request' has no attribute 'HTTPSHandler'

    报错内容: TASK [activemq : extract activemq tarball] *************************************************** ...

  3. AttributeError: module 'html.parser' has no attribute 'HTMLParseError'

    别人说这种错误大多是,因为beautifulsoup的版本兼容问题, 因为beautifulsoup的4.0以下版本和4.0版本与python3.5以上都不兼容, 网上的解决方案大多是:降python ...

  4. Tensorflow机器学习入门——AttributeError: module 'scipy.misc' has no attribute 'toimage'

    这个bug的解决办法: import cv2 # scipy.misc.toimage(image_array).save('cifar10_data/raw/%d.jpg' % i) cv2.imw ...

  5. pycharm最新版新建工程没导入本地包问题:module 'selenium.webdriver' has no attribute 'Firefox'

    前言 最新版的pycharm做了很大的改变,新建工程的时候,默认不导入本地的安装包,这就导致很多小伙伴踩坑了... 明明已经pip安装过selenium了,但是却报AttributeError:mod ...

  6. Python报错module 'scipy.misc' has no attribute 'xxx'

    Python报错module 'scipy.misc' has no attribute 'imresize' 解决办法: 安装Pillow包,命令如下: pip install Pillow 然后重 ...

  7. pytorch版本问题:AttributeError: 'module' object has no attribute '_rebuild_tensor_v2'

    用pytorch加载训练好的模型的时候遇到了如下的问题: AttributeError: 'module' object has no attribute '_rebuild_tensor_v2' 到 ...

  8. python中引入包的时候报错AttributeError: module 'sys' has no attribute 'setdefaultencoding'解决方法?

    python中引入包的时候报错:import unittestimport smtplibimport timeimport osimport sysimp.reload(sys)sys.setdef ...

  9. Python脚本报错AttributeError: ‘module’ object has no attribute’xxx’解决方法

    最近在编写Python脚本过程中遇到一个问题比较奇怪:Python脚本完全正常没问题,但执行总报错"AttributeError: 'module' object has no attrib ...

  10. attributeError:'module' object has no attribute ** 解决办法

    写了一个小脚本,执行的时候报错: Traceback (most recent call last): File "F:/test/qrcode.py", line 109, in ...

随机推荐

  1. mongoengine模型字段非严格校验FieldDoesNotExist

    背景 最近需要从mongoDB中查询数据用于数据分析,一开始就用了pymongo后来发现使用起来很不方便,后面了解到有类似SQLAlchemy的ORM模块mongoengine能够操mongo 简单看 ...

  2. Window下载并安装WinSCP客户端

    winSCP官方网站:https://winscp.net/eng/docs/lang:chs. 环境 操作系统:Window 10 企业版LTSC;内存:8GB;操作类型:64位. 步骤 1. 打开 ...

  3. Ubuntu 20.04 部署kubernetes 网络组件calico-v3.2.1

    1.官方网址: https://projectcalico.docs.tigera.io/archive/v3.21/getting-started/kubernetes/self-managed-o ...

  4. 逆向学习物联网-网关ESP8266-01硬件原理及平台搭建

    1.系统原理 2.ESP8266网关的内部原理框图 1)STM32通过COM2以AT指令与ESP-01进行通讯,实现MQTT协议, 2)将COM3收到的JSON数据,透明传输到云端 3)通过COM2收 ...

  5. Git系列 -> git commit 报错 “Invalid syntax in configuration ini file.”

    git commit 报错 提示信息为 "Invalid syntax in configuration ini file." 解决办法: 方法一:使用-n or --no-ver ...

  6. nginx服务器下的TP5框架的虚拟域名配置

    server { listen 80; default_type 'text/html'; charset utf-8; server_name www.xxx.com; root /usr/loca ...

  7. python中json的四个方法总结dumps、dump、loads、load

    json的四个方法总结dumps.dump.loads.load dump介绍 1 json .作用:将python内置类型序列化为json对象后写入文件.参数:要存储的数据以及可以用于存储的文件对象 ...

  8. springboot 整合内存缓存Caffeine

    springboot 整合内存缓存Caffeine 1.引jar包 <dependency> <groupId>org.springframework.boot</gro ...

  9. 关于在Eclipse中使用EclEmma

    在LAB2中,要求使用EclEmma来统计JUnit测试用例的代码覆盖度.下面就来说说如何进行基本的使用来应付实验(bushi). 在这给出完全体,可以访问下面的网址进行学习. http://www. ...

  10. 【项目记录】4:Pycharm激活方法

    引用一下: 今天给大家带来一种全新的Pycharm安装激活方式.可以激活到2099年. 安装 1.我们首先进入idea官网 jetbrains.com 找到最新版本的pycharm,这里就以windo ...