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

modelscope/reason_step_huge/reason_extraction_v6.py#L42 load non json file failed #2

Open
Claber opened this issue May 26, 2023 · 1 comment

Comments

@Claber
Copy link
Collaborator

Claber commented May 26, 2023

this file is actually not a json file:( each single line is in json-format, but the the whole thing is not)
https://github.com/lil-lab/nlvr/blob/master/nlvr2/data/test1.json

then this will definitely always fail:
https://github.com/lonestar234028/nlvr/blob/main/modelscope/reason_step_huge/reason_extraction_v6.py#L42

@Claber
Copy link
Collaborator Author

Claber commented May 26, 2023

and there is no such a key "images" in each json line.
https://github.com/lonestar234028/nlvr/blob/main/modelscope/reason_step_huge/reason_extraction_v6.py#L70
"
69 v = ann[i]
70 images = v['images']

    img_key = v['sentence'] + '##' + '##'.join(images)
    text = prompt.strip()

"
line example in (https://github.com/lil-lab/nlvr/blob/master/nlvr2/data/test1.json):
{
"validation": {
"28": "False"
},
"sentence": "There is an empty glass.",
"left_url": "http://xxxx.jpg",
"writer": "103",
"label": "False",
"right_url": "https://yyyy.jpg",
"synset": "beer bottle",
"query": "group of beer bottles41",
"identifier": "test1-0-1-0",
"extra_validations": {
"56": "False",
"83": "False",
"19": "False",
"92": "False"
}
}

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