
ERROR
文章平均质量分 79
codebrid
公众号:NLP_codebrid | NLP笔记屋
展开
-
faiss问题记录
当我执行一个脚本时,报错: import faissModuleNotFoundError: No module named 'faiss'遂:pip install faiss autofaiss -i https://pypi.tuna.tsinghua.edu.cn/simple再次执行脚本,报错: import faiss File "/Users/sunzhuo02/anaconda3/envs/torch_py37/lib/python3.7/site-pack...原创 2022-03-08 17:32:45 · 3059 阅读 · 0 评论 -
【ERROR】Floating point exception
问题出现:在使用旧版本的paddle(v2)时,使用from sklearn.metrics import f1_score计算多分类时,仅macro时出现这种报错报错原因:非法运算,如分母为0参考博客:https://blog.youkuaiyun.com/yyangzhenjie/article/details/87859506内在原因:因为 macro算法为求出每个实体的PRF再求平均,存在某个实体的PRF值计算时分母为0的情况。sklearn.metrics用法参考:h...原创 2020-09-10 17:34:05 · 4822 阅读 · 0 评论 -
【ERROR】TypeError: expected bytes, Descriptor found
起因:帮我可爱的妹子在windows电脑上,尝试跑通一个tensorflow的GAN代码报错信息:TypeError: expected bytes, Descriptor found出错位置:Traceback (most recent call last): File "<stdin>", line 1, in <module>...原创 2019-12-06 16:55:49 · 20482 阅读 · 21 评论 -
【ERROR】AttributeError: 'BatchNorm2d' object has no attribute 'track_running_stats'
起因:一份很久之前(2018年)的项目代码image caption,今天想重新运行模型测试文件,却出现了如下错误报错信息:AttributeError: 'BatchNorm2d' object has no attribute 'track_running_stats'报错位置: File "/users4/zsun/pytorch/paper_image_...原创 2019-12-01 22:51:54 · 2342 阅读 · 1 评论 -
【ERROR】AssertionError: The NVIDIA driver on your system is too old (found version). Please upd
错误信息:AssertionError:The NVIDIA driver on your system is too old (found version 10000).Please update your GPU driver by downloading and installing a newversion from the URL: http://www.nvidia.com...原创 2019-11-13 15:26:45 · 11982 阅读 · 6 评论 -
【error】旧版本的torchtext会出现的问题
出错代码:torch.save(vocab_en, opt.vocab_path)或pickle.dump(dict(vocab_en), open(opt.vocab_path,'wb'))都会报pickle的错误其中from torchtext import dataEN = data.Field(init_token=EOS, eos_token=EOS, lo...原创 2019-11-10 15:28:59 · 2349 阅读 · 0 评论 -
【error】 RuntimeError: Expected object of scalar type Byte but got scalar type Int for sequence elmen
错误:RuntimeError: Expected object of scalar type Byte but got scalar type Int for sequence elment 1 in sequence argument at position #1 'tensors'出错位置:valid = 1 - src.data.eq(padding_idx)pad =...原创 2019-10-24 20:45:31 · 1547 阅读 · 0 评论 -
【RuntimeError】the derivative for 'target' is not implemented
报错信息:Traceback (most recent call last): File "/users/anaconda3/lib/python3.6/site-packages/torch/nn/modules/module.py", line 489, in __call__ result = self.forward(*input, **kwargs) File "/...原创 2019-05-27 22:19:52 · 13036 阅读 · 3 评论 -
【ERROR】关于训练时以及开发集上loss丝毫不变的原因
记录一次马虎导致的BUG事情起因:最新在跑项目的代码,一切都好好的,直到我突发奇想加了个新model之后,一切诡异了起来。。。代码逻辑是每训练一轮会在开发集上测三次,然后log打印每次测出的loss以及PRF指标,在改了model之后,在每一次打印的log中所有的数值都丝毫没有变化。。。出现问题:训练时以及开发集上loss丝毫不变这说明了虽然模型每一轮都在训练,...原创 2019-07-13 20:28:20 · 2848 阅读 · 3 评论 -
【RuntimeError】Gather got an input of invalid size【DataParallel问题】
错误:错误发生在DataParallelordata_parallel()时RuntimeError: Gather got an input of invalid size: got [32, 7, 15013], but expected [32, 6, 15013] (gather at /pytorch/torch/csrc/cuda/comm.cpp:239出错位置...原创 2019-07-13 15:34:53 · 3042 阅读 · 0 评论