Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EOFError: Compressed file ended before the end-of-stream marker was reached (on Google Colab)? #24

Open
Alla-Abdella opened this issue Apr 1, 2021 · 0 comments

Comments

@Alla-Abdella
Copy link

This is my code to open the data:

jsonfilename = "/content/v1.0-simplified_nq-dev-all.jsonl.gz"
with gzip.open(jsonfilename, 'r') as fin:
data = json.loads(fin.read().decode('utf-8'))

However, I'm getting this error:
EOFError Traceback (most recent call last)
in ()
8 jsonfilename = "/content/v1.0-simplified_nq-dev-all.jsonl.gz"
9 with gzip.open(jsonfilename, 'r') as fin:
---> 10 data = json.loads(fin.read().decode('utf-8'))

1 frames
/usr/lib/python3.7/gzip.py in read(self, size)
491 break
492 if buf == b"":
--> 493 raise EOFError("Compressed file ended before the "
494 "end-of-stream marker was reached")
495

EOFError: Compressed file ended before the end-of-stream marker was reached

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant