ABSTRACT
Animal-borne cameras are increasingly used to study animal behavior. Here, we assessed the utility of three machine-learning models – Resnet-50 (3 epochs), Resnet-50 (10 epochs) and Vision Transformer (ViT) (3 epochs) – for identifying breathing behavior from animal-borne camera footage from green turtles (Chelonia mydas). The ViT model had mean Accuracy (97.2%), Precision (63.3%) and F1 (72.7%) scores that outperformed the Resnet-50 models, while all models had a Recall of >99.9%. Thus, the ViT model correctly identified almost all breathing frames although false positives (apnea frames labeled as breathing) were relatively common and led to an over-estimation of breathing rates. We conclude that ViT models are a promising solution for behavioral classification of animal-borne camera footage and even if not yet capable of the fully automated calculation of breathing events in sea turtles, they can still massively reduce the quantity of footage that needs to be manually checked and labeled.
Keywords: Artificial intelligence, Diving, Behavioral classification, Image processing, Machine learning, Chelonia mydas
Summary: Demonstration that the Vision Transformer (ViT) tool is suitable for annotating breathing behavior from animal-borne cameras deployed on sea turtles.
INTRODUCTION
Incorporating cameras into animal-borne devices facilitated a major leap forward in the study of marine megafauna such as sea turtles, marine mammals and sharks (Hays, 2015; Wilmers et al., 2015). With the capacity to gain insights into an animal's visual surroundings (Umwelt), these devices can reveal how animals both perceive and interact with their environment (e.g. Ryan et al., 2022). However, as the use of animal-borne cameras is rapidly increasing (e.g. Thomson et al., 2011; Handley et al., 2018; Agabiti et al., 2026) and innovation in technology allows for longer recording durations, ecologists are faced with the issue of how to efficiently analyze growing quantities of footage (Hampton et al., 2013; Farley et al., 2018). One solution to this problem is to use machine-learning tools, where pre-annotated datasets are used to train pattern-identifying algorithms to annotate other datasets without the requirement for human input (Valletta et al., 2017; Tuia et al., 2022).
Animal-borne camera footage is primarily used to study the behavior of the tagged individuals (Moll et al., 2007). In the context of developing machine-learning tools for behavioral classification, a practical starting point would therefore be to identify an ecologically relevant behavior that is repeatedly and reliably observed across several different taxa. One such example from air-breathing marine megafauna, such as sea turtles, could be breathing behavior. Indeed, information on sea turtle breathing patterns can provide insights into their diving physiology (Robinson et al., 2021), foraging strategies (Okuyama et al., 2012), habitat use (Shillinger et al., 2011) and stress levels (Robinson et al., 2024). Breathing patterns for sea turtles, however, are typically inferred via time–depth recorders (TDRs) by assuming that turtles are breathing whenever they ascend above a specified depth (typically 2 m; e.g. Shillinger et al., 2011, Robinson et al., 2021). Yet, turtles at the surface may not always be breathing (Hochscheid et al., 2010; Agabiti et al., 2026) and this technique is of little use in habitats that are shallower that typically utilized depth limits (e.g. Doñate-Ordóñez et al., 2025). Similarly, efforts to estimate breathing events from accelerometers have had only limited success because of the high signal to noise ratio in the data alongside issues associated with the influence of both waves and the turtles' variable posture when breathing (Jeantet et al., 2024; Agabiti et al., 2026).
The most common machine-learning tools used for image processing and feature extraction are currently convolutional neural networks (CNN) (e.g. Alexnet, Resnet) (Krizhevsky et al., 2017). While powerful, CNNs assume that images have local spatial correlation. In other words, this means that pixels closer to each should be more closely related than pixels farther away (O'Shea and Nash, 2015 preprint). As a result, CNNs are suited to identifying localized objects (e.g. features) within an image, but they are less suited to ‘comprehend’ entire images holistically or the interactions between various subsections of a single image. Indeed, these tools were recently applied to identify breathing behavior in leatherback turtles Dermochelys coriacea in the North Atlantic (Rogers et al., 2024) and while these models successfully identified almost most breathing frames in many deployments, in others, the accuracy dropped to almost 50%. The authors also did not report on how many non-breathing frames were incorrectly labeled as breathing by the model or how effectively the labeled frames could be converted into a biologically relevant metric, such as breathing rate.
To address the short-comings of CNN for image analysis, a tool called Vision Transformer (ViT) was developed with the capacity for global image comprehension (e.g. it does not assume that pixels closer to each other are more closely related than pixels father away) but at the cost of higher computational and data requirements (Dosovitskiy et al., 2020 preprint; Vaswani et al., 2017). In brief, ViT divides each image into smaller sub-sections before assessing how each subsection is related to the others. In the case of identifying sea turtle breathing behavior from animal-borne camera footage, this tool could theoretically identify multiple key features that could help indicate whether a turtle is breathing from both the turtle itself (e.g. the tilt of a turtle's head) and the background (e.g. whether the camera itself is inside or outside the water). ViT also has another benefit over CNNs in that it can create ‘attention maps’ that help establish long-distance connections across the image and illustrate what location on each image the model is using to make predictions, removing some of the ‘black box’ dynamics of many machine-learning tools.
Another potential issue in the use of machine-learning tools for analyzing data from animal-borne cameras is that image processing and feature extraction algorithms often require annotated datasets exceeding millions of images. If the time spent labeling such datasets exceeds the potential time savings from the use of the machine-learning tool, this mitigates the benefits of these tools. Nevertheless, this issue could be potentially alleviated through the use of transfer learning, where a model is trained on an ancillary task where typically a lot of data are available before being fine-tuned to tackle the primary task. This works because the first dataset allows the model to learn how to extract general features, such as edges and contours, whereas the second dataset allows the model to focus on more specific features that are of key interest for addressing the primary task. At present, the most commonly used training dataset for transfer learning is ImageNet, which contains over 14 million images that are categorized into 21,000 unique classes (Deng et al., 2009).
Here, we assessed the accuracy of typical image-processing, feature-extraction and transfer-learning algorithms to identify breaths from animal-borne camera footage on green sea turtles Chelonia mydas in The Bahamas. Green turtles, while listed as ‘least concern’ under the International Union for Conservation of Nature (IUCN), are still threated in many areas worldwide (Wallace et al., 2025) and protected via the Convention on International Trade in Endangered Species of Wild Fauna and Flora (CITES). Thus, new knowledge gained from automation of image processing may contribute positively to conservation priorities. Our specific objectives were to (i) compare the efficacy of using Resnet-50 and ViT models, supported by transfer-learning tools, to identify breathing behavior from video footage and then (ii) compare how breathing events (continual series of breathing frames) identified via these models compare with those identified manually.
MATERIALS AND METHODS
Study sites and camera deployment
Juvenile green sea turtles, Chelonia mydas (Linnaeus 1758) are common residents of mangrove creeks throughout the island of Eleuthera in The Bahamas (Fig. 1; Robinson et al., 2020; Mills et al., 2023), which is where this study was conducted. Specifically, we sampled turtles found in three mangrove creeks: Rollins Creek, Deep Creek and Starved Creek. The creeks were generally shallow (<5 m depth), with a mix of sandy, muddy and rocky substrates. Beds of turtle grass, Thalassia testudinum, and various algal species were present at each location.
Fig. 1.
Map showing the study sites. The dotted red square illustrates the location of the map on the right.
Between September 2018 and February 2020, we captured juvenile green turtles via ‘rodeo’. In short, turtles were followed via boat until we were close enough to deploy a snorkeler to capture the animal by hand. Once brought back to the boat, turtles with a straight carapace length >30 cm and without external injuries were selected for the deployment of an animal-borne camera (hereafter referred to as a TurtleCam), with both the methodology and details of the TurtleCam setup described in Robinson et al. (2024). The TurtleCams were programmed to record at 30 frames s−1 and resolution of 1920×1080 pixels, and typically recorded 3–4 h of footage based on battery life before the camera released from the carapace and was recovered. Research was conducted under permits provided by The Bahamian Department of Marine Resources (#MA&MR/FIS/9).
Video annotation and dataset preparation
From a total of 67 successful TurtleCam deployments (for full details, see Robinson et al., 2024), we randomly selected 10 min sections from 18 different deployments on unique green turtles. This resulted in a total of 324,000 frames for this analysis. Each frame was labeled manually by the authors (N.J.R. and L.M.) using VGG Image Annotator (VIA) to identify when turtles were breathing or in apnea (i.e. not breathing). We defined breathing as any moment when the turtle's mouth and nostrils were above the surface of the water (Fig. 2). Furthermore, as the number of breathing frames was only 7460 (2% of the entire dataset) whereas the number of apnea frames was 316,540 (98% of the entire dataset), we dealt with this large class imbalance by using all 7460 breathing frames and then randomly selected 7460 frames from all the apnea frames to use as a training dataset. Finally, we hereafter refer to any continual series of frames identified as breathing as a ‘breathing event’. While each manually labeled breathing event was typically short (less than 60 frames per 2 s), we made the assumption that a single breathing event was synonymous with a single breath.
Fig. 2.
Example frames of apnea and breathing as used in the training dataset. We defined breathing as any frame when the turtle's head was above the surface of the water and apnea as any frame when the turtle's head was below the surface of the water. The designations remained accurate regardless of whether the camera was also above or below the water. On the right, we provide attention maps provided by the Vision Transformer (ViT) that visualize the subsections of each image that the model was using to generate predictions.
Baseline model architecture and training details
We separately used and assessed both a Convolutional Resnet-50 (He et al., 2015 preprint) and a base ViT with patch sizes of 16 (Vaswani et al., 2017) that were already pre-trained on the ImageNet classification task (Deng et al., 2009). The ResNet50 is a deep CNN with 50 layers, designed using residual blocks to mitigate vanishing gradients. Each residual block contains convolutional layers along with normalization and the ReLU activation, and skip connections that enable gradients to flow directly through the network during training. The ViT applies the transformer architecture, originally developed for Natural Language Processing, to images. It splits an image into fixed size patches, which are then processed by the Transformer encoder layer. These encoder layers consist of the Attention mechanism, which learns the pairwise relationships between patches, followed by feedforward projections to process per-patch information.
We took these pre-trained models and used Cross-Entropy Loss to train them on the apnea/breathing TurtleCam frames. The original TurtleCam footage was recorded at 1920×1080 pixel resolution, while the ViT/Resnet-50 required images of 224×224 pixels. As such, images were downsized via interpolation to the necessary resolution before model processing. To promote model generalization and robustness, 50% of images went through image transformations (e.g. flipping the image on the horizontal axis). All models were also trained with a batch size of 128, a learning rate of 0.0002 and the AdamW optimizer with a linear learning rate schedule. The Resnet-50 was trained first for 3 epochs but due to initially poor results and lack of convergence, the model was run a second time until convergence was achieved after 10 epochs (Fig. S1). The ViT was only trained once for 3 epochs as convergence was reached by the first epoch (Fig. S1). We define an epoch as a full pass through of the dataset. Once the training loss begins to reach convergence (e.g. it plateaus), it is likely to start overfitting to the training dataset and so the ViT model was not also run with 10 epochs. The hardware utilized for training was 2×A6000 GPUs, and we leveraged the Huggingface Platform for model and training implementations. The ResNet50 model has approximately 25 million parameters where ViT has 86 million. Each model took less than an hour to process on the aforementioned hardware. Full models are available at https://huggingface.co/priyammaz/TurtleCamClassifier and the data are available at https://huggingface.co/datasets/priyammaz/TurtleCamFrames.
Model prediction post-processing
As we defined a dive as any period between breathing events, either a single or a series of incorrectly labeled frames could lead to us counting one more dive per section of video and this problem will continue to increase with each mislabeled frame. To mitigate this issue, we assigned each apnea frame a value of 0 and each breathing frame a value of 1. Next, we calculated the running mean per six sequential frames (equivalent to 0.2 s of footage) and then labeled all those frames as either apnea or breathing if the running mean was ≤0.5 or >0.5, respectively. Next, we deleted three frames from the beginning and end of each dive to correct mis-labeling due to the use of the weighted averaging method. Finally, we removed any continual series of breathing frames of fewer than 15 frames in total (0.5 s) as we manually determined that the shortest breathing event from the manually labeled data was 17 frames (Fig. S2). An example of the smoothing process is shown in Fig. S3.
Model evaluation
For model evaluation, we used the post-processed output (see previous section) and applied a ‘leave one out’ approach whereby the model was trained on 17 of the 18 videos and then assessed via its capacity to label the remaining video. This method was repeated to assess the capacity of the model to label each of the 18 labeled videos. We assessed the capacity of the model after post-processing to distinguish between apnea and breathing frame using the following metrics. (1) Accuracy: proportion of all correctly identified frames (true-positive or true-negative), whether apnea or breathing. (2) Precision: the proportion of all the true-positive breathing frames divided by the number of both true-positive and false-positive frames. (3) Recall: the ratio of correctly labeled breathing frames to the sum of correctly labeled breathing and apnea frames. (4) F1 score: the harmonic mean of precision and recall. F1 Score was useful when seeking a balance between high precision and high recall, as it penalizes extreme negative values of either component. Finally, the ViT model was also used to create Attention Maps, which are essentially ‘heat maps’ that visualize which sections of each image the model considers most relevant to the current task (Dosovitskiy et al., 2020 preprint).
To assess the suitability of the model output for estimating a biologically relevant metric, we calculated the total number of breathing events (defined as any continual series of breathing frames) identified manually to those identified by each model. We also calculated the mean difference (after converting all differences to positive numbers) in the manually identified number of dives (defined as the period between breathing events) compared with the predicted dives. Finally, we divided this number by the number of manually identified breaths to indicate how many breaths were incorrectly identified relative to each manually identified breath. Hereafter, we refer to this as the ratio of correctly to incorrectly identified breaths. Finally, we also used the capacity of the ViT model to create Attention Maps that visualize the subsections of each image that it is using to generate predictions (Fig. 2), to assess where the focus of the model was directed during both correct and incorrect labels.
RESULTS AND DISCUSSION
Model performance
Accuracy is the proportion of breathing frames that were correctly labeled by the model. The mean accuracy increased from 86.6% for Resnet50 (3 epochs) to 95.2% for Resnet50 (10 epochs) to 97.2% for ViT (3 epochs) models alongside a decrease in the range in accuracies of individual models from 49.2–98.2% to 84.0–99.8% to 89.3–99.1%, respectively (Table 1; Tables S1, S2 and S3). While appearing promising, because of the class imbalance in the videos (i.e. 98% of frames were of apnea), a model that exclusively predicted apnea frames would still have an accuracy of 98%. Nevertheless, the accuracy of the ResNet50 (3 epochs) model, which ranged from 49.2% to 98.2%, was similar to that reported from the use of other CNN models to assess breathing rates of leatherback turtles from animal-borne camera footage (Rogers et al., 2024) or in green turtles using TDRs (Francke et al., 2013). These values were, however, far exceeded by the ResNet50 (10 epochs) and the ViT model, for which the lowest accuracy per deployment was 84.0% and 89.3% respectively.
Table 1.
Aggregate Measures of Accuracy, Precision, Recall, F1 score and the ratio of correctly to incorrectly identified breaths across all videos with leave-one-out prediction results
| Model architecture | Accuracy (%) | Precision (%) | Recall (%) | F1 (%) | Ratio of correctly to incorrectly identified breaths |
|---|---|---|---|---|---|
| Resnet50–3 epochs | 86.6 [49.2, 98.2] |
19.6 [3.5, 46.3] |
100 [99.7, 100] |
55.0 [6.9, 63.3] |
2.48 |
| Resnet50–10 epochs | 95.2 [84.0, 99.8] |
47.6 [14.7, 82.3] |
99.9 [99.4, 100] |
60.3 [25.6, 90.3] |
0.17 |
| ViT – 3 epochs | 97.2 [89.3, 99.1] |
63.3 [17.9, 98.1] |
99.1 [92.8, 100] |
72.7 [30.4, 95.4] |
0.10 |
Data presented are means with range in brackets.
Precision compares the number of frames correctly labeled as breathing with all frames labeled as breathing, both correct or incorrect. As such, precision can be a flawed metric for evaluating a dataset like ours with distinct class imbalances, as a small percentage of incorrectly labeled apnea frames could significantly reduce the model's precision. It was therefore somewhat predictable that precision was low in all models. Nevertheless, the mean precision increased from 19.6% in Resnet50 (3 epochs) to 47.6% in Resnet50 (10 epochs), and then to 63.4% in ViT (3 epochs) models even though the range in precision of individual models remained very high at 3.5–46.3%, 14.7–82.3% and 17.9–98.1%, respectively (Table 1; Tables S1, S2 and S3).
Recall is the proportion of manually identified breathing frames that were classified correctly as breathing frames by the model, and should be robust to the previously mentioned issue of class imbalance. Encouragingly, the mean recall for all models ranged from 99.1% to 100.0% and the recall of any individual model was always above 92.8%. Unlike in the two previous metrics, Resnet50 (3 epochs) was the highest performing model and ViT (3 epochs) model was the lowest (Table 1; Tables S1, S2 and S3). It should be noted that the Recall of all models (mean range: 99.1–100.0%) WAS notably higher than the Recall values of 0.62–0.63 achieved in a similar study but using accelerometry data instead of animal-borne camera footage, when estimating breathing behavior from loggerhead turtles Caretta caretta (Agabiti et al., 2026). In other words, almost all breathing frames were classified correctly in our study and the percentage of apnea frames incorrectly labeled as breathing was also relatively small (3.9%). The current ResNet50 or ViT models may therefore not yet be sufficient to automatically estimate breathing rate, but they represent a notable improvement over the use of previous CNN models (e.g. Rogers et al., 2024) as well as many TDR and accelerometry studies for estimating breathing rates (e.g. Jeantet et al., 2024; Agabiti et al., 2026). Moreover, the almost perfect Recall of the ViT models indicates that these tools can rapidly highlight all potential frames that could then be reviewed manually to confirm whether they show breathing or not. The use of such a tool could still massively reduce the number of frames that need to be reviewed when manually labeling breathing versus apnea frames, in turn saving researchers considerable effort and time.
The F1 score combines both Precision and Recall metrics, and typically F1 scores over 70% are ‘good’ (Naidu et al., 2023). As Recall was almost 100% in all models, the F1 score should be primarily influenced by variation in Precision. Mean F1 scores increased from 55.0% in Resnet50 (3 epochs) to 60.3% in Resnet50 (10 epochs), and then to 72.7% in ViT (3 epochs) (Table 1; Tables S1, S2 and S3). The fact that the ViT model outperformed the Resnet model even when the latter was trained over a higher number of epochs highlights the value of using AI-tools with global image comprehension for identifying behaviors in animal-borne camera footage. These F1 values of the ViT model were also comparable to other machine-learning based models that have been used to identify behaviors, such as feeding and resting (but not breathing), using accelerometry data from both sea turtles (Jeantet et al., 2024) and seabirds (Otsuka et al., 2024). This suggests that ViT models can be just as effective at the automated behavioral identification from video footage as has been previously achieved using arguable less complex data inputs (e.g. numerical dive or accelerometry data).
Identifying individual breathing events
The Resnet50 (3 epochs) never correctly predicted the number of breathing events per video, overestimating in 16 videos and underestimating in the other two. Specifically, for every correctly identified breathing event there were 2.48 incorrectly identified. The Resnet50 (10 epochs) exhibited a marked improvement over the Resnet50 (3 epochs) and correctly predicted the number of breathing events in eight videos while also overestimating in six videos and underestimating in four. Specifically, for every correctly identified breathing event there were 0.17 incorrectly identified. Finally, the ViT (3 epochs) continued to improve upon both previous models and correctly predicted the manually identified number of breathing events in 12 of 18 videos while still overestimating in four videos and underestimating in two. Specifically, for every correctly identified breathing event there were 0.10 incorrectly identified. By comparing the time between breaths for each video (Fig. 3), the majority of errors in the ViT (3 epochs) model were observed when the time between breathing events was <25 s or >125 s.
Fig. 3.
Manually identified time between breaths compared with the ViT (3 epochs) model-predicted time between breaths.
Attention maps
Reviewing the attention maps generated by the ViT model shows that on correctly identified breathing events, the attention was typically focused on the sea turtle's head rising above the surface of the water, which matches how we defined breathing in ‘Video annotation and dataset preparation’, above (Fig. 2). Similarly, in incorrectly identified apnea frames, we observed that the head was the key focal point in the attention maps, whereas in incorrectly predicted breathing frames, the focus was largely distributed across the background of the image. This suggests that the model has ‘learned’ that the key feature to be observed when discriminating between apnea and breathing is the head. Nevertheless, the primary sources of mislabeled breathing frames appear to result from two key events. (1) When the turtle came to the surface and took multiple breaths consecutively without actively swimming/diving away from the surface. In such instances, the camera often remained above the water's surface (Fig. 2) and instead of identifying each breath, the model rapidly switched back and forth between breathing and apnea, vastly over-estimating the number of breathing events while the turtle remained at the surface (Fig. 4). (2) When the turtle surfaced for a breath, but the camera itself did not break the surface of the water (Fig. 2). When this occurred, the model often did not identify a breathing event and thus overestimated the time between breathing events. Both of these issues indicate that the model was imprecise in discriminating between when the turtle was breathing or when the camera itself was above the water's surface but the turtle's head remained below the surface. One potential solution would therefore be to first adjust the model to identify surfacing events (defined as periods of inactivity at the surface that may be punctuated by multiple breathing events) instead of breathing events. However, this may reduce the biological insights gained from the animal-borne cameras when trying to assess breathing and diving patterns, and would not present a significant advance over what is already achievable using depth sensors. Alternatively, we could potentially increase the height of the camera and thus ensure that it broke the water's surface upon every surfacing event. While the first solution would be an interesting angle for further research, we caution against the second option as it would likely increase the hydrodynamic drag associated with the bio-logging device (e.g. Jones et al., 2013) and such a trade-off to improve analysis times would not be justifiable.
Fig. 4.
An example output from the ViT model where the TurtleCam remained above the surface of the water while a turtle was conducting several breathing events. In this instance, the model output (orange line) struggled to correctly identify each breathing event (dashed blue lines).
Future model improvements
While we used a running mean (described in ‘Model prediction post-processing’, above) to address the issues associated with a single mislabeled frame, a more refined solution could be to incorporate a temporal ‘memory’ into the model. The current model produces a prediction for every frame individually, but has no context for preceding and future frames, which is a major limitation as most behaviors we are interested in span multiple sequential frames of video footage. As discussed earlier, the ViT model interprets images via the learned relationships across the different subsections, although these subsections are for a single image. More advanced architectures, such as the VideoMAE (Tong et al., 2022) can learn relationships across the subsections not only of a single image but also between all subsections of an entire sequence of images. By doing this, the model can learn both the spatial and temporal dynamics to produce its predictions.
Another way to potentially improve any machine-learning algorithm is to provide ever larger training datasets. In our model, we used transfer-learning via ImageNet (Deng et al., 2009; Krizhevsky et al., 2017) to provide a source of images to pre-train our models on, and as these models continually grow, their utility for image processing will simultaneously increase. Moreover, as the use of animal-borne cameras on sea turtles continues to increase (e.g. Mullaney et al., 2024; Robinson et al., 2024; Manning et al., 2025), the amount of highly relevant training footage will also increase. As the sea turtle species, camera quality and environmental conditions (e.g. water quality, benthic substrate, etc.) will differ in many of these training datasets, the resulting model will grow increasingly robust until a point where hopefully it can be applied to novel sea turtle species in novel habitats while still retaining a high level of performance.
Conclusion
We illustrated that ViT models can serve as useful tools for identifying breathing behavior from animal-borne camera footage from sea turtles, with improved reliability beyond CNN tools or inferences derived from TDRs and/or accelerometers. While the ViT model still has some limitations when determining biologically relevant metrics, such as breathing rates, its high Recall values show that ViT models can already massively reduce the number of frames that researchers need to annotate. The next steps should therefore focus on how ViT models perform for identifying breathing behavior in other air-breathing marine species and more visually complex behaviors such as foraging and socializing. Moreover, we envisage that the strength of image processing tools will continue to advance in the coming years alongside a mix of technological innovation and, if publicly shared, an ever-increasing abundance of potential training datasets.
Supplementary Material
Acknowledgements
We thank all the researchers, interns and students at the Cape Eleuthera Island School for their essential help with TurtleCam deployments. The Cape Eleuthera Island School also provided boat access during deployments.
Footnotes
Author contributions
Conceptualization: N.J.R., B.F.A., A.S.; Data curation: P.M., L.M.; Investigation: N.J.R.; Methodology: P.M., B.C., B.-Y.H., J. Terstriep; Resources: N.J.R., A.S.; Supervision: B.F.A., J.A., J. Tomás, A.S.; Writing – original draft: N.J.R., P.M.
Funding
The TurtleCam project was funded by the Cape Eleuthera Institute and Western Connecticut State University’s Finding Our Way project. The latter project was, in turn, supported by the National Oceanic and Atmospheric Administration and National Marine Fisheries Service through the New England B-WET Program (NA16NMF0080003). The machine-learning analyses were funded by center directed discretionary research funding from the National Center for Supercomputing Applications and the University of Illinois. N.J.R. was funded by the Spanish government (AEI) through the Ramon y Cajal postdoctoral program (RYC2021-034381-I). J.A. was funded through EU DIGI4ECO (101112883-GAP-101112883). Open Access funding provided by Consejo Superior de Investigaciones Científicas (CSIC). Deposited in PMC for immediate release.
Data and resource availability
Full models are available at https://huggingface.co/priyammaz/TurtleCamClassifier. Data are available at https://huggingface.co/datasets/priyammaz/TurtleCamFrames. All other relevant data and details of resources can be found within the article and its supplementary information.
References
- Agabiti, C., Restelli, F., Freggi, D., Salvemini, P., Luschi, P. and Casale, P. (2026). Sea turtle breathing patterns and involved factors investigated through animal-borne camera and sensors. Mar. Biol. 173, 24. 10.1007/s00227-025-04783-5 [DOI] [Google Scholar]
- Deng, J., Dong, W., Socher, R., Li, L.-J., Li, K. and Fei-Fei, L. (2009). Imagenet: A large-scale hierarchical image database. IEEE conference on computer vision and pattern recognition, 248-255. 10.1109/CVPR.2009.5206848 [DOI] [Google Scholar]
- Doñate-Ordóñez, R., Chatzievangelou, D., Mills, S., Reyes-González, J. M. and Robinson, N. J. (2025). Diving behavior of juvenile green turtles in shallow habitats in the Bahamas. Mar. Ecol. Prog. Ser. 780, meps15080. 10.3354/meps15080 [DOI] [Google Scholar]
- Dosovitskiy, A., Beyer, L., Kolesnikov, A., Weissenborn, D., Zhai, X., Unterthiner, T., Dehghani, M., Minderer, M., Heigold, G., Gelly, S.et al. (2020). An image is worth 16×16 words: transformers for image recognition at scale. arXiv, 2010.11929. 10.48550/arXiv.2406.09415 [DOI] [Google Scholar]
- Farley, S. S., Dawson, A., Goring, S. J. and Williams, J. W. (2018). Situating ecology as a big-data science: Current advances, challenges, and solutions. Bioscience 68, 563-576. 10.1093/biosci/biy068 [DOI] [Google Scholar]
- Francke, D. L., Hargrove, S. A., Vetter, E. W., Winn, C. D., Balazs, G. H. and Hyrenbach, K. D. (2013). Behavior of juvenile green turtles in a coastal neritic habitat: Validating time–depth–temperature records using visual observations. J. Exp. Mar. Biol. Ecol. 444, 55-65. 10.1016/j.jembe.2013.03.011 [DOI] [Google Scholar]
- Hampton, S. E., Strasser, C. A., Tewksbury, J. J., Gram, W. K., Budden, A. E., Batcheller, A. L., Duke, C. S. and Porter, J. H. (2013). Big data and the future of ecology. Front. Ecol. Envir. 11, 156-162. 10.1890/120103 [DOI] [Google Scholar]
- Handley, J. M., Thiebault, A., Stanworth, A., Schutt, D. and Pistorius, P. (2018). Behaviourally mediated predation avoidance in penguin prey: in situ evidence from animal-borne camera loggers. R. Soc. Open Sci. 5, 171449. 10.1098/rsos.171449 [DOI] [PMC free article] [PubMed] [Google Scholar]
- Hays, G. C. (2015). New insights: animal-borne cameras and accelerometers reveal the secret lives of cryptic species. J. Anim. Ecol. 84, 587-589. 10.1111/1365-2656.12355 [DOI] [PubMed] [Google Scholar]
- He, K., Zhang, X., Ren, S. and Sun, J. (2015). Deep residual learning for image recognition. arXiv, 1512.03385. 10.48550/arXiv.1512.03385 [DOI] [Google Scholar]
- Hochscheid, S., Bentivegna, F., Hamza, A. and Hays, G. C. (2010). When surfacers do not dive: multiple significance of extended surface times in marine turtles. J. Exp. Biol. 213, 1328-1337. 10.1242/jeb.037184 [DOI] [PubMed] [Google Scholar]
- Jeantet, L., Zondo, K., Delvenne, C., Martin, J., Chevallier, D. and Dufourq, E. (2024). Automatic identification of the endangered hawksbill sea turtle behavior using deep learning and cross-species transfer learning. J. Exp. Biol. 227, jeb249232. 10.1242/jeb.249232 [DOI] [PMC free article] [PubMed] [Google Scholar]
- Jones, T. T., Van Houtan, K. S., Bostrom, B. L., Ostafichuk, P., Mikkelsen, J., Tezcan, E., Carey, M., Imlach, B. and Seminoff, J. A. (2013). Calculating the ecological impacts of animal-borne instruments on aquatic organisms. Method. Ecol. Evol. 4, 1178-1186. 10.1111/2041-210X.12109 [DOI] [Google Scholar]
- Krizhevsky, A., Sutskever, I. and Hinton, G. E. (2017). ImageNet classification with deep convolutional neural networks. Commun. ACM 60, 84-90. 10.1145/3065386 [DOI] [Google Scholar]
- Manning, J. C., Rosengarten, S., Hooper, C. and Fuentes, M. M. P. B. (2025). Post-release changes in the fine-scale diving behavior and activity of loggerhead sea turtles (Caretta caretta) from the Northeastern Gulf of Mexico. Anim. Biotelemetry 13, 13. 10.1186/s40317-025-00406-4 [DOI] [Google Scholar]
- Mills, S. K., Rotger, A., Brooks, A. M., Paladino, F. V. and Robinson, N. J. (2023). Photo identification for sea turtles: Flipper scales more accurate than head scales using APHIS. J. Exp. Mar. Biol. Ecol. 566, 151923. 10.1016/j.jembe.2023.151923 [DOI] [Google Scholar]
- Moll, R. J., Millspaugh, J. J., Beringer, J., Sartwell, J. and He, Z. (2007). A new ‘view’ of ecology and conservation through animal-borne video systems. Trends Ecol. Evol. 22, 660-668. 10.1016/j.tree.2007.09.007 [DOI] [PubMed] [Google Scholar]
- Mullaney, C. M., Seminoff, J. A., Lemons, G. E., Chesney, B. and Maurer, A. S. (2024). The urban lives of green sea turtles: Insights into behavior in an industrialized habitat using an animal-borne camera. Ecol. Evol. 14, e11282. 10.1002/ece3.11282 [DOI] [PMC free article] [PubMed] [Google Scholar]
- Naidu, G., Zuva, T. and Sibanda, E. M. (2023). A review of evaluation metrics in machine learning algorithms. In Artificial Intelligence Application in Networks and Systems. CSOC 2023. Lecture Notes in Networks and Systems, Vol. 724 (ed. Silhavy R. and Silhavy P.). Cham: Springer. 10.1007/978-3-031-35314-7_2 [DOI] [Google Scholar]
- Okuyama, J., Kataoka, K., Kobayashi, M., Abe, O., Yoseda, K. and Arai, N. (2012). The regularity of dive performance in sea turtles: a new perspective from precise activity data. Anim. Behav. 84, 349-359. 10.1016/j.anbehav.2012.04.033 [DOI] [Google Scholar]
- O'Shea, K. and Nash, R. (2015). An introduction to convolutional neural networks. arXiv 1511, 08458. 10.48550/arXiv.1511.08458 [DOI] [Google Scholar]
- Otsuka, R., Yoshimura, N., Tanigaki, K., Koyama, S., Mizutani, Y., Yoda, K. and Maekawa, T. (2024). Exploring deep learning techniques for wild animal behaviour classification using animal-borne accelerometers. Method. Ecol. Evol. 15, 716-731. 10.1111/2041-210X.14294 [DOI] [Google Scholar]
- Robinson, N. J., Bigelow, W. F., Cuffley, J., Gary, M., Hoefer, S., Mills, S., Smith, A. and Miguel Blanco, A. (2020). Validating the use of drones for monitoring the abundance and behaviour of juvenile green sea turtles in mangrove creeks in The Bahamas. Testudo 9, 24-35. [Google Scholar]
- Robinson, N. J., García-Párraga, D., Stacy, B. A., Costidis, A. M., Blanco, G. S., Clyde-Brockway, C. E., Haas, H. L., Harms, C. A., Patel, S. H., Stacy, N. I.et al. (2021). A baseline model for estimating the risk of gas embolism in sea turtles during routine dives. Front. Physiol. 12, 678555. 10.3389/fphys.2021.678555 [DOI] [PMC free article] [PubMed] [Google Scholar]
- Robinson, N. J., Doñate-Ordóñez, R., Chatzievangelou, D., Brooks, A. M., Cuffley, J., Fields, C. Y., Hoefer, S., Pinou, T., Smith, A. and Mills, S. (2024). Short-term effects of attaching animal-borne devices on the behavior of juvenile green turtles. Ecol. Evol. 14, e70707. 10.1002/ece3.70707 [DOI] [PMC free article] [PubMed] [Google Scholar]
- Rogers, R., Choate, K. H., Crowe, L. M., Hatch, J. M., James, M. C., Matzen, E., Patel, S. H., Sasso, C. R., Siemann, L. A. and Haas, H. L. (2024). Investigating leatherback surface behavior using a novel tag design and machine learning. J. Exp. Mar. Biol. Ecol. 576, 152012. 10.1016/j.jembe.2024.152012 [DOI] [Google Scholar]
- Ryan, L. A., Andrzejaczek, S., Gleiss, A. C., Meekan, M. G., Chapple, T. K. and Hart, N. S. (2022). Prey interactions in tiger sharks: Accounting for visual perception in animal-borne cameras. J. Exp. Mar. Biol. Ecol. 553, 151764. 10.1016/j.jembe.2022.151764 [DOI] [Google Scholar]
- Shillinger, G. L., Swithenbank, A. M., Bailey, H., Bograd, S. J., Castelton, M. R., Wallace, B. P., Spotila, J. R., Paladino, F. V., Piedra, R. and Block, B. A. (2011). Vertical and horizontal habitat preferences of post-nesting leatherback turtles in the South Pacific Ocean. Mar. Ecol. Prog. Ser. 422, 275-289. 10.3354/meps08884 [DOI] [Google Scholar]
- Thomson, J. A., Heithaus, M. R. and Dill, L. M. (2011). Informing the interpretation of dive profiles using animal-borne video: a marine turtle case study. J. Exp. Mar. Biol. Ecol. 410, 12-20. 10.1016/j.jembe.2011.10.002 [DOI] [Google Scholar]
- Tong, Z., Song, Y., Wang, J. and Wang, L. (2022). VideoMAE: Masked autoencoders are data-efficient learners for self-supervised video pre-training. Adv. Neural Inf. Process. Syst. 35, 10078-10093. [Google Scholar]
- Tuia, D., Kellenberger, B., Beery, S., Costelloe, B. R., Zuffi, S., Risse, B., Mathis, A., Mathis, M. W., Van Langevelde, F., Burghardt, T.et al. (2022). Perspectives in machine learning for wildlife conservation. Nat. Commun. 13, 1-15. 10.1038/s41467-022-27980-y [DOI] [PMC free article] [PubMed] [Google Scholar]
- Valletta, J. J., Torney, C., Kings, M., Thornton, A. and Madden, J. (2017). Applications of machine learning in animal behaviour studies. Anim. Behav. 124, 203-222. 10.1016/j.anbehav.2016.12.005 [DOI] [Google Scholar]
- Vaswani, A., Shazeer, N., Parmar, N., Uszkoreit, J., Jones, L., Gomez, A. N., Kaiser, Ł. and Polosukhin, I. (2017). Attention is all you need. Advances in neural information processing systems. Adv. Neural Inf. Proc. Syst. 30. 10.48550/arXiv.1706.03762 [DOI] [Google Scholar]
- Wallace, B. P., Bandimere, A. N., Abreu-Grobois, A., Acosta, H., Akiti, J., Akomedi, M., Alfaro-Shigueto, J., Allen, C. D., Angenda, D., Ayissi, I., et al. (2025). Updated global conservation status and priorities for marine turtles. Endanger. Species Res. 56, 247-276. 10.3354/esr01385 [DOI] [Google Scholar]
- Wilmers, C. C., Nickel, B., Bryce, C. M., Smith, J. A., Wheat, R. E. and Yovovich, V. (2015). The golden age of bio-logging: How animal-borne sensors are advancing the frontiers of ecology. Ecology 96, 1741-1753. 10.1890/14-1401.1 [DOI] [PubMed] [Google Scholar]
Associated Data
This section collects any data citations, data availability statements, or supplementary materials included in this article.




