The meaning of "most" for visual question answering models

The correct interpretation of quantifier statements in the context of a visual scene requires non-trivial inference mechanisms . For the example of “ most ” , we discuss two strategies which rely on fundamentally different cognitive concepts . Our aim is to identify what strategy deep learning models for visual question answering learn when trained on such questions . To this end , we carefully design data to replicate experiments from psycholinguistics where the same question was investigated for humans . Focusing on the FiLM visual question answering model , our experiments indicate that a form of approximate number system emerges whose performance declines with more difficult scenes as predicted by Weber ’ s law . Moreover , we identify confounding factors , like spatial arrangement of the scene , which impede the effectiveness of this system . 1 INTRODUCTION . Deep learning methods have been very successful in many natural language processing tasks , ranging from syntactic parsing to machine translation to image captioning . However , despite significantly raised performance scores on benchmark datasets , researchers increasingly worry about interpretability and indeed quality of model decisions . We see two distinct research endeavors here , one being more pragmatic , forward-oriented , and guided by the question “ Can a system solve this task ? ” , the other being more analytic , reflective , and motivated by the question “ How does a system solve this task ? ” . In other words , the former aspires to improve performance , while the latter aims to increase our understanding of deep learning models . By ‘ understanding ’ here we mean observing a reasoning mechanism that , if not resembling human behavior , at least is cognitively plausible . This is by no means necessary for practically solving a task , however , we highlight two reasons why being able to explain model behavior is nonetheless important : On the one hand , cognitive plausibility increases confidence in the abilities of a system – one is generally more willing to rely on a reasonable than an incomprehensible mechanism . On the other hand , pointing out systematic shortcomings inspires systematic improvements and hence can guide progress . Moreover , particularly in the case of a human-centered domain like natural language , ultimately , some degree of comparability to human performance is indispensable . In this paper we are inspired by experimental practice in psycholinguistics to shed light on the question of how deep learning models for visual question answering ( VQA ) learn to interpret statements involving the quantifier “ most ” . We follow Pietroski et al . ( 2009 ) in designing abstract visual scenes where we control the ratio of the objects quantified over and their spatial arrangement , to identify whether VQA models exhibit a preferred strategy of verifying whether “ most ” applies . Figure 1 illustrates how visual scenes can be configured to favor one over another mechanism . We want to emphasize the experimental approach and its difference to mainstream machine learning practice . For different interpretation strategies , conditions are identified that should or should not affect their performance , and test instances are designed accordingly . By comparing the accuracy of subjects on various instance types , predictions about a subject ’ s performance for these mechanisms can be verified and the most likely explanation identified . Note that our advocated evaluation methodology is entirely extrinsic and does not constrain the system in any way ( like requiring attention maps ) or require a specific framework ( like being probabilistic ) . Psychology as a discipline has focused entirely on questions around how humans process situations and arrive at decisions , and consequently has the potential to inspire a lot of experiments ( like ours ) for investigating the same questions in the context of machine learning . Similar to psychology , we advocate the preference of an artificial experimentation environment which can be controlled in detail , over the importance of data originating from the real world , to arrive at more convincing and thus meaningful results . Artificial data has a history in deep learning of establishing new techniques – most prominently , LSTMs were introduced by showing their ability to handle various formal grammars ( Gers & Schmidhuber , 2001 ) – and our higher-level goal with this paper is to demonstrate the potential for more informative evaluation of machine learning models in general . This is motivated by our belief that , in the long term , true progress can only be made if we do not just rely on the narrative of neural networks “ learning to understand/solve ” a task , but can actually confirm our theories experimentally . Taking inspiration from psychology seems particularly appropriate in the context of powerful deep learning models , which recently are not infrequently described by anthropomorphizing words like “ understanding ” , and compared to “ human-level ” performance . 2 THE MEANING OF “ MOST ” . In this section we will introduce the two mechanisms of interpreting “ most ” , discuss cognitive differences and implications , and introduce relevant cognitive concepts . 2.1 GENERALIZED QUANTIFIERS AND “ MOST ” . “ Most ” has a special status in linguistics due to the fact that it is the most prominent example of a quantifier whose semantics can not be expressed in first-order logic , while other simple natural language quantifiers like “ some ” , “ every ” or “ no ” directly correspond to the quantifier primitives ∃ and ∀ ( plus logical operators ∧ , ∨ and ¬ ) . This situation is not just a matter of introducing further appropriate primitives , but requires a fundamental extension of the logic system and its expressivity . In the following , by x we denote an entity , A and B denote predicates ( “ square ” , “ red ” ) , A ( x ) is true if and only if x satisfies A , and SA = { x : A ( x ) } is the corresponding set of entities satisfying this predicate ( “ squares ” ) . Thus we can define the semantics of “ some ” and “ every ” : some/every ( A , B ) ⇔ ∃/∀x : A ( x ) ⇒ B ( x ) ( 1 ) Importantly , these definitions do not involve the concept of set cardinality and indeed can be formulated without involving sets . This is not possible for “ most ” , which is commonly defined in one of the following ways : most ( A , B ) ⇔ |SA∧B| > 1/2 · |A| ⇔ |SA∧B| > |SA∧¬B| ( 2 ) This makes “ most ” an example of a generalized quantifier , and in fact all generalized quantifiers can be defined in terms of cardinalities , indicating the apparent importance of a cardinality concept to human cognition . 2.2 ALTERNATIVE CHARACTERIZATION . There is another way to define “ most ” which uses the fact that whether two sets are equinumerous can be determined without a concept of cardinality , based on the idea of a bijection : A↔ B : ⇔ ∀x : [ A ( x ) ⇔ B ( x ) ] ( 3 ) ⇔ |SA| = |SB| ( 4 ) The definition of equinumerosity can be generalized to “ more than ” ( and , correspondingly , “ less than ” ) , which lets us define “ most ” as follows : most ( A , B ) ⇔ ∃S ( SA∧B : S↔ SA∧¬B ( 5 ) Although , at a first glance , this definition looks similar to the one above , it can be seen as suggesting a different algorithmic approach to interpreting “ most ” , as we will discuss below . 2.3 TWO INTERPRETATION STRATEGIES . The two characterizations of “ most ” are of course truth-conditionally equivalent , that is , every situation in which one of them holds , the other holds , and vice versa . In particular , if we are just interested in solving a task involving “ most ” statements , we can be agnostic about which definition our system prefers . Nevertheless , the subtle differences between these two characterizations suggest different algorithmic mechanisms of verifying or falsifying such statements , meaning that a system processes a visual scene differently to come to the ( same ) conclusion about a statement ’ s truth . Characterization ( 2 ) represents the cardinality-based strategy of interpreting “ most ” : 1 . Estimate the number of entities satisfying both predicates ( “ red squares ” ) and the number satisfying one predicate but not the other ( “ non-red squares ” ) . 2 . Compare these number estimates and check whether the former is greater than the latter . We want to add that , actually , the two definitions in ( 2 ) already suggest a minor variation of this mechanism – see Hackl ( 2009 ) for a discussion on “ most ” versus “ more than half ” . However , we do not focus on this detail here , and assume the second variant in ( 2 ) to be ‘ strictly ’ simpler in the sense that both involve estimating and comparing cardinalities , but the first variant additionally involves the rather complex operation of halving one number estimate . Characterization ( 5 ) utilizes the concept of a bijection , which is a comparatively simple pairing mechanism and as such could be imagined to be a primitive cognitive operation . This gives us the pairing-based strategy of interpreting “ most ” : 1 . Successively match entities satisfying both predicates ( “ red squares ” ) uniquely with entities satisfying one predicate but not the other ( “ non-red squares ” ) . 2 . The remaining entities are all of one type , so pick one and check whether it is of the first type ( “ red square ” ) . 2.4 COGNITIVE IMPLICATIONS . Finding evidence for one strategy over the other has substantial implications with respect to the ‘ cognitive abilities ’ of a neural network model . In particular , evidence for a cardinality-based processing of “ most ” suggests the existence of an approximate number system ( ANS ) , which is able to simultaneously estimate the number of objects in two sets , and perform higher-level operations on the resulting number representations themselves , like the comparison operation here . Explicit counting would be an even more accurate mechanism here , but neither available to the subjects in the experiments of Pietroski et al . ( 2009 ) due to very short scene display time , nor likely to be learned by the ‘ one-glance ’ feed-forward-style neural network we evaluate in this work1 . 1By “ one-glance feed-forward-style networks ” we refer to the predominant type of network architecture which , by design , consists of a fixed sequence of computation steps before arriving at a decision . In particular , such models do not have the ability to interact with their input dynamically depending on the complexity of an instance , or perform more general recursive computations beyond the fixed recurrent modules built into their design . Important for the discussion here is the fact that precise – in contrast to approximate or subitizing-style – counting is by definition a recursive ability , thus impossible to learn for such models . The ANS ( see appendix in Lidz et al . ( 2011 ) for a summary ) is an evolutionary comparatively old mechanism which is shared between many different species throughout the animal world . It emerges without explicit training and produces approximate representations of the number of objects of some type . They are approximate in the sense that their number judgment is not ‘ sharp ’ , but resulting behavior exhibits variance – like interpreting “ most ” statements with a cardinality-based strategy , as described above . This variance follows Weber ’ s law which states that the discriminability of two quantities is a function of their ratio2 . The precision of the ANS is thus usually indicated by a characteristic value called Weber fraction which relates quantity and variance . The ANS of a typical adult human is often reported to have a Weber fraction of 1.14 or , more tangibly , it can distinguish a ratio of 7:8 with 75 % accuracy . Finding evidence for the emergence of a similar system in deep neural networks indicates that these models can indeed learn and utilize more abstract concepts ( approximate numbers ) than mere superficial pattern matching ( “ red squares ” etc ) . Both mechanisms to interpret “ most ” suggest conditions in which they should perform well or badly . For the cardinality-based one , the difference in numbers of the two sets in question is expected to be essential : smaller differences , or greater numbers for the same absolute difference , require more accurate number estimations and hence make this comparison harder , according to Weber ’ s law . The pairing-based mechanism , on the other hand , is likely affected by the spatial arrangement of the objects in question : if the objects are more clustered within one set , pairing them with objects from the other set becomes harder . Importantly , these conditions are orthogonal , so each mechanism should not substantially be affected by the other condition , respectively . By constructing ( artificial ) scenes where one of the conditions dominates the configuration , and measuring the accuracy of being able to correctly interpret propositions involving “ most ” , the expected difficulties can be confirmed ( or refuted ) and thus indicate which mechanism is actually at work . Using this methodology , Pietroski et al . ( 2009 ) show that humans exhibit a default strategy of interpreting “ most ” , at least when only given 200ms to look at the scene and hence having to rely on an immediate subconscious judgment . This strategy is based on the approximate number system and the cardinality-based mechanism . Moreover , the behavior is shown to be sub-optimal in some situations where humans would , in principle , be able to perform better if deviating from their default strategy . Since machine learning models are trained by optimizing parameters for the task at hand , it is far from obvious whether they learn a similarly stable default mechanism , or instead follow a potentially superior adaptive strategy depending on the situation . While the latter is likely more efficient in solving at least a narrowly defined task , the former would instead suggest that the system is able to acquire and utilize core concepts like an approximate number system . We may speculate about the innate preference of modern network architectures for either of the strategies : Most of the visual processing is based on convolutions which , being an inherently local computation , we assume would favor the pairing-based strategy via locally matching and ‘ cancelling out ’ entities of the two predicates . On the other hand , the tensors resulting from the sequence of convolution operations are globally fused into a final embedding vector , which in turn would support the more globally aggregating cardinality-based strategy . However , the type of computations and representations learned by deep neural networks are poorly understood , making such speculations fallacious . We thus emphasize again that the higher-level motivation for this paper is to demonstrate how we need not rely on such speculative ‘ narratives ’ , but can experimentally substantiate our claims .

Summary: This paper studies how the FiLM visual question answering (VQA) model answer questions involving the quantifier ‘most’. This quantifier is chosen for study because it cannot be expressed in first order logic (i.e., high-order logic is required), and secondly because there are two different algorithmic approaches to answering questions involving ‘most’ (cardinality-based strategy and pairing-based strategy). Experiments are performed by designing abstract visual scenes with controlled numerosity and spatial layouts, and applying methodologies from pyscholinguistics. The paper concludes that the model learns an approximate number system (ANS), consistent with the cardinality-based strategy, with implications for understanding the conditions under which existing VQA models should perform well or badly (and possibly for improving VQA models).