Varying levels of numerical cognition have been found in several animal species. Bees, in particular, have been argued to be able to count up to four items and solve complex numerical tasks. Here we present an exceedingly simple neural circuit that, when provided with the actual visual input that the bee is receiving while carrying out the task, can make reliable estimates on the number of items in the display. Thus we suggest that the elegance of numerical problem solving in bees might not lie in the formation of numerical concepts (such as “more,” “less,” or “zero”), but in the use of specific flight movements to scan targets, which streamlines the visual input and so renders the task of counting computationally inexpensive. Careful examination of the actual inspection strategies used by animals might reveal that animals often employ active scanning behaviors as shortcuts to simplify complex visual pattern discrimination tasks.

Here we explore how serial processing reduces the size of the neural hardware required for basic counting. It seems likely that bees cannot extract complex visual pattern properties “at a glance” (); they inspect pattern elements from up close () and one by one (). If such an inspection strategy is indeed universal, it has profound implications for the complexity of visual tasks. We present a simple abstract model of only four neural units that, when provided with the responses that known low-level visual neurons would produce during such a sequential scan, is able to match the bees' performance in a complex numerical ordering task (). The output of this network is sufficient to distinguish between numerosities up to 4–6, produces an appropriate response to an empty set (“zero”), and reproduces Weber's law of number discriminability.

However, how complex is numerical cognition in neurocomputational terms? Computer vision algorithms, often based on convolutional neural networks, are abundantly used for counting objects in images and offer a good starting point for addressing this question (e.g.,and references therein). Most of these algorithms rely on object detection and then count the detected instances, but because such methods explicitly make use of symbolic mathematics, they are not accessible for animal brains. However, computer vision has also proved that it is possible to reliably estimate object count without detecting and localizing individual object instances, using, for example, image density (). As for the size of the neural network necessary,proposed a formal model of only 480 neural units (plus 50 input units) to account for the elementary numerical abilities of infants and animals. This model is able to extract approximate numerosity from images, up to five items. It seems likely that the perception of numerosity is a basic attribute of visual systems () and emerges spontaneously when neural networks are trained to encode statistical properties of images ().

Dijkstra, K., van de Loosdrecht, J., Schomaker, L.R.B., and Wiering, M.A. (2018). CentroidNet: A deep neural network for joint object localization and counting. Conference: The European Conference on Machine Learning and Principles and Practice of Knowledge Discovery in Databases.

Numerical cognition is traditionally considered a higher cognitive ability, perhaps because of its association with the most advanced human intellectual achievements. The symbolic, language-based mathematics we use, however, appears to be rooted in a predisposition to use quantitative information without symbolic representation, which exists in pre-verbal infants and in cultures that do not use symbols for counting (). A growing body of experiments demonstrates that a wide range of animals possess a similar “number sense.” Not only birds () and mammals () or other large-brained animals but also fish, frogs/toads, and even insects with miniature brains were shown to be able to make decisions based on numerosity (reviewed in). Bees, in particular, exhibit counting-like abilities and can be trained to search for food after a given number of landmarks () or on the stimulus with a given number of items (), and can use the number of items as the decision criteria in a match-to-sample task (). Recently, honeybees have been argued to even understand numerical concepts of “less than,” “greater than,” and “zero” as a number ().

We then turned our attention to a recent study in which bees succeeded in numerical ordering tasks (including an adequate response to zero), which was interpreted by the authors as indicating that bees form concepts of “less than,” “greater than,” and “zero” (). The flight paths were not recorded in this article, compelling us instead to assume an idealized flight path based on the scanning rules described in, one that passes over each item once, at a hovering distance of 2 cm. The decision to land on the feeder is determined by the value of the “evaluation” neuron after completing the scan. For the “less than” task, the decision to land would be guided by a high value, whereas the “more than” task would be guided by a lower value. Note that the network does not compare two sets of stimuli; instead, a decision is made concerning each stimulus independently based on its overall score. We simulated the input to the neural network that could result from flying a scanning path and calculated the output from the “evaluation” neuron to predict the probability of choosing a pattern. For the stimuli used in, the model's numerosity estimations match the performance of the bees ( Figure 3 and Table S1 —“less than” task; for the “more than” task, see Table S1 ). The model's accuracy when choosing from two stimuli follows Weber's law, which states that accuracy is expected to improve with numerical distance. Finally, the model reliably rates “zero” (an empty sheet) over other numbers in the “less than” task. Our counting network actually outperformed the behavior of real bees; they failed at choosing zero over two in the original experiment.

