Comments (7)
Traceback (most recent call last):
File "bert.py", line 655, in
main()
File "bert.py", line 545, in main
args.local_rank), num_labels=len(label_list))
File "/home/zhaohaoran/anaconda3/lib/python3.7/site-packages/pytorch_pretrained_bert/modeling.py", line 573, in from_pretrained
archive.extractall(tempdir)
File "/home/zhaohaoran/anaconda3/lib/python3.7/tarfile.py", line 2002, in extractall
numeric_owner=numeric_owner)
File "/home/zhaohaoran/anaconda3/lib/python3.7/tarfile.py", line 2044, in extract
numeric_owner=numeric_owner)
File "/home/zhaohaoran/anaconda3/lib/python3.7/tarfile.py", line 2114, in _extract_member
self.makefile(tarinfo, targetpath)
File "/home/zhaohaoran/anaconda3/lib/python3.7/tarfile.py", line 2163, in makefile
copyfileobj(source, target, tarinfo.size, ReadError, bufsize)
File "/home/zhaohaoran/anaconda3/lib/python3.7/tarfile.py", line 247, in copyfileobj
buf = src.read(bufsize)
File "/home/zhaohaoran/anaconda3/lib/python3.7/gzip.py", line 276, in read
return self._buffer.read(size)
File "/home/zhaohaoran/anaconda3/lib/python3.7/_compression.py", line 68, in readinto
data = self.read(len(byte_view))
File "/home/zhaohaoran/anaconda3/lib/python3.7/gzip.py", line 482, in read
raise EOFError("Compressed file ended before the "
EOFError: Compressed file ended before the end-of-stream marker was reached
from bert_chinese_pytorch.
from bert_chinese_pytorch.
这个看上去感觉是下载下来的压缩文件解压失败 可能是下载的文件不完整或者是已经存在要下载但是没下载完的文件报的错,可以试试删除你的bert pretrained下载的那部分内容,对应的是from_pretrained方法中cache_dir这个目录
from bert_chinese_pytorch.
from_pretrained
可是cache文件夹我已经删除重下好几次了
from bert_chinese_pytorch.
我甚至创建了一个新的用户来从头下载包运行程序,但是没变化
from bert_chinese_pytorch.
更换一个cache目录呢?
from bert_chinese_pytorch.
可能是我给数字化的标签加引号了,感觉这个错误在这里并不仅是模型错误触发的
from bert_chinese_pytorch.
Related Issues (9)
- 您好问个问题,参数里没分类个数 HOT 13
- 如何使用已训练好的output_dir下的model,而不是每次都do_train? HOT 3
- > 不过现在好像在
- 请教.json文件的具体张什么样啊 HOT 1
- 报错__init__() missing 1 required positional argument: 'num_labels' HOT 1
- 您好,请问‘’Weights of BertForSequenceClassification not initialized from pretrained model: ['classifier.weight', 'classifier.bias']‘’这种情况您碰到过吗,这样权重无法加载,预训练模型的意义也发挥不出来。 HOT 1
- Error:'model' not found
- example转feature
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bert_chinese_pytorch.