Comments (3)
Traceback (most recent call last):
File "debug.py", line 15, in
predictor = Predictor.from_path('/mnt/cephfs/home/zhihongyan/VLN/DUET/datasets/elmo')
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/predictors/predictor.py", line 364, in from_path
plugins.import_plugins()
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/common/plugins.py", line 79, in import_plugins
import_module_and_submodules(
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/common/util.py", line 362, in import_module_and_submodules
import_module_and_submodules(subpackage, exclude=exclude)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/common/util.py", line 351, in import_module_and_submodules
module = importlib.import_module(package_name)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/importlib/init.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1014, in _gcd_import
File "", line 991, in _find_and_load
File "", line 975, in _find_and_load_unlocked
File "", line 671, in _load_unlocked
File "", line 843, in exec_module
File "", line 219, in _call_with_frames_removed
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/commands/init.py", line 32, in
from allennlp.commands.checklist import CheckList
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/commands/checklist.py", line 22, in
from allennlp.confidence_checks.task_checklists.task_suite import TaskSuite
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/confidence_checks/task_checklists/init.py", line 4, in
from allennlp.confidence_checks.task_checklists.task_suite import TaskSuite
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/allennlp/confidence_checks/task_checklists/task_suite.py", line 9, in
from checklist.perturb import Perturb
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/checklist/perturb.py", line 7, in
from pattern.en import tenses
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/pattern/text/en/init.py", line 61, in
from pattern.text.en.inflect import (
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/pattern/text/en/init.py", line 80, in
from pattern.text.en import wordnet
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/pattern/text/en/wordnet/init.py", line 57, in
nltk.data.find("corpora/" + token)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/data.py", line 555, in find
return find(modified_name, paths)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/data.py", line 542, in find
return ZipFilePathPointer(p, zipentry)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/compat.py", line 41, in _decorator
return init_func(*args, **kwargs)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/data.py", line 394, in init
zipfile = OpenOnDemandZipFile(os.path.abspath(zipfile))
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/compat.py", line 41, in _decorator
return init_func(*args, **kwargs)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/site-packages/nltk/data.py", line 935, in init
zipfile.ZipFile.init(self, filename)
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/zipfile.py", line 1269, in init
self._RealGetContents()
File "/mnt/cephfs/home/zhihongyan/anaconda3/envs/vlnduet_probe/lib/python3.8/zipfile.py", line 1336, in _RealGetContents
raise BadZipFile("File is not a zip file")
zipfile.BadZipFile: File is not a zip file
from allennlp.
I believe we've encountered this before. It's an issue with race conditions in NLTK when it tries to download the same corpora from two processes at the same time. You end up with a corrupted download. Try this:
# Remove existing corrupted NLTK downloads
rm -rf ~/nltk_data
# Re-download everything
python -c 'import nltk; [nltk.download(p) for p in ("wordnet", "wordnet_ic", "sentiwordnet", "omw", "omw-1.4")]'
from allennlp.
This issue is being closed due to lack of activity. If you think it still needs to be addressed, please comment on this thread 👇
from allennlp.
Related Issues (20)
- The DataLoader Needs to Handle Dirty Examples. HOT 8
- AllenNLP biased towards BERT HOT 12
- will update to support latest pytorch? HOT 9
- Rich 12.1.0 has been yanked, but has been pinned in `requirements.txt` HOT 1
- Incompatibile packages HOT 2
- Unclear how to use text2sql model HOT 5
- Can't load models with .zip extension HOT 2
- AllenNLP-Light! 🎉 🙂 HOT 2
- Is it possible to load my own quantized model from local HOT 3
- Questions about start training from checkpoint using --recover HOT 1
- Is it possible to load my own quantized model from local HOT 9
- SRL BERT performing poorly for german dataset HOT 1
- Remove upper bounds for requirements HOT 1
- Alternative semantic role labeling model HOT 3
- AutoTokenizer config error when load clipmodel HOT 2
- When 'instances_per_epoch' is set up in the class MultiTaskDataLoader, the function __len__ in it will return a wrong answer. HOT 1
- New version with upper bounds on dependencies removed HOT 2
- Incomplete model_state_epoch files HOT 1
- allennlp.common.checks.ConfigurationError: key "token_embedders" is required at location "model.text_field_embedder." HOT 3
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 allennlp.