AttributeError: ‘NoneType‘ object has no attribute ‘_free_weak_ref‘

AttributeError: 'NoneType' object has no attribute '_free_weak_ref'

yolov5训练时报错:
AttributeError: 'NoneType' object has no attribute '_free_weak_ref'

问题解决:

降低pytorch版本。

之前使用的是1.11.3,降低成1.10.2

卸载之前的pytorch

复制代码
conda uninstall pytorch
conda uninstall libtorch

安装低版本的pytorch

复制代码
conda install pytorch==1.10.0 torchvision==0.11.0 cudatoolkit=10.2 -c pytorch
相关推荐
专注仿真1 小时前
Agentic RAG算法详解
人工智能·python·大模型训练·控制算法
学习论之费曼学习法1 小时前
无人值守AI内容矩阵实战(8):标题 A/B 实验的 6 个工程实现细节,隔日对比与自动判胜
人工智能·python·算法·矩阵·自动化·a/b测试·内容矩阵
东哥16881 小时前
我用 DeepSeek 做了 4 个零依赖的赚钱小工具,全部开源
python·开源·deepseek
Carl_奕然1 小时前
【机器视觉】最强算法之:3D高斯泼溅(3D Gaussian Splatting)
人工智能·python·算法·目标检测·计算机视觉·3d
小亮_money2 小时前
Agent开发工程师-Python环境搭建
人工智能·python
isfox3 小时前
Python3 线程:多任务并发编程详解
python
Michelle80233 小时前
第1周摸底测试
python
通问AI3 小时前
【实战】企业口径一致性检查:用 Python 对齐官网/招聘平台/投标文件三个来源的成立日期与注册地
开发语言·python
AI直播技术杂谈3 小时前
九点整那场,讲品顺序是前一天下午就锁定的
网络·python·ai·秒播
青少儿编程课堂3 小时前
蓝桥杯青少组·全国青少年信息素养·电子学会Scratch考级:校园智能抢答器项目解析
c++·python·算法·bfs·信息学竞赛