TensorX
返回文献探索

Paper · arXiv 2306.05392

Modular Visual Question Answering via Code Generation

Sanjay Subramanian, Medhini Narasimhan, Kushal Khangaonkar, Kevin Yang, Arsha Nagrani, Cordelia Schmid, Andy Zeng, Trevor Darrell, Dan Klein

2 upvotesJune 8, 2023arXiv 预印本
AI 摘要

A framework generates modular Python code that combines pre-trained visual and language models for visual question answering, improving accuracy on benchmark datasets.

visual question answeringcode generationpre-trained language modelsvisual modelsimage-caption pairsin-context learningCOVR datasetGQA datasetfew-shot baseline

Abstract

We present a framework that formulates visual question answering as modular code generation. In contrast to prior work on modular approaches to VQA, our approach requires no additional training and relies on pre-trained language models (LMs), visual models pre-trained on image-caption pairs, and fifty VQA examples used for in-context learning. The generated Python programs invoke and compose the outputs of the visual models using arithmetic and conditional logic. Our approach improves accuracy on the COVR dataset by at least 3% and on the GQA dataset by roughly 2% compared to the few-shot baseline that does not employ code generation.

北京市昌平区探索星信息技术及软件开发工作室

京ICP备2026059466号