![](https://img-blog.csdnimg.cn/4b0324056fb949f0aecf4eb89739f07b.png?x-oss-process=image/resize,m_fixed,h_224,w_224)
Debug
文章平均质量分 77
记录平时代码中遇到的各种花式bug解决方法,跟我一起斩妖杀魔吧......
zy_destiny
一名天天向上的程序媛
展开
-
【Debug】报错 a view of a leaf Variable that requires grad is being used in an in-place operation
yolov5训练初始化模型参数报错RuntimeError: a view of a leaf Variable that requires grad is being used in an in-place operation.解决方案原创 2024-02-29 17:00:17 · 1744 阅读 · 0 评论 -
【debug】报错Assertion input_val >= zero && input_val <= one解决
一大串../aten/src/ATen/native/cuda/Loss.cu:118: operator(): block: [10,0,0], thread: [33,0,0] Assertioninput_val >= zero && input_val原创 2023-12-14 09:57:08 · 1266 阅读 · 0 评论 -
【mmseg】ValueError: Only one of `max_epochs` or `max_iters` can be set.报错解决
mmseg工程报错“ValueError: Only one of `max_epochs` or `max_iters` can be set.”解决方案及源码解析原创 2023-11-28 13:50:48 · 979 阅读 · 0 评论 -
【git】pip install git+https://github.com/xxx/xxx替换成本地下载编译安装解决网络超时问题
报错信息:Running command git clone --filter-blob:none --quiet https://github.com/openai/(lIgit /tmp/pip-reg-build-r7wizorc。解决方案:本地下载编译安装原创 2023-11-23 18:04:52 · 3637 阅读 · 1 评论 -
【conda】conda create 环境报错CondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://conda.anaconda.o
conda创建虚拟环境报错CondaHTTPError: HTTP 000 CONNECTION FAILED for url原创 2023-11-23 15:29:43 · 8923 阅读 · 14 评论 -
【DEBUG】报错RuntimeError: Trying to resize storage that is not resizable和DataLoader worker (pid xxx) 解决
报错 RuntimeError in DataLoader worker process 0和DataLoader worker (pid xxx) is killed by signal: Killed.解决方案原创 2023-10-24 17:52:52 · 4462 阅读 · 0 评论 -
【debug】目标检测任务报错TypeError: Argument ‘bb‘ has incorrect type (expected numpy.ndarray, got list)
pycocotools 包处调用coco.py 报错TypeError: Argument 'bb' has incorrect type (expected numpy.ndarray, got list)报这个错误是传入的segment点是四个以内(包含四个)的会触发的错误。找到环境安装位置的coco.py文件,修改420行,增加条件判断就好了✔️。整理不易,欢迎一键三连!原创 2023-09-15 09:10:35 · 680 阅读 · 0 评论 -
【debug】解决RecursionError: maximum recursion depth exceeded in comparison报错
RecursionError: maximum recursion depth exceeded in comparison报错解决递归次数超限问题原创 2023-08-28 17:23:33 · 3911 阅读 · 0 评论 -
【conda install】网络慢导致报错CondaHTTPError: HTTP 000 CONNECTION FAILED for url
CondaHTTPError: HTTP 000 CONNECTION FAILED for url报错解决原创 2023-08-28 14:02:53 · 2742 阅读 · 0 评论 -
【debug】NCCL error in: ../torch/csrc/distributed/c10d/ProcessGroupNCCL.cpp:1191, unhandled system err
mmseg工程单机多卡可以顺利运行训练,切换到多机多卡训练就报错。原创 2023-08-18 18:01:47 · 6400 阅读 · 1 评论 -
【debug】报错RuntimeError: CUDA error: an illegal memory access was encountered
mmseg工程报错RuntimeError: CUDA error: an illegal memory access was encountered解决。原创 2023-08-07 10:04:37 · 2911 阅读 · 0 评论 -
【debug】python代码报错std::bad_alloc
报错terminate called after throwing an instance of 'std::bad_alloc' what(): std::bad_alloc解决原创 2023-08-03 17:59:35 · 965 阅读 · 0 评论 -
【debug】报错RuntimeError: can‘t start new thread解决
跑PyTorch 的深度学习的代码,之前跑没有问题,换了一台服务器,遇到这个bug报错:RuntimeError: can't start new thread,原因是测试的时候线程开得太多了,导致软件开始,不再能够被处理,卡死。原创 2023-07-18 11:25:14 · 5910 阅读 · 5 评论 -
【debug】mmseg工程训练报错:CUDA kernel errors might be asynchronously reported at some other API call ...
CUDA kernel errors might be asynchronously reported at some other API call,so the stacktrace below might be incorrect报错解决。原创 2023-06-05 14:01:05 · 33141 阅读 · 9 评论 -
【debug】一个Epoch前几个batch正常训练,最后一个batch的数据不足报错
在模型训练过程中,一个epoch的前几轮batch数据可以正常训练输出loss,在最后一轮batch数据报错,大概率就是数据量和epoch不匹配,导致最后一个batch的数据不能被整除,所以导致该问题。删除最后一个batch的数据,不参与训练,具体的操作是在定义dataloader的时候,设置drop_last参数为True。手动将epoch的参数调整一下,保证num-data/ batchz-size= epoch中的所有参数均为整数。整理不易,欢迎一键三连!原创 2023-06-05 09:56:54 · 1070 阅读 · 0 评论 -
【debug】RuntimeError: cuDNN error: CUDNN_STATUS_INTERNAL_ERROR
报错RuntimeError: cuDNN error: CUDNN_STATUS_INTERNAL_ERROR解决原创 2023-04-07 16:17:42 · 1525 阅读 · 2 评论 -
【debug】报错ValueError: <COMPRESSION.LZW: 5> requires the ‘imagecodecs‘ package
报错ValueError: requires the 'imagecodecs' package。缺少包imagecodecs,安装下即可。原创 2023-03-20 11:15:44 · 2396 阅读 · 0 评论