add vqa for label and unlabel

This commit is contained in:
2025-08-18 19:49:41 +00:00
parent c35a1621b2
commit 228fa8c81b
5 changed files with 1637381 additions and 3 deletions

File diff suppressed because it is too large Load Diff

346664
data/vq_nolabel_psycho.json Normal file

File diff suppressed because it is too large Load Diff

520697
data/vqa_label.json Normal file

File diff suppressed because it is too large Load Diff

476441
data/vqa_multi_turn_label.json Normal file

File diff suppressed because it is too large Load Diff

View File

@@ -459,13 +459,13 @@ if __name__ == "__main__":
parser.add_argument("--system_prompt", type=str, default="/home/nguyendc/phong-dev/distillation/easydistill/mmkd/dev-vqa/qa_bank/unstructured_prompt.txt", help="Path to the system prompt text file.")
parser.add_argument("--questions", type=str, default="/home/nguyendc/phong-dev/distill/prompt/question_bank.json", help="Path to the question bank JSON file.")
parser.add_argument("--answers", type=str, default="/home/nguyendc/phong-dev/distill/prompt/answer_bank.json", help="Path to the answer bank JSON file.")
parser.add_argument("--output", type=str, default="/home/nguyendc/phong-dev/distill/vqa_multi_turn_nolabel.json", help="Path to save the output VQA conversations JSON file.")
parser.add_argument("--output", type=str, default="/home/nguyendc/phong-dev/distillation/data/vqa_label.json", help="Path to save the output VQA conversations JSON file.")
parser.add_argument("--ratio", type=float, default=0.4, help="Ratio of fields to sample for questions (default: 0.4).")
args = parser.parse_args()
# Single-turn, field-by-field conversations WITH labels
# generate_vqa_conversations(args.labels, args.image_root, args.system_prompt, args.questions, args.answers, args.output, args.ratio)
generate_vqa_conversations(args.labels, args.image_root, args.system_prompt, args.questions, args.answers, args.output, args.ratio)
# Use this for multi-turn conversations WITH labels based on field groups
# generate_multiturn_conversations(args.labels, args.image_root, args.system_prompt, args.questions, args.answers, args.output)
@@ -474,4 +474,4 @@ if __name__ == "__main__":
# generate_vq_question(args.image_root, args.system_prompt, args.questions, args.output, args.ratio)
# Use this for multi-turn question-only prompts for unlabeled images
generate_multiturn_vq_question(args.image_root, args.system_prompt, args.questions, args.output)
# generate_multiturn_vq_question(args.image_root, args.system_prompt, args.questions, args.output)