New Tech Revolutionizes Monitoring Macaque Behavior
MacqD uses machine learning to improve macaque behavior tracking in research settings.
Genevieve Moat, Maxime Gaudet-Trafit, Julian Paul, Jaume Bacardit, Suliann Ben Hamed, Colline Poirier
― 7 min read
Table of Contents
- The Need for Monitoring Animal Behavior
- The Role of Machine Learning
- Challenges of Tracking Macaques
- Introducing MacqD
- Data Collection
- Annotating the Data
- How MacqD Works
- Experiments to Test MacqD
- Experiment 1: Single Macaque Detection
- Experiment 2: Paired Macaque Detection
- Adding a Tracking Algorithm
- Generalizing MacqD's Performance
- Conclusion
- Original Source
- Reference Links
Monitoring how animals behave is really important for knowing if they're happy and healthy. Traditionally, scientists watched animals in person or went through hours of video footage, which took a lot of time and could be biased. Luckily, technology is stepping in to help with this task. Machine Learning, a kind of technology that lets computers learn and make decisions, is now helping scientists analyze animal behavior more quickly and more accurately.
Primates, especially macaques, are often studied because they are similar to humans in various ways. However, seeing what macaques are up to can be tricky, especially when they are in pairs or are hiding behind objects. To improve this situation, researchers created a new model called MacqD, which is designed to spot macaques in videos, even when they are partially hidden.
The Need for Monitoring Animal Behavior
Understanding animal behavior is essential for many reasons such as ensuring their welfare and studying their brain functions. When we notice how animals act, we can figure out how they're feeling. For example, if a macaque seems stressed or anxious, it can help scientists make changes to their environment to improve their well-being.
But keeping an eye on animal behavior is no small feat. Traditional methods, while useful, require a lot of manual work and can lead to errors. With improved technology, researchers are hoping to simplify this process so they can get accurate insights without spending hours on tedious observations.
The Role of Machine Learning
Machine learning is increasingly used to analyze animal behavior. By using video footage of animals, researchers can train computers to recognize different actions and movements. This means they can process large amounts of data in a fraction of the time it would take a human.
People have used machine learning successfully to track smaller lab animals like mice and flies. However, Tracking larger animals like non-human primates poses additional challenges. To make this happen, scientists need to make sure they can accurately find and follow these animals in videos, even when they are close together or hiding behind objects.
Challenges of Tracking Macaques
Macaques, specifically Rhesus Macaques, are often studied because their brains and behaviors can provide insights relevant to humans. However, tracking them is not as easy as it sounds. They have flexible bodies, tend to move a lot, and can easily be confused with one another, especially if they share similar fur patterns.
In recent attempts to track macaques, some methods focused on recognizing their faces or detecting their bodies in videos. While some of these methods showed promise, they often fell short when things got complicated - like when two macaques were close together or when one was partially hidden.
In short, while there has been progress, the need for a better solution remains.
Introducing MacqD
To tackle these challenges, researchers developed MacqD, a machine learning model built to detect and recognize rhesus macaques from videos taken in their housing environment. MacqD uses a specific kind of technology called Mask R-CNN, which is excellent for identifying objects in images.
MacqD was specially designed to deal with the complexities of studying macaques in their cages, capturing their movements and interactions even in challenging conditions, such as when they are partially hidden or when there are reflections in the glass.
Data Collection
To develop and test MacqD, researchers gathered videos of macaques from a research facility. These videos were recorded with cameras set up to capture their daily activities. The setup was designed to ensure the macaques were in a comfortable environment with plenty of space and things to play with.
Researchers collected a variety of video footage over several years, which included a large number of frames to train and test MacqD effectively. They made sure the footage included different lighting conditions, angles, and scenes to simulate real life accurately.
Annotating the Data
Once the videos were collected, researchers needed to mark the positions of the macaques in each frame. They did this using special tools that allowed them to create outlines around the animals. These markings helped the computer learn where the macaques were and how they were moving.
By having precise Annotations, MacqD could learn better and improve its detection accuracy. The annotations were done carefully, ensuring that they highlighted the macaques in focus and ignored any other animals in the background.
How MacqD Works
MacqD works by analyzing video frames to detect where the macaques are located. It uses advanced algorithms to provide a box around each macaque, ensuring that it can track them effectively. The technique allows it to differentiate between individual animals, even when they're close together or one is partly hidden.
The model operates in two stages: first, it finds areas in the video where macaques could be, and then it zooms in to identify each macaque more precisely. This two-step process helps MacqD achieve accuracy while handling real-life challenges, like occlusions or reflections.
Experiments to Test MacqD
To see how well MacqD performed, researchers conducted a variety of experiments. They tested it on different videos featuring both single macaques and pairs of macaques.
Experiment 1: Single Macaque Detection
In the first experiment, MacqD was put to the test using videos of individual macaques that had previously been used for training. Researchers measured how accurately it could identify each macaque compared to other existing models and methods.
The result was overwhelmingly positive, with MacqD showing high precision and recall rates, meaning it was very effective in spotting the macaques. This experiment helped underline the strengths of MacqD in detecting single macaques accurately, even under difficult conditions.
Experiment 2: Paired Macaque Detection
In the second experiment, the focus shifted to pairs of macaques in the same cage. The challenge here was greater because distinguishing between two moving animals can be tricky.
Researchers again tested MacqD against other models. The results showed that MacqD could still effectively detect both macaques in pairs, demonstrating its robustness in more challenging situations. This success further highlighted MacqD's adaptability and effectiveness.
Adding a Tracking Algorithm
To see if MacqD's performance could be improved even more, researchers decided to add a tracking algorithm. This algorithm helps keep track of where a macaque moves from one video frame to the next. The idea was to reduce missed detections when macaques became briefly hidden.
However, results were mixed. In some scenarios, the tracking improved recall by catching missed detections, while in other cases, it slightly lowered precision due to an increase in false positives. This variation showed that while adding a tracking system could enhance results, it wasn't a one-size-fits-all solution.
Generalizing MacqD's Performance
One of the essential aspects of MacqD is how well it can adapt to new situations. Researchers tested it not only on footage from the original facility but also on videos from a different research center.
MacqD continued to perform well, proving that it could generalize its learning to new environments and animals it had never seen before. This capability is crucial because it suggests that MacqD could be used in a variety of settings, making it a valuable tool for researchers.
Conclusion
In summary, MacqD is a novel and effective solution for monitoring macaque behavior in lab settings. By using advanced machine learning techniques, it can accurately detect and track macaques under challenging conditions.
While some challenges remain, particularly regarding occlusions or when multiple macaques are in close proximity, MacqD shows great promise as a tool for researchers interested in studying animal behavior. The combination of high accuracy, adaptability, and ease of use makes it an exciting development in animal behavior research.
With MacqD, scientists can spend less time watching videos and more time ensuring the well-being of their furry research subjects. Now, if only they could teach the macaques to watch the videos themselves!
Title: MacqD - A Deep Learning-based Model for Automatic Detection of Socially-housed Laboratory Macaques
Abstract: Despite advancements in video-based behaviour analysis and detection models for various species, existing methods are suboptimal to detect macaques in complex laboratory environments. To address this gap, we present MacqD, a modified Mask R-CNN model incorporating a SWIN transformer backbone for enhanced attention-based feature extraction. MacqD robustly detects macaques in their home-cage under challenging scenarios, including occlusions, glass reflections, and overexposure to light. To evaluate MacqD and compare its performance against pre-existing macaque detection models, we collected and analysed video frames from 20 caged rhesus macaques at Newcastle University, UK. Our results demonstrate MacqDs superiority, achieving a median F1-score of 99% for frames with a single macaque in the focal cage (surpassing the next-best model by 21%) and 90% for frames with two macaques. Generalisation tests on frames from a different set of macaques from the same animal facility yielded median F1-scores of 95% for frames with a single macaque (surpassing the next-best model by 15%) and 81% for frames with two macaques (surpassing the alternative approach by 39%). Finally, MacqD was applied to videos of paired macaques from another facility and resulted in F1-score of 90%, reflecting its strong generalisation capacity. This study highlights MacqDs effectiveness in accurately detecting macaques across diverse settings.
Authors: Genevieve Moat, Maxime Gaudet-Trafit, Julian Paul, Jaume Bacardit, Suliann Ben Hamed, Colline Poirier
Last Update: 2024-12-23 00:00:00
Language: English
Source URL: https://www.biorxiv.org/content/10.1101/2024.12.23.629644
Source PDF: https://www.biorxiv.org/content/10.1101/2024.12.23.629644.full.pdf
Licence: https://creativecommons.org/licenses/by-nc/4.0/
Changes: This summary was created with assistance from AI and may have inaccuracies. For accurate information, please refer to the original source documents linked here.
Thank you to biorxiv for use of its open access interoperability.