UWIN graduate fellow Thomas Mohren and UWIN faculty Bing Brunton, Steve Brunton, and Tom Daniel published a paper in PNAS (Proceedings of the National Academy of Sciences of the United States of America) on how flying insects can detect changes in their flight patterns using only a few complex sensors. In order to navigate quickly in complex situations, insects require rapid feedback from the multitude of sensors found on their wings, antennae, and other body parts. The paper, titled “Neural-inspired sensors enable sparse, efficient classification of spatiotemporal data,” describes how insects use both the location of the sensors and the temporal history of the wing motions to sense body rotations.
The researchers use computer models to investigate how insect sensors help detect disturbances. They found a few vital pieces in the insects intake and processing mechanisms. The temporal filter, which modifies environmental inputs with relation to the history of the wings, alongside a non-linear transformation of the received signal at every sensor was crucial for the detection of rotations. These two input modifications, as well as the precise layout of sensors across the wing made it so only a few sensors were required for this detection. The group of researchers believe the principle of neural encoding and sparse placement of sensors hold promise for man-made system. they are now working to implement biologically inspired sensors into robotic platforms.
UWIN faculty member and Washington Research Foundation (WRF) Innovation Assistant Professor in Neuroengineering Azadeh Yazdan published a paper in eLIFE on how brain stimulation changes the ability of neurons to activate and encourage a learning state. The paper titled “Target cortical reorganization using optogenetics in non-human primates” describes investigations into the large-scale connections between brain regions, testing if the relationship between regions become stronger or weaker with varied stimulation.
When people preform everyday actions, connections occur between the sensory and motor areas in the brain. As this action happens more often, those connections becomes stronger. Strengthening connections allow us to learn new skills, and may be key to relearning skills lost due to a brain injury. While many studies have addressed this idea in individual neurons, the importance of strengthened connections can also be expanded to brain regions. Yazdan used a type of virus with the ability to embed light-sensitive proteins into neurons to modify the neurons of macaque monkeys. This allows for researchers to specifically activate certain neurons in the brain, isolating desired regions for connectivity and investigation. Using a concentrated light, researchers activated small regions of tissue within the brain and measured the activity of the regions electronically, displaying the reaction of the regions. While much of the brain followed the assumption that co-activation strengthens connections between brain areas, smaller brain regions had more variability, with some connections becoming weaker overall.
Using the understanding gained through these experiments, researchers can continue to refine therapies that use brain stimulation, such as those used in Parkinson’s disease. Researchers hope to use the brain’s natural learning and growing process to cure or recover from neurological illness and traumas.
Join us in welcoming UWIN’s newest undergraduate and post-baccalaureate fellows! Nine undergraduate students and six post-baccalaureate researchers were awarded 2019 UWIN Fellowships. You can read all about their exciting research below, and follow the links to see all of UWIN’s undergraduate and post-baccalaureate fellows.
2019 UWIN Undergraduate Fellows
Manjari Anant (2019 fellow) is an undergraduate student in Bioengineering, working with Samira Moorjani in the Physiology and Biophysics department. Manjari’s research focuses on a novel neural stimulation technique called movement-triggered stimulation. She is investigating whether movement-triggered stimulation modulates neuronal connectivity differently based on the original strength of the synaptic connection. If movement-triggered stimulation can strengthen cortical connections, it would have implications in aiding individuals with decreased motor function due to injury, disease or age.
Makoto Eyre (2019 Fellow) is a post-baccalaureate undergraduate student in Mechanical Engineering with a background in architecture (Rhode Island School of Design, Bachelor of Architecture 2014). Working with Kat Steele and Michael Rosenberg of the Ability & Innovation Lab in Mechanical Engineering, Makoto’s research focuses on comparing motor coordination strategies (muscle synergies) employed by the human body during steady state and non-steady state modes of walking, and the effects that the mechanical properties of ankle foot orthoses (AFOs) have on them. The goal of this research is to inform AFO customization for neuromuscular rehabilitation, potentially yielding prescriptions that are optimal across a broader set of daily activities. After his time at the UW, Makoto aims to utilize neuromuscular and biomechanical methods of examining human motion to inform human habitation of outer space.
Nathaniel Linden (2019 fellow) is an undergraduate student in Bioengineering with a minor in Applied Mathematics. He is working with Bing Brunton in the Biology Department. Nathaniel’s research focuses on applying computational techniques to study cortical development in the brain using mouse models. His current project involves developing an analysis pipeline to model neural activity from wide-field calcium imaging data of the developing mouse cortex.
Jon Luntzel (2019 fellow) is an undergraduate student in Computer Science who is working with Michael Beyeler in Psychology and Ariel Rokem in the eScience Institute. Jon’s research focuses on computational models for retinal implants. This research will help clarify how visual aids create visual percepts and progress towards restoring useful vision. Jon intends to contribute a submodule for simulating percepts of subretinal prostheses that interface with the bipolar layer in the retina.
Amanuel Mamo (2019 fellow) is an undergraduate student in Mechanical Engineering working with Tom Daniel in the Biology department. Amanuel is collaborating with Melanie Anderson on the “Smellicopter” project, a bio-inspired odor-guided micro-air vehicle. He is using Robot Operating System (ROS) and controls associated with micro-scale quadrotors to enhance the capabilities of this odor tracking air vehicle.
Kathryn Stangret (2019 fellow) is an undergraduate student intending on majoring in Neuroscience and Bioengineering. She is working with Jeff Ojemann and Courtnie Paschall in the department of Neurosurgery. Kathryn’s research involves analyzing the frequency content of resting state electrocorticography (ECoG) data from people is epilepsy. She is working to determine what connections there are between the frequency domain and the microelectrophysiology studies of epileptic tissue in the brain.
Nicholas Thomas (2019 fellow) is a Bioengineering undergraduate student working with Amy Orsborn in Electrical & Computer Engineering and Bioengineering. Nicholas’ work focuses on implementing real time markerless motion tracking for the study of hand kinematics. This research will help facilitate the study of learning relating to high dimensional movements and object manipulation. Nicholas intends to pursue a Master’s degree in bioengineering upon graduation. Outside of research, he enjoys exploring his passions of both the culinary arts and ceramics.
Joey Ullmann (2019 Fellow) is an undergraduate student in Biology and Psychology working with David Gire in the Laboratory of Comparative Systems Neuroscience. Joey’s research investigates how the integration of octopus sucker mechanical sensory information delegated along the length of an arm modulates the intensity and pattern of localized muscle activity during foraging and exploration. His goal is to derive a model based on localized mechanical sensorimotor feedback loops, which will be informed by the observed patterns of activity within the nerve cord.
Maximilian Walter (2019 Fellow) is an undergraduate student in the Bioengineering department working with Rajiv Saigal in the Neurological Surgery department. Max’s research focuses on developing biodegradable microneedle arrays for controlled drug delivery for the treatment of spinal cord injury. After receiving his bachelor’s degree, he intends to pursue a Masters in Bioengineering at the University of Washington.
2019 UWIN Post-baccalaureate Fellows
Sufia Ahmad (2019 fellow) is a post-baccalaureate researcher working with Beth Buffalo in the Physiology and Biophysics department. Sufia is conducting simultaneous electrophysiological recordings from the dorsolateral prefrontal cortex and medial temporal lobe in awake behaving non-human primates to understand how neurological systems are affected by aging. By using behavioral tasks based on those used in human studies that are sensitive to a diagnosis of Alzheimer’s Disease, she hopes this work may be translated into early diagnostic and treatment therapies for patients with memory deficit disorders. Sufia graduated from Seattle University where she received a Bachelor’s of Science in Psychology..
Evyn Dickinson (2019 Fellow) is a post-baccalaureate researcher working with John Tuthill in Physiology and Biophysics and Bing Brunton in Biology. Evyn’s research focuses on the neural circuitry involved in Drosophila melanogaster (fruit flies) locomotion. He uses optogenetics to manipulate and characterize sensorimotor integration during walking and turning behavior. Evyn graduated from Bowdoin College with Bachelor’s degrees in Biology and French.
Isabelle Hua (2019 fellow) is a post-baccalaureate researcher working with Steve Perlmutter in the Department of Physiology and Biophysics. Isabelle’s research focuses on the use of activity-dependent epidural stimulation in humans to induce spike-timing dependent plasticity to improve motor function recovery following a spinal cord injury. Isabelle attended the University of Washington where she received Bachelor’s degrees in Biochemistry and Neuroscience with departmental Honors.
Briana Smith (2019 fellow) is a post-baccalaureate researcher working with Andrea Stocco and Lori Zoellner in the Psychology department. Briana is investigating emotional trauma and the associated maladaptive cognitive and behavioral conditions that often follow. She is developing a computational model of intrusive memory retrieval patterns symptomatic of post traumatic stress disorder (PTSD). The model aims to follow PTSD recovery curves and accurately represent the neural correlates of intrusive memory retrieval by incorporating individual moderating factors, such as trauma severity, environmental stress, and personal history. Briana graduated from Auburn University with a Bachelor’s degree in Chemical Engineering.
Gg Tran(2019 fellow) is a post-baccalaureate researcher working with Ione Fine and Geoffrey Boynton in the Department of Psychology. Gg’s research uses fMRI data to model the population receptive field (pRF) in people with visual impairments. The goal is to improve estimation of the neural pRF, and subsequently to better predict differences in neural activity in people with normal vision versus in those with vision impairments. She received a Bachelor of Science in Psychology and a minor in Applied Mathematics at the University of Washington.
Willem Weertman (2019 fellow) is a post-baccalaureate researcher working with David Gire in the Laboratory of Comparative Systems Neuroscience in the Psychology department. Willem’s research is focused on understanding how chemical information is integrated within the octopus sucker. The goal of this work is to build a model of chemosensory motor feedback loops within the arm of the octopus. Weertman graduated from the University of Washington with a Bachelor’s of science in Oceanography with a minor in Marine Biology and will begin as a graduate student at Alaska Pacific University in the fall of 2019.
The UWIN seminar series continues in May with a pair of short talks by Kameron Decker Harris and Jeff Ojemann. The seminar is on Wednesday, May 8, 2019 at 3:30pm in Husky Union Builiding (HUB) 337. Refreshments will be served prior to the talks.
” Machine theories of animal learning ” Kameron Decker Harris, Postdoctoral Fellow, Departments of Computer Science & Engineering and Biology, University of Washington
“Cortical plasticity when interfacing with a brain-computer interface” Jeff Ojemann, Professor, Department of Neurological Surgery, University of Washington
Recent work in computational neuroscience highlights the importance of understanding the roles of the “dimensionality” of neural representations. We have some clues that compressing or expanding dimensionality is useful for tasks such as noise removal or learning. I will present a roadmap of my current research, which uses statistical learning theory to explain how dimensionality controls the variance of a neural circuit that carries out associative learning. This theory is well-suited to explaining the functioning of mostly feed-forward neural circuits, such as the mushroom body and cerebellum.
“Cortical plasticity when interfacing with a brain-computer interface” (Jeff Ojemann)
Both motor and sensory cortex have been used to interact with artificial limbs in neuroprosthetic research. Learning occurs during this interaction and results in fascinating changes within the native cortical maps. The changes in both motor and remote cortex during the performance of a brain-computer interface show remarkable remapping in a short time frame. Electrical stimulation of sensory cortex is equally rapidly incorporated into the body representation. Implications for future neuroprosthetics will be discussed.
The focus of this research is on the ability of flying animals to acquire information about the environment and make tiny adjustments with small amounts of data. The researchers look to mimic this ability in algorithms and robotics. Many flying animals have strict constraints on size, weight, and computing power, but can still make precise adjustments with large amounts of environmental data. Brunton is looking to use inspiration from flying animals to work on the flying ability in tiny robots by reducing the amount of data imputed through use of specialized hardware alongside sparse neuronal computations. By investigating the flight constraints and the neural response, the project strives to have broad impacts in designing efficient sensor networks, performing adaptive control of complex systems, and achieving agile flight sensing and control.
Bing Brunton, a Washington Research Foundation Innovation Assistant Professor and UWIN faculty member in Neuroengineering, was featured in a recent College of Arts and Sciences newsletter. The article, titled “What Insects can Teach us about Data,” was published in March of 2019.
Brunton researches the ability of flying insects to make tiny but critical adjustments with small amounts of data. She is specifically working to develop a sparse sensor algorithm to mimic sensors on the wings of a hawk moth. These tiny mechanoreceptor neurons on the moth wings allow the moth to track environmental impacts such as wind and adjust the wings accordingly. By understanding how the these neurons are able to take in data, process it, and produce micro-adjustments in real time, Brunton hopes to determine how to mimic this process artificially.
The April 2019 UWIN seminar series continues with a pair of short talks by Eberhard Fetz and Ramkumar Sabesan. The seminar is on Wednesday, April 10, 2019 at 3:30 in Husky Union Building (HUB) 337. Refreshments will be served prior to the talks.
“Computational models of cortical plasticity induced with brain-computer interfaces” Eberhard Fetz, Professor, Department of Physiology & Biophysics, University of Washington
“Probing spatial and color vision at the resolution of single cone photoreceptors” Ramkumar Sabesan , Research Assistant Professor, Department of Ophthalmology, University of Washington
“Computational models of cortical plasticity induced with brain-computer interfaces” (Eberhard Fetz)
Changes in cortical connectivity have been induced in awake behaving monkeys with head-fixed bidirectional brain-computer interfaces. This talk will discuss results from three experimental protocols that have been modeled: spike-triggered and cycle-triggered stimulation and paired-pulse stimulation. Conditioning results were simulated for the first with an analytical statistical model and for all three with an integrate-and-fire spiking network model.
“Probing spatial and color vision at the resolution of single cone photoreceptors” (Ramkumar Sabesan)
The visual system reconstructs fine spatial detail and rich color experience from a paucity of wavelength and intensity signals originating in the cone mosaic. We use a combination of adaptive optics and high speed eye-tracking to allow light stimuli of multiple wavelengths to be targeted on individual cones. Consequently, visual perception upon controlled activation of a single or a group of cones can be addressed in a living human yielding psychophysical measures ultimately limited by the cone mosaic and downstream retinal and cortical circuitry. I will describe results from a recent set of experiments aimed at outlining the spatial characteristics of color appearance and conclude by framing these results in relation to contemporary models of neural circuitry mediating color and spatial vision.
The March 2019 UWIN seminar series continues in March with an exciting pair of short talks by Wu-Jung Lee and Eric Rombokas.
The seminar is on Wednesday, March 13, 2019 at 3:30 in Husky Union Building (HUB) 337. Refreshments will be served prior to the talks.
“Dissecting the closed-loop feedback in animal echolocation” Wu-Jung Lee, Research Associate, Applied Physics Lab, University of Washington
“Sensory Substitution, Multisensory Conflict, and Body Ownership: Stepping, Seeing, Sensing, Stabbing!” Eric Rombokas , Research Scientist, VA Center for Limb Loss and Mobility; Affiliate Assistant Professor, Mechanical Engineering, University of Washington
“Dissecting the closed-loop feedback in animal echolocation” (Wu-Jung Lee):
The biosonar systems of echo-locating bats and dolphins possess accuracy and efficiency unmatched by human-made sonars. Echolocation is an adaptive process that involves transmitting probing signals and analyzing returning echoes to make decisions about the next set of behaviors. Yet, only until recently have elements of this closed-loop feedback process been considered in a holistic manner in experimental and theoretical studies. In this talk I will discuss the significance of each element of the echolocation feedback and my ongoing work in modeling echolocation-based target search behavior using the infotaxis principle originally developed for odor source localization.
“Sensory Substitution, Multisensory Conflict, and Body Ownership: Stepping, Seeing, Sensing, Stabbing!” (Eric Rombokas):
I will describe three topics we’re working on, providing humans novel sensory stimuli using noninvasive devices. The first is a vibrotactile sensory feedback array that allows people to better estimate their foot (ski boot or prosthetic lower limb) placement on stairs. This will include some early results we’ve observed about sensory capabilities after lower-limb Targeted Reinnervation sugery. The second is a series of visuo-tactile integration experiments in which we experimentally induce spatial conflict in the cues, a sort of “visuotactile 2-point discrimination test.” Finally I’ll describe a body ownership illusion over a virtual reality body during an exciting “stabbing knife game.” We’re exploring the behavioral consequences, as opposed to subjective responses or physiological signals, to feeling these illusions.
This year’s connection drew 160 attendees, with a multitude of talks: four by invited keynote lecturers, four from local UWIN faculty, three talks by senior UWIN/Swartz postdoctoral fellows, and seven talks by senior UWIN and Computational Neuroscience graduate students. Alongside these talks, there were a series of lightning talks by new graduate students and postdoctoral fellows, a poster session, and an ethics panel. Thank you to all who attended and participated!
Day 1: Thursday, January 24, 2019
Day 1 of NCEC kicked off with a poster session over lunch! UW faculty members and students presented their work on a variety of neural engineering and computational neuroscience topics.
“Subject-specific quantification and acceleration of motor learning “
Yamagami looks to improve treatment of individuals with neurologic
injury by analyzing how predictive (feedforward) and reactive (feedback)
controllers change as individuals perform a manual trajectory tracking task.
“Electrophysiological Correlates of Feedback Learning in Humans”
Rice investigates how learning and behavior in target discrimination tasks can be improved through the use of noninvasive neuromodulation of various event-related potentials, such as error- and feedback- related negativity. With this investigation in progress, plans were discussed to apply this research to deeper cortical regions of the brain through trans-cranial magnetic stimulation.
“Continuous long-term recording of sleep in a mouse model of epilepsy”
Sanchez addresses issues with manual long-term sleeps
studies, which are often time-consuming and error-prone, by working to develop
sleep-stage classification algorithms that can parse the stages of rest. The algorithm
currently can detect REM sleep well, and is continuing to be worked on with an
increased training set size.
“Does the mouse see the world like an artificial neural network?”
Shi’s goal is to predict single neuron responses through an artificial
neural network and to compare the responses that occur in a mouse’s visual cortex,
in hopes of gaining insights into how the mouse visual cortex processes natural
“What do patients with retinal prostheses actually see?”
Yucel looks to discover
the experiences of retinal prostheses patients through a series of manipulations
of stimulation protocols, in the process solidifying a few problems in creating
reproduceable percepts. One of these problems revolves around differences in retinal
structure which causes variation in electrode stimulation, producing a variety
of different shapes which are inconsistent from patient to patient.
“Concurrent measurement of olfactory information and behavior tracking during odor-guided navigation”
to study how dynamically varying odor flow guides decision making in animals
who rely on odor as a method of navigation. He uses a network of low-cost, lightweight
sensors to monitor olfactory information in real time, which is then combined
with behavioral tracking of animals.
“Investigating Neural Synchrony Within the Monkey Hippocampus”
Garcia expands the investigation of simultaneous neural firing from rodents to primates in an attempt to determine the mechanisms of memory formation and navigation in primates. This effort revolves around applying non-traditional analysis methods on recorded local field potential from the primate hippocampus.
Keynote Lecture: “He can be a normal child; he couldn’t do that before.”: The potential for therapy-directed neurorecovery after pediatric-onset SCI
In the first keynote lecture, Berhman investigates the status of neurotherapeutic interventions and how the current state of therapies based on activity-dependent plasticity has altered the trajectory of outcomes with acquired spinal cord injuries. By using locomotion training with patients, even if the patient cannot make certain movements voluntarily, the neuromuscular system can learn the correct motor patterns and the spinal cord nerves can learn to fire to encourage voluntary movement. These interventions can decrease scoliosis severity, improve respiratory function, improve ability to sit, and improve trunk control, and with continued research can perhaps reach even further.
Panel Discussion of Ethics in Neuroscience
Day 1 ended with a discussion on the topic of “what are our responsibilities as scientists at the interface of neuroscience, computation, and engineering?” The panel covered many different points including managing data and protecting patient privacy, considering the place neurointerventions have in society, as well as the separation between restoring function and enhancing function.
Panel Speakers (left to right): Mitra Hartmann, Andrea Behrman, Eric Shea-Brown, Abby Person, Maryam Shanechi, Michael Berry, David Perkel, Loren Frank. Panel chair (not pictured): Adrienne Fairhall.
Day 2: Friday, January 25, 2019
Keynote Lecture: “Neural Decoding and Control of Mood to Treat Neuropsychiatric Disorders”
Shanechi works to model and decode mood variations in an effort to create future closed loop therapies which would have the ability to read the brains signal, encode this bio-signal to an electrical one, provide some electrical stimulation as input, and continue to self-modulate to monitor and manage mood. Her current investigations work with creating a model to characterize the bio-signal output by the brain as well as to identify the locations in the brain that are most predictive of mood.
“Advancing Neuroscience through Next-Generation Optical Tools”
Berndt designs a new method
of optimizing new sensor proteins in order to streamline a resource and time-intensive
task of creating tools that have the potential to provide data at high spatial
and temporal resolution. Through a recursive high throughput method consisting of
random mutagenesis, ensuring individual sensor expression, screening in
microarrays, and DNA sequencing of the best performing sensor, Berndt believes the
creation of these sensor proteins will be more efficient.
to transfer the fluid language adaptation of humans to computational modeling
of language through the incorporation of modified variables into the neural network
model of language. These variables include changing discrete variables to continuous,
allowing for words to be related to each other and characterize similarity easier,
as well as various methods of a weighted variable of bias, which allows for multiple
contexts to be considered at once.
Libby works to improve robotics through incorporating the understanding of animal’s complex interactions between behavior and morphology. He emphasizes multi-functionality exhibited in animals and emphasized the need for multi-functionality in robotics in order to reduce the need for isolated movements and highly calculated encounters.
“Decoding motor control to improve movement in cerebral palsy”
Steel examines whether altered motor control limits potential improvements in movement patterns of individuals with cerebral palsy and the implications for their clinical care. Using a simulation model which displays optimal gait for varied synergy levels – varying the ability to co-activate certain muscle groups and display fine motor control – which at the lowest levels optimized to movement patterns similar to those in individuals with cerebral palsy. The lowered synergy levels lowers the ceiling on recovery as even after surgery and rehabilitation, synergy spaces is hard to modify, although in the future, therapy may focus specifically on expanding synergy space.
Keynote Lecture: “Insights into cerebellar control of movement”
Person investigates how cerebellar damage
leads to dysmetric movement through experiments defining the relationship
between cerebellar activity and limb reaching movement in freely behaving mice.
The experimentation supports the idea that the signaling by Purkinje neurons are
used for the feedforward control of the reaching limb.
“Signatures and mechanisms of low-dimensional neural predictive manifolds.”
Recanatesi looks at ability of recent
neural networks to solve sequential processing tasks using predictive modeling
and uses a recurrent artificial neural network model to investigate if the
ability of the hippocampus to guide sequential planning. The recurrent neural network
was trained with predictive learning on a simulated spatial navigation task and
resulted in a series of nonlinearly modified inputs which captured the structure
of the environment, highlighting the predictive aspect of neural representations.
Keshavan addresses the difficulties that have arisen from advances in technology allowing massive amounts of data to be collected, and proposes how using web technology can help neuroscientists manage the big data challenge. Through the use of web-based visualization, collaborative meta-analysis, and citizen science platforms, scientists can address challenges of high data dimensionality, integrating a seemingly endless stream of new results into literature, and scaling decisions made by neuroimaging experts to large data sets.
“Distributed correlates of visually-guided behavior across the mouse brain”
Steinmetz presents recent work studying the neural mechanism of visually-guided behavior in mice by using Neuropixels probes to record the activity of 30,000 neurons over 42 brain regions while mice performed a vision-based behavior task. The work provides a new view on the neural population, showing how neurons in different regions respond differently when making decisions as opposed to when responding to purely visual signals, as well as highlighting how all brain regions are active and working together to respond to a stimulus.
Keynote Lecture: “Whiskers as tactile and flow sensors: linking neuroscience, mechanics, and robotics”
Hartmann studies the use of animal vibrissae (whiskers) in order to sense fluid flow in their environment, and works on applying biological insight to the design of artificial whiskers for tactile and flow sensing. These insights have led to mechanical analysis that also is applied to guide neurophysical experiments in hopes of better understanding both the neuroscience and mechanics of whisker-based sensing.
The February 2019 UWIN seminar features a talk by visiting speaker Adam Calhoun, who is a Postdoctoral Fellow in the Princeton Neuroscience Institute at Princeton University. His talk is titled “Quantitative methods to identify behavioral states”.
The seminar is on Wednesday, February 13, 2019 at 3:30 in Husky Union Building (HUB) 337. Refreshments will be served prior to the talk.
Animals must flexibly alter their responses to stimuli according to changing internal needs or behavioral contexts. This source of behavioral variability is often ignored because we lack of methods that are able to identify the changing internal state of an animal. To address this gap, we have developed a novel unsupervised method to identify internal states and have applied it to the study of a dynamic social interaction. During courtship, Drosophila melanogaster males chase and sing to females and, in a manner analogous to human conversation, the structure of their songs is actively patterned by interactions with the female. We identify the internal states of the male use this new model to identify neural correlates of state switching. Our results reveal how animals compose behavior from previously invisible states, a necessary step for quantitative descriptions of animal behavior that link environmental cues, internal needs, neuronal activity, and motor outputs.