Open Nice-Zhang66 opened 4 hours ago
Hello, you need to replace
You can see the path in this image, I followed the format of train_monkey.json and wrote the json file with my own image and the corresponding comments, but I still get the above error when reading into the code.
很感谢您的回复,我在尝试用我自己的图片集和对应的注释对Monkey进行微调,但是按照您的train_monkey.json的格式编写了我自己的json文件,但是进行训练还是会报错
Wenbo Zhang | |
---|---|
@. | ---- Replied Message ---- | From | @.> | | Date | 9/25/2024 12:52 | | To | @.> | | Cc | @.>, @.***> | | Subject | Re: [Yuliang-Liu/Monkey] TypeError: list indices must be integers or slices, not str (Issue #144) |
Hello, you need to replace
image.png (view on web)
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
Can you use the following code to read train_monkey.json and output the value? Will using the provided train_monkey.json cause this error?
import json
path = "train_monkey.json"
with open(path,"r") as f:
data = json.load(f)
print(data[0]['conversations'][1]['value'])
Hello author, I encountered an error while reproducing the code, I just used the link to download the json file in your readme to train and pointed to train_monkey.json with --data_path, but the error is reported as follows: "TypeError: list indices must be integers or slices, not str."