We introduce a method based on machine vision for automatically measuring aggression and courtship in Drosophila melanogaster. The genetic and neural circuit bases of these innate social behaviors are poorly understood. High-throughput behavioral screening in this genetically tractable model organism is a potentially powerful approach, but it is currently very laborious. Our system monitors interacting pairs of flies and computes their location, orientation and wing posture. These features are used for detecting behaviors exhibited during aggression and courtship. Among these, wing threat, lunging and tussling are specific to aggression; circling, wing extension (courtship 'song') and copulation are specific to courtship; locomotion and chasing are common to both. Ethograms may be constructed automatically from these measurements, saving considerable time and effort. This technology should enable large-scale screens for genes and neural circuits controlling courtship and aggression.
This is a preview of subscription content
Subscribe to Journal
Get full journal access for 1 year
only $9.92 per issue
All prices are NET prices.
VAT will be added later in the checkout.
Tax calculation will be finalised during checkout.
Get time limited or full article access on ReadCube.
All prices are NET prices.
Manoli, D.S. et al. Male-specific fruitless specifies the neural substrates of Drosophila courtship behaviour. Nature 436, 395–400 (2005).
Demir, E. & Dickson, B.J. fruitless splicing specifies male courtship behavior in Drosophila. Cell 121, 785–794 (2005).
Stockinger, P., Kvitsiani, D., Rotkopf, S., Tirian, L. & Dickson, B.J. Neural circuitry that governs Drosophila male courtship behavior. Cell 121, 795–807 (2005).
Vrontou, E., Nilsen, S.P., Demir, E., Kravitz, E.A. & Dickson, B.J. fruitless regulates aggression and dominance in Drosophila. Nat. Neurosci. 9, 1469–1471 (2006).
Manoli, D.S., Meissner, G.W. & Baker, B.S. Blueprints for behavior: genetic specification of neural circuitry for innate behaviors. Trends Neurosci. 29, 444–451 (2006).
Callaway, E.M. A molecular and genetic arsenal for systems neuroscience. Trends Neurosci. 28, 196–201 (2005).
Luo, L., Callaway, E.M. & Svoboda, K. Genetic dissection of neural circuits. Neuron 57, 634–660 (2008).
Suh, G.S. et al. A single population of olfactory sensory neurons mediates an innate avoidance behaviour in Drosophila. Nature 431, 854–859 (2004).
Katsov, A.Y. & Clandinin, T.R. Motion processing streams in Drosophila are behaviorally specialized. Neuron 59, 322–335 (2008).
de Bono, M. & Maricq, A.V. Neuronal substrates of complex behaviors in C. elegans. Annu. Rev. Neurosci. 28, 451–501 (2005).
Skrzipek, K.H., Kroner, B. & Hager, H. Inter-male aggression in Drosophila melanogaster—laboratory study. J. Comp. Ethol. 49, 87–103 (1979).
Hoffmann, A.A. A laboratory study of male territoriality in the sibling species Drosophila melanogaster and D. simulans. Anim. Behav. 35, 807–818 (1987).
Chen, S., Lee, A.Y., Bowens, N.M., Huber, R. & Kravitz, E.A. Fighting fruit flies: a model system for the study of aggression. Proc. Natl. Acad. Sci. USA 99, 5664–5668 (2002).
Kravitz, E.A. & Huber, R. Aggression in invertebrates. Curr. Opin. Neurobiol. 13, 736–743 (2003).
Greenspan, R.J. & Ferveur, J.F. Courtship in Drosophila. Annu. Rev. Genet. 34, 205–232 (2000).
Wehrhahn, C., Poggio, T. & Bülthoff, H. Tracking and chasing in houseflies (Musca). Biol. Cybern. 45, 123–130 (1982).
Branson, K. & Belongie, S. Tracking multiple mouse contours (without too many samples). IEEE Computer Vision and Pattern Recognition 1, 1039–1046 (2005).
Khan, Z., Balch, T. & Dellaert, F. MCMC-based particle filtering for tracking a variable number of interacting targets. IEEE Trans. Pattern Anal. Mach. Intell. 27, 1805–1819 (2005).
Veeraraghavan, A., Chellappa, R. & Srinivasan, M. Shape-and-behavior encoded tracking of bee dances. IEEE Trans. Pattern Anal. Mach. Intell. 30, 463–476 (2008).
Fry, S.N., Rohrseitz, N., Straw, A.D. & Dickinson, M.H. TrackFly: virtual reality for a behavioral system analysis in free-flying fruit flies. J. Neurosci. Methods 171, 110–117 (2008).
Wolf, F.W., Rodan, A.R., Tsai, L.T. & Heberlein, U. High-resolution analysis of ethanol-induced locomotor stimulation in Drosophila. J. Neurosci. 22, 11035–11044 (2002).
Valente, D., Golani, I. & Mitra, P.P. Analysis of the trajectory of Drosophila melanogaster in a circular open field arena. PLoS ONE 2, e1083 10.1371/journal.pone.0001083 (2007).
Hoyer, S.C. et al. Octopamine in male aggression of Drosophila. Curr. Biol. 18, 159–167 (2008).
Wang, L., Dankert, H., Perona, P. & Anderson, D.J. A common genetic target for environmental and heritable influences on aggressiveness in Drosophila. Proc. Natl. Acad. Sci. USA 105, 5657–5663 (2008).
Dierick, H.A. A method for quantifying aggression in male Drosophila melanogaster. Nat. Protoc. 2, 2712–2718 (2007).
Bishop, C.M. Pattern Recognition and Machine Learning (Springer, New York) p. 738 (2007).
Johns, D.C., Marx, R., Mains, R.E., O'Rourke, B. & Marban, E. Inducible genetic suppression of neuronal excitability. J. Neurosci. 19, 1691–1697 (1999).
Ferveur, J.F., Stortkuhl, K.F., Stocker, R.F. & Greenspan, R.J. Genetic feminization of brain structures and changed sexual orientation in male Drosophila. Science 267, 902–905 (1995).
Certel, S.J., Savella, M.G., Schlegel, D.C.F. & Kravitz, E.A. Modulation of Drosophila male behavioral choice. Proc. Natl. Acad. Sci. USA 104, 4706–4711 (2007).
Otsu, N. A threshold selection method from gray level histograms. IEEE Trans. Syst. Man Cybern. 9, 62–66 (1979).
We thank K. Watanabe and A. Hergarden for helping prepare the flies, assays, taking video footage of flies as well as collecting ground-truth data. This work was supported by a National Science Foundation Frontiers in Integrative Biological Research grant to M.J. Dickinson, D.J.A. and E. Isacoff, a National Science Foundation National Institutes of Health grant to P.P. and M.J. Dickinson, and a postdoctoral fellowship of the Alexander von Humboldt-Foundation to H.D. We thank M. Heisenberg for sponsoring H.D. in Germany and for sharing information and data regarding aggression arenas and automated assays.
Supplementary Figures 1–6, Supplementary Tables 1–9, Supplementary Methods (PDF 3305 kb)
High-resolution movie clip of a lunge (top view), complementing Figure 3a. (MOV 47 kb)
Movie clip of body and wing tracking during a lunge. (MOV 251 kb)
High-resolution movie clip of tussling (top view), complementing Figure 3b. (MOV 141 kb)
High-resolution movie clip of a wing threat (side view), complementing Figure 3c. (MOV 86 kb)
Movie clip of body and wing tracking during a wing threat. (MOV 564 kb)
High-resolution movie clip of wing extension and circling (top view), complementing Figure 3e. (MOV 185 kb)
Movie clip of body and wing tracking during wing extension and circling. (MOV 2009 kb)
High-resolution movie clip of copulation (side view), complementing Figure 3d. (MOV 762 kb)
High-resolution movie clip of copulation with wing extension and circling (top view), complementing Figure 3d. (MOV 259 kb)
High-resolution movie clip of chasing (top view), complementing Figure 3f. (MOV 742 kb)
Source code of “Caltech Automated Drosophila Aggression-Courtship Behavioral Repertoire Analysis (CADABRA)”. (ZIP 3904 kb)
About this article
Cite this article
Dankert, H., Wang, L., Hoopfer, E. et al. Automated monitoring and analysis of social behavior in Drosophila. Nat Methods 6, 297–303 (2009). https://doi.org/10.1038/nmeth.1310
Deep-learning-based identification, tracking, pose estimation and behaviour classification of interacting primates and mice in complex environments
Nature Machine Intelligence (2022)
Establishment of open-source semi-automated behavioral analysis system and quantification of the difference of sexual motivation between laboratory and wild strains
Scientific Reports (2021)
Lab Animal (2021)
Scientific Reports (2021)
Communications Biology (2021)