[Paper Review] Learning to Reason: End-to-End Module Networks for Visual Question Answering
This paper introduces End-to-End Module Networks (N2NMNs) that learn to predict instance-specific network layouts from questions and perform visual question answering using a set of attentional neural modules. It demonstrates strong gains on CLEVR and competitive results on VQA by end-to-end training with supervised pretraining and reinforcement learning.
Natural language questions are inherently compositional, and many are most easily answered by reasoning about their decomposition into modular sub-problems. For example, to answer "is there an equal number of balls and boxes?" we can look for balls, look for boxes, count them, and compare the results. The recently proposed Neural Module Network (NMN) architecture implements this approach to question answering by parsing questions into linguistic substructures and assembling question-specific deep networks from smaller modules that each solve one subtask. However, existing NMN implementations rely on brittle off-the-shelf parsers, and are restricted to the module configurations proposed by these parsers rather than learning them from data. In this paper, we propose End-to-End Module Networks (N2NMNs), which learn to reason by directly predicting instance-specific network layouts without the aid of a parser. Our model learns to generate network structures (by imitating expert demonstrations) while simultaneously learning network parameters (using the downstream task loss). Experimental results on the new CLEVR dataset targeted at compositional question answering show that N2NMNs achieve an error reduction of nearly 50% relative to state-of-the-art attentional approaches, while discovering interpretable network architectures specialized for each question.
Motivation & Objective
- Address compositional reasoning in visual question answering by learning to decompose questions into sub-tasks without relying on external parsers.
- Predict instance-specific network layouts from questions and assemble neural modules accordingly.
- Jointly train layout policy and module parameters end-to-end, using both supervised (behavioral cloning) and reinforcement learning signals.
- Show that modular, attention-driven architectures improve interpretability and performance on compositional VQA benchmarks.
Proposed method
- Introduce a library of neural modules (find, relocate, and, or, filter, describe, etc.) that operate on image attention maps and textual features.
- Represent each module as a parameterized function that consumes zero, one, or two attention maps plus image and question features.
- Predict a question-specific layout expressed in Reverse Polish Notation via a sequence-to-sequence RNN with soft attention over question words to generate module parameters.
- Assemble and execute the network described by the predicted layout to produce an answer.
- Train end-to-end by optimizing an expected loss over layouts using policy gradient with a baseline to reduce variance, and optionally pretrain via behavioral cloning from expert layouts.
- Utilize soft attention over question words to supply module-specific textual parameters instead of hard-coded word assignments.
Experimental results
Research questions
- RQ1Can an end-to-end learned layout policy predict effective module layouts for each question without relying on an external parser?
- RQ2Do soft-attention based textual parameters for modules improve flexibility and performance over fixed textual parameters?
- RQ3Does end-to-end training (with or without initial supervised cloning) yield interpretable, question-tailored reasoning architectures and improved QA accuracy on compositional VQA tasks?
- RQ4Can the approach achieve state-of-the-art results on CLEVR and competitive results on VQA datasets?
Key findings
- On CLEVR, the model achieves strong gains, including near-expert performance with behavioral cloning and substantial improvements with policy search, outperforming several baselines.
- On shapes data, behavioral cloning yields 100% accuracy and policy search from scratch achieves 96.19%.
- On CLEVR test set, the method with policy search after cloning reaches 83.7% overall accuracy, outperforming previous NMN baselines and many non-modular approaches.
- On VQA, the model with cloning expert or policy search after cloning achieves competitive accuracy, surpassing NMN and D-NMN and approaching MCB results under similar visual features.
- The approach yields interpretable, instance-specific network layouts and modular architectures that adapt to each question.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.