(B) If the bee chooses patterns to scan randomly and lands with a likelihood directly proportional to the state of the “evaluation neuron” at the end of the scan, the distribution of landings on zero versus other numerosities follows Weber's law of number discriminability (as found in). Note that this decision rule does not involve comparing two stimuli.

(A) The evaluation given by the model for the stimuli used inshows a decreasing response with increasing numerosity. Each stimulus contains a varying number (0–6) of differently shaped (circle, triangle, or square) items. 1, 3, 15, or 21 individual patterns per number were used. The dots represent the “evaluation” responses to each pattern, the black lines indicate their means, and the gray areas depict the standard deviations. We assumed the bee scans each pattern by flying over each item once, as described in

The model reproduces the choices of the bee in a complex numerical ordering task from, including the preference for the empty stimulus (“zero”) and an increasing success of discrimination with increasing numerical distance

Our network outputs an estimate of the numerosity that can be used to solve a number of different types of quantification tasks (counting, equals to, less than, or more than) depending on how the “evaluation” neuron's response is interpreted in decision making. For the “choose two not four” task from, we employed the rule that the bee is prompted to leave the stimulus if the “evaluation” neuron's response falls below a critical level (approximately 0.8 here). This can happen if the bee has passed over more items than she is looking for (>3 items here) and when she has been searching for the sugar reward without success long enough for the working memory to degrade. We also assume that the bee would land on the stimulus should she complete a scan without being prompted to abandon it. In either event, the decision to leave or find the sugar reward will reset the network by inhibiting both the “brightness working memory” and the “counting working memory” neurons. Using these assumptions, we find that the model reliably predicts the rejections and landings shown inbased on the visual input during its flight path ( Figure 2 ). The same model outputs can be used for selecting “higher number” or “greater” by inverting the decision rule, i.e., the bee should leave the stimulus after finishing the scan but lands on it once the evaluation falls below the threshold. Moreover, the same method can be used to address landmark counting (). Here, the bee is viewing large landmarks from a distance, instead of small items from close up; the behavioral rule is to interrupt flight and land when the “evaluation” neuron's response falls below a threshold.

The flight path of the bee, and the resulting visual input sequence, is crucial for generating a correct evaluation. A recent experiment () analyzed the bees' flight trajectories when choosing between patterns with different number of elements and concluded that bees inspect pattern elements sequentially, flying over each item once. Moreover, bees keep very close to the pattern during scanning (). We assumed a 1–2 cm viewing distance; from this distance, our wide-field neuron's receptive field of 60° only covers 1.2–2.3 cm in diameter of the stimulus. Thus its input is akin to a moving spotlight across the pattern ( Figure 2 ).

(C) The responses of the “brightness” neuron (gray line), “brightness working memory” neuron (dotted line), the “counting working memory” neuron (dashed line), and the “evaluation” neuron (black line) for the flight path shown in (A). Decisions to land on a stimulus (light gray arrow) are made when the scan is finished (there are no more items in sight) and the response of the “evaluation” neuron is high (above approximately 0.8 here). Decisions to leave the stimulus (black arrows) are triggered when the “evaluation” falls below a threshold (approximately 0.8 here). When the bee decides to leave a stimulus, the network is reset, and it is reactivated once the bee has left the stimulus.

(B) Example set of visual input to the model during scanning. From a short distance, with limited field of view, the visual input is akin to moving a spotlight across the image.

