An open reproducible framework for CNN-based cetacean vocalization detection in passive acoustic monitoring

List of Authors

  1. Rocco De Marco
Article Authors & roles Authors Peer review record Peer review Metrics
Cite

Abstract

Background

Passive acoustic monitoring (PAM) combined with deep learning is increasingly used to detect cetacean vocalizations. The workflow from raw audio to a trained detector — annotation, segmentation, spectrogram parameterization, image processing, and model evaluation — is seldom accompanied by the complete set of configuration parameters, code, and data needed for independent reproduction, limiting methodological comparability and systematic benchmarking.

Methods

This article presents ai-pam-pipeline, an open-source six-stage framework that formalizes the complete CNN-based detection workflow, with every parameter defined in a single YAML configuration file ensuring exact experimental reproducibility. The framework separates methodological structure from computational implementation, allowing single-channel, spectrogram-based classification workflows to be adapted to other species and vocalization types through configuration alone, without code modification. Validation was conducted on bottlenose dolphin ( Tursiops truncatus) recordings through two complementary experiments: (A) a binary whistle detector trained on controlled-environment data and evaluated on an independent open-ocean dataset, and (B) a five-class vocalization classifier demonstrating framework scalability.

Results

The binary detector achieved macro F1 = 0.960 under ten-fold cross-validation with file-level grouped splitting. Cross-domain evaluation yielded a precision of 0.999 and a false discovery rate of 0.001 (macro F1 = 0.744); precision-recall analysis shows that recall rises to 0.76 at a lower decision threshold while precision remains above 0.95, indicating partial but operationally useful generalization. The multiclass extension achieved macro F1 = 0.835 across five vocalization categories; inter-class confusion between echolocation click trains and burst-pulse sounds reflects biological signal overlap rather than classifier failure.

Conclusions

The framework provides a reproducible and documented baseline for CNN-based cetacean detection in PAM. The complete toolkit is released under the Apache 2.0 license, with training and evaluation datasets made openly available through separate public repositories. Together, these resources enable exact replication of the reported analyses and support adaptation to new monitoring contexts.

Plain Language Summary

Dolphins and other cetaceans are increasingly monitored by recording the sounds they make underwater, a technique called passive acoustic monitoring. Modern systems use artificial intelligence to automatically detect dolphin whistles in these recordings, but the way each research group prepares its data and trains its models is rarely described in full, which makes results hard to reproduce or compare. This paper introduces ai-pam-pipeline, a freely available software framework that organizes the whole process — from labeling recordings to training and testing a detector — into six clearly defined steps, all controlled by a single settings file. Because every choice is written down in that file, anyone can reproduce the exact same results or adapt the workflow to a different species. We tested the framework on bottlenose dolphin recordings: it detected whistles accurately, and when applied to a completely separate recording made in another ocean, it never produced a false alarm. The framework is openly released so other researchers can build on it.

Corresponding author
Rocco De Marco
Grant information

This project has received funding from the European Commission LIFE Programme under grant agreement No [LIFE19 NAT/IT/000942](project name LIFE DELFI).

The funders had no role in study design, data collection and analysis, decision to publish, or preparation of the manuscript.

Copyright
© 2026 Rocco De Marco (Corresponding Author) Creative Commons License

This work is licensed under a Creative Commons Attribution 4.0 International License.

First version published
Latest version published
Revised

Amendment

The current revision addresses every point raised by both reviewers. The principal changes are:
1) Data leakage corrected (Reviewer 2, Major 1): cross-validation redesigned with StratifiedGroupKFold grouping by source audio file; all experiments re-run; all numbers updated throughout.

2) Precision-recall curves added (Reviewer 2, Major 2): new §3.3.3 with threshold sweep analysis and Figure 3.

3) Claims moderated throughout (both reviewers): "never," "confirming generalization," and the recall/FDR priority contradiction resolved.

4) Literature substantially expanded (Reviewer 2, Major 4 and Minor 8–10): ten new references added, including metadata standards (Tethys, ANSI/ASA S3/SC1.7), training frameworks (Koogu, Ketos, ANIMAL-SPOT, PAMGuard, DeepAcoustics), and missing whistle detection studies (Li et al. 2020, Li et al. 2023, White et al. 2022).

5) Figure 3 replaced (both reviewers): the erroneously retained N_fft boxplot has been replaced with the correct precision-recall analysis; Figure 4 now shows the updated confusion matrix for Experiment B.

6) Repository updated to v1.1.0: includes the grouped cross-validation fix (group_by: "stem" as default), C-spectrogram engine, and updated documentation.

Comments

Authors & roles

Rocco De Marco

1. Institute of Biological Resources and Marine Biotechnology (IRBIM), National Research Council (CNR), Ancona, Largo Fiera della Pesca, 2, 60126, Italy

Roles
Corresponding Author, Conceptualization, Data Curation, Formal Analysis, Investigation, Methodology, Software, Validation, Visualization, Writing – Original Draft Preparation, Writing – Review & Editing

Downloads over the last 12 months:

Cited by

via Crossref

View citing articles