Pretrain file load problem.
JiachengLi1995 opened this issue · 5 comments
Hi,
When I load pretrain text file 'exclude_fewrel_distant.json', I encounter the following problem:
JSONDecodeError: Expecting ':' delimiter: line 1 column 25283907 (char 25283906)
Problems in the file? Thanks for your help.
Can you show me your code and more log? I can load the json file normally.
data = json.load(open('exclude_fewrel_distant.json',encoding='utf8'))
I use the above code to load the file. And got the following error:
`JSONDecodeError Traceback (most recent call last)
in
----> 1 data = json.load(open('exclude_fewrel_distant.json',encoding='utf8'))
~\Anaconda3\lib\json_init_.py in load(fp, cls, object_hook, parse_float, parse_int, parse_constant, object_pairs_hook, **kw)
297 cls=cls, object_hook=object_hook,
298 parse_float=parse_float, parse_int=parse_int,
--> 299 parse_constant=parse_constant, object_pairs_hook=object_pairs_hook, **kw)
300
301
~\Anaconda3\lib\json_init_.py in loads(s, encoding, cls, object_hook, parse_float, parse_int, parse_constant, object_pairs_hook, **kw)
352 parse_int is None and parse_float is None and
353 parse_constant is None and object_pairs_hook is None and not kw):
--> 354 return _default_decoder.decode(s)
355 if cls is None:
356 cls = JSONDecoder
~\Anaconda3\lib\json\decoder.py in decode(self, s, _w)
337
338 """
--> 339 obj, end = self.raw_decode(s, idx=_w(s, 0).end())
340 end = _w(s, end).end()
341 if end != len(s):
~\Anaconda3\lib\json\decoder.py in raw_decode(self, s, idx)
353 """
354 try:
--> 355 obj, end = self.scan_once(s, idx)
356 except StopIteration as err:
357 raise JSONDecodeError("Expecting value", s, err.value) from None
JSONDecodeError: Expecting ':' delimiter: line 1 column 25283907 (char 25283906)
`
I used the file from Google Drive. I opened the file and check the JSON format and found some problems with formatting.
Could you also download it from Google Drive to see if there is any problem with that file? Thank you!
I download another file from Tsinghua Cloud. Use the same code and found that I can correctly load in.
So I think there are some problems with your file from Google Drive. Please update it. Thank you.
Jiacheng
Thank you for finding the problem, I will update the data on Google Drive.
I'm getting the same error again. Can I ask how this was fixed?
I've downloaded the pre-train file twice so far.
json.decoder.JSONDecodeError: Expecting ':' delimiter: line 1 column 25283907 (char 25283906)