(A) The flight path of a bee trained to choose two items and not four items. The bee inspects each item one by one, flying over them at a distance of 1–2 cm. During training, the bee was rewarded with sugar solution hidden in a hole in the middle of the correct stimulus (indicated by a small circle). When a stimulus is chosen, the bee hovers in front of the hole, trying to feed from it; when rejected, she leaves the stimulus without trying to feed. Reproduced from

Using realistic visual input and following simple rules for interpreting the evaluation provided by the neural network, the model can provide enough information to reproduce the decisions the bee made in the counting task from

Our simple model ( Figure 1 ) employs just four independent neural units (which we will refer to as neurons for simplicity). It is able to mimic the counting abilities of bees—provided that it receives sequential visual input of the countable items. The first neuron is a wide-field (60° visual angle) neuron that sums up the responses of a collection of phasic on-off narrow-field cells of the medulla (). Neurons with similar response properties have been found in the second and third visual ganglia (medulla and lobula) of insects (). This phasic “brightness” neuron responds to changes in brightness within its receptive field. The model is not limited to this specific type of input but will provide comparable results when using input from a global brightness detector or an edge detector ( Figure S1 ). The “brightness working memory” neuron receives strong excitatory input from the “brightness” neuron and feeds back to itself; thus its response will be close to maximum when the bee encounters a change in light intensity. The “counting working memory” neuron also feeds back to itself, but it is only weakly stimulated by the “brightness” neuron; thus its response will be proportional to the number of times the bee has moved between dark and bright areas. Note that numbers are not registered as integers, but accumulated as magnitudes (as in the approximate number system described in humans for estimating numerosities higher than 4;). Finally, the “evaluation” neuron is excited by the “brightness working memory” neuron and inhibited by the “counting working memory” neuron. The “evaluation” neuron thus accumulates information about the stimulus while the bee is inspecting it, and so this neuron provides a continuously updating evaluation of the numerosity of the stimulus ( Figure 1 ).

The phasic “brightness” neuron extracts the change in brightness from the visual input. The working memory neurons in the second layer are recurrent and thus maintain exponentially decaying memory traces. The “brightness working memory” neuron receives strong input from the “brightness” neuron, and signals recent changes in brightness. The “counting working memory” neuron receives weak input from the “brightness” neuron, and so accumulates information about the changes in brightness over a longer period. Finally, the “evaluation” neuron subtracts the “counting working memory” from the “brightness working memory.” Its response is inversely proportional to the number of brightness changes, and, with the right visual input, it provides an online evaluation of the numerosity of the stimulus.

The temporal tuning of the Drosophila motion detectors is determined by the dynamics of their input elements.

Discussion

Erber et al., 1980 Erber J.

Masuhr T.

Menzel R. Localization of short-term memory in the brain of the bee, Apis mellifera. Menzel, 1999 Menzel R. Memory dynamics in the honeybee. Douglass and Strausfeld, 2003 Douglass J.K.

Strausfeld N.J. Retinotopic pathways providing motion-selective information to the lobula from peripheral elementary motion-detecting circuits. Haag and Borst, 2001 Haag J.

Borst A. Recurrent network interactions underlying flow-field selectivity of visual interneurons. Liu et al., 2006 Liu G.

Seiler H.

Wen A.

Zars T.

Ito K.

Wolf R.

Heisenberg M.

Liu L. Distinct memory traces for two visual features in the Drosophila brain. Stone et al. (2017) Stone T.

Webb B.

Adden A.

Weddig N.B.

Honkanen A.

Templin R.

Wcislo W.

Scimeca L.

Warrant E.

Heinze S. An anatomically constrained model for path integration in the bee brain. Eichler et al., 2017 Eichler K.

Li F.

Litwin-Kumar A.

Park Y.

Andrade I.

Schneider-Mizell C.M.

Saumweber T.

Huser A.

Eschbach C.

Gerber B.

