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

json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1) #28

Closed
rrsun opened this issue Jun 10, 2021 · 1 comment

Comments

@rrsun
Copy link

rrsun commented Jun 10, 2021

Hi, when I run the script with the provided demo command:

python scripts/embed.py --ids data/sample.ids --metadata data/sample-metadata.json --model ./model.tar.gz --output-file output.jsonl --vocab-dir data/vocab/ --batch-size 16 --cuda-device 0

I get this error, and I don't know how to fix it. Could you please give me some advice?

Traceback (most recent call last):
File "specter/predict_command.py", line 226, in
run()
File "specter/predict_command.py", line 222, in run
main(prog="allennlp")
File "specter/predict_command.py", line 216, in main
args.func(args)
File "specter/predict_command.py", line 160, in _predict
predictor = _get_predictor(args)
File "specter/predict_command.py", line 149, in get_predictor
overrides=args.overrides)
File "e:\ding-project\specter and gender\specter\src\allennlp\allennlp\models\archival.py", line 214, in load_archive
config = Params.from_file(os.path.join(serialization_dir, CONFIG_NAME), overrides)
File "e:\ding-project\specter and gender\specter\src\allennlp\allennlp\common\params.py", line 492, in from_file
overrides_dict = parse_overrides(params_overrides)
File "e:\ding-project\specter and gender\specter\src\allennlp\allennlp\common\params.py", line 168, in parse_overrides
return unflatten(json.loads(evaluate_snippet("", serialized_overrides, ext_vars=ext_vars)))
File "E:\ProgramData\Anaconda3\envs\specter\lib\json_init
.py", line 348, in loads
return _default_decoder.decode(s)
File "E:\ProgramData\Anaconda3\envs\specter\lib\json\decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "E:\ProgramData\Anaconda3\envs\specter\lib\json\decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)

@rrsun rrsun closed this as completed Jun 13, 2021
@gokul427
Copy link

were you able to resolve this issue?

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

2 participants