et al. The complete connectome of a learning and memory centre in an insect brain. Grünewald, 1999 Grünewald B. Morphology of feedback neurons in the mushroom body of the honeybee, Apis mellifera. The location of visual working memory in the bee brain is unknown. For olfactory learning, the antennal lobes have been identified as most likely sites for working memory/early short-term memory (); the most likely analog sites in the visual pathway would be in the medulla or lobula. In the medulla, recurrently wired neurons might exist in the serpentine layer (); in the lobula, in the inner layers (). There is evidence that in flies some short-term memory traces are stored in the central complex (); for bees,put forward an argument for a recurrent microcircuit serving as the memory unit in the path integrator in the central complex. The linear neurons we used here are capable of less computation than a more complex spiking neuron, and even if we need to scale up the number of working memory neurons an order of magnitude to counterbalance neural noise, the necessary tens of neurons would still fit easily in the optic lobes or the central complex. Two simple working memory circuits, each of which receives the same input only weighted differently, may be easily co-opted for counting by neurons in the mushroom body (; represented in our model as one “evaluation” neuron). To summarize, neurons of the types that are required for our simple theoretical model do exist in the insect brain. Although it is likely that more than four neurons are involved in real counting tasks (perhaps with multiple similar circuits operating in parallel), such circuitry would still not be prohibitively expensive to be accommodated in an insect brain.

Paulk et al., 2008 Paulk A.C.

Phillips-Portillo J.

Dacks A.M.

Fellous J.-M.

Gronenberg W. The processing of color, motion, and stimulus timing are anatomically segregated in the bumblebee brain. Paulk et al., 2009b Paulk A.C.

Dacks A.M.

Phillips-Portillo J.

Fellous J.-M.

Gronenberg W. Visual processing in the central bee brain. The advantage of explicitly outlining a possible neural architecture is that such a model yields testable predictions. Our model makes the following predictions (among others). (1) The counting circuit we proposed relies on inputs from the color blind motion pathway, and so expected to use only long-wavelength-sensitive receptor inputs and be color blind as well (). (2) The signal of the working memory circuit that acts as an “item counter” degrades exponentially with time; thus introducing delays during a scan is expected to cause the bee to underestimate numerosity. (3) We propose that the bee tailors her scan to the stimulus, in a way that keeps input noise to the minimum; forcing the bee to an altered scan route (e.g., viewing the stimulus from a larger distance than ideal) should degrade the performance. (4) The model makes the decision to land on a stimulus based on its numerosity, without directly comparing two stimuli. With appropriate tuning, this decision rule is enough to reliably choose the smaller or the larger numerosity but cannot be used to choose the middle number from three numbers; thus bees should fail at his task.

Chittka and Skorupski, 2017 Chittka L.

Skorupski P. Active vision: a broader comparative perspective is needed. Dawkins and Woodington, 2000 Dawkins M.S.

Woodington A. Pattern recognition and active vision in chickens. Gegenfurtner, 2016 Gegenfurtner K.R. The interaction between vision and eye movements. Chittka et al., 2012 Chittka L.

Rossiter S.J.

Skorupski P.

Fernando C. What is comparable in comparative cognition?. In comparative cognition, there is little value in rating cognitive task difficulty based on how difficult it is using symbolic human-like thinking. What is worthy of our attention is the repertoire of innate and learnt behavioral routines that animals employ while completing the task, and the complexity of the task in terms of neurocomputation. Within this framework we have shown that counting and numerical ordering are computationally inexpensive, provided the animal employs an active, sequential scanning of pattern elements. Here we studied the scanning behavior of bees; similarly simple computational solutions may underpin numerical cognition in other animals that employ active scanning (e.g.,). Furthermore, we have shown that counting does not need to rely on the internal representation of concepts. Sequential scanning drastically reduces the demand for the neural hardware required to solve the task. We conclude that active scanning behavior could play a major role in even the most complex cognitive tasks. Future studies in comparative cognition should benefit from shifting the focus from what an animal can do to how it does it and explore the intricacies of the sequential decision-making process ().