OSCR

A real-time, multi-animal model for automatic face detection and identification of freely moving common marmosets based on YOLOv8 algorithms.

Code ↔ Paper

3 matches between paragraphs of the paper and lines of its authors' code, computed by the harvester (lexical-v1). Click a colored paragraph or line to see its counterpart.

The 3 matches
  1. [1] § Results › Automatic facial and identity extraction accurately localizes new marmoset faces and their collar beads ↔ pre-processing/postAutoExtract_label_modification.py, lines 1 to 20 · score 0.60 · automatic facial, identity extraction, collected video, confusion, marmoset face, pre · Report a mismatch
  2. [2] § Materials and methods › Real-time face recognition program ↔ pre-processing/postAutoExtract_label_modification.py, lines 25 to 60 · score 0.54 · detected bounding box, marmoset identities, frame, collar, videos, model · Report a mismatch
  3. [3] § Materials and methods › Marmoset face recognition pipeline ↔ pre-processing/postAutoExtract_label_modification.py, lines 25 to 60 · score 0.52 · bounding box, identity extraction, location, collar, videos, model · Report a mismatch

Paper

Loaded from Europe PMC by your browser; OSCR does not store it: doi.org · Europe PMC

The paper is loaded when this pane is shown.

The authors' code

Python · 64 lines · 3.4 KB · MIT · 3 matches

  1. """
  2. Label modification of specific marmoset identities, converting from the automatically detected face and collar.
  3. - Input: automatic extracted labels of marmoset faces and collars (from single marmoset, automatic identity extration model).
  4. - Output: modified names for the label classes of marmoset.
  5. - Each input folder contains 2 label classes (face, collar) with indices (0, 1).
  6. - As only 1 marmoset with known identity is included in the video of automatic identity extraction.
  7. - The videos were named with marmoset identity at the beginning, thus the labeling files of the input folder start with specific marmoset name.
  8. - This is recommended to avoid confusion between collected videos from each marmoset from the same family, but not necessary.
  9. - The face (0) and collar (1) index are converted to corresponding marmoset names --> for facial recognition of their family.
  10. Example:
  11. If the family includes marmoset A, B, C, so in the family face recognition model the labels would be:
  12. - marmoset A (face = 0, collar = 1)
  13. - marmoset B (face = 2, collar = 3)
  14. - marmoset C (face = 4, collar = 5)
  15. So, the results of automatic facial extraction of marmoset B needs to be converted: (face 0 --> 2; collar 1 --> 3)
  16. Contributor: Jiayue Yang, 2025-09-15
  17. """
  18. import os
  19. # directory of the txt file folder of automatic identity extraction results (1 marmoset per video per folder)
  20. txt_folder = "automatic_extract_label" # (to edit) the YOLO output of the automatic extraction model (with marmoset faces and collars detected)
  21. # iterate throughout the folder (i.e. frames of the input video of automatic identity extraction)
  22. for txt_file in os.listdir(txt_folder):
  23. if txt_file.endswith(".txt"):
  24. file_path = os.path.join(txt_folder, txt_file)
  25. # only necessary if experimenter differs videos by marmoset identity
  26. marm_name = "abc" # (to edit) if the frame name starts with a marmoset name
  27. if txt_file.startswith(marm_name):
  28. # create new empty lines for label modification
  29. new_lines = []
  30. # open the file and enable editing
  31. with open(file_path, "r") as f:
  32. for line in f:
  33. # each line = 1 detected bounding box/object
  34. line = line.strip()
  35. if not line:
  36. continue
  37. # separate the label index (first element of the line) from the location of the bounding box/detected object
  38. parts = line.split()
  39. label = parts[0]
  40. # (to edit) change the label index based on the pre-defined family model index
  41. # see examples: if marmoset B, face 0 --> 2, collar 1 --> 3
  42. if label == "0":
  43. parts[0] = "2"
  44. elif label == "1":
  45. parts[0] = "3"
  46. # ensure that the other elements of the line (i.e. location of the bounding box) remain unchanged
  47. # add that to the modified label class index
  48. new_lines.append(" ".join(parts))
  49. # update the file with the modified label index, keep the file name same
  50. with open(file_path, "w") as f:
  51. f.write("\n".join(new_lines) + "\n")
  52. # print an ending statement, for the specific marmoset
  53. print("Finished updating labels for", marm_name, "files.")

postAutoExtract_label_modification.py at commit 465da2c, under MIT · at the source

Overview

Authors: Jiayue Yang1,2, James Wang1,2, Justine Cléry1,3,4
  1. The Neuro, Department of Neurology and Neurosurgery, McGill University Montreal Canada
  2. Integrated Program in Neuroscience, McGill University Montreal Canada
  3. McConnell Brain Imaging Centre, The Neuro, Montreal Neurological Institute and Hospital, McGill University Montreal Canada
  4. Azrieli Centre for Autism Research, The Neuro Montreal Canada
Journal: eLife, volume 15, article RP110932
Dates: published online 29 September 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI 10.7554/elife.110932 · PMID 42808519 · PMCID PMC13623377 · OpenAlex W7147516715
Open access: gold, a free copy (OpenAlex)
Status: code verified (how the code is found and verified)
Categories: human (organism), non-human primate (organism), methods / tools (subfield)
Methods: Spectral & time-frequency, Statistics, Preprocessing, Machine learning
Keywords: Callithrix jacchus, facial recognition, deep learning, automation, YOLOv8, tracking, Other
MeSH: Callithrix*, Face*, Algorithms, Animals, Detection Algorithms, Female (* major topic)
Journal subjects: Computational and Systems Biology
Topic: Face recognition and analysis (Computer Vision and Pattern Recognition, Computer Science), according to OpenAlex
Funding: Government of Canada (NFRFT-2022-00051); Fonds de recherche du Québec (10.69777/347426, 358082, 10.69777/2003934)
Citations: not cited yet (Europe PMC); 65 references in the paper

Abstract

Precise and up-to-date information about animal location and identity allows us to better quantify individual behaviors in studies of neural activity, cognition, and animal health. In socially housed laboratory animals, identification is usually defined by observation or invasive markers, making the data collection time-consuming, variable across experimenters, and disruptive to animals. We established an automatic pipeline for real-time identification of common marmosets in captivity using a close-view camera. It uses the supervised deep-learning YOLOv8 model to localize individuals, detect faces, and classify identities. Moreover, we use recognition of uniquely color-coded collar beads to improve detection accuracy among visually similar individuals. Across adult and juvenile marmosets, our system automatically identifies marmosets with >82.9% precision and >91.5% recall, achieving human-level performance. This pipeline is designed to be easy to use and generalizable across non-human primate species, ages, and recording hardware, providing rapid and automatic identity recognition from real-time video.

Reproduced under the paper's license (CC BY), from the paper cited above.

Repository

Its files are read in the Code ↔ Paper reader above, with 3 matches between paragraphs and lines of code.

Jy-Yang-bot/real-time-marmoset-recognition

License: MIT
State: the link answers, verified on 1 October 2026
Evidence: files inventoried
Commit: 465da2c9066eed5f575f0b5b175dd0e38c71f0d6, 13 July 2026
Languages: Python (6), MATLAB (2)
Size: 12 files, 8 scripts
Software Heritage: not archived
Found in: “Data availability”
Holds: README, license file
Not found: CITATION.cff, environment file, tests, continuous integration, documentation
Tools: Matplotlib (3 files), NumPy (3 files), OpenCV (3 files), pandas (3 files), Pillow (1 file), PyTorch (1 file), scikit-learn (1 file), SciPy (1 file), seaborn (1 file)
Availability: 1 check, the latest on 1 October 2026: the link answers
  • 1 October 2026: the link answers
10 files

The paper's code and data availability statement is in the Data section.

Tracing map

Proposed by the machine: these links were found in the paper and verified at the source, without human review. The map will receive a Zenodo DOI once one of the paper's authors has validated it with their ORCID.

What the map holds:

  • 1 repository of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 8 scripts, each with its path and the digest of its content;
  • 3 matches between paragraphs of the paper and lines of the code (method lexical-v1);
  • neither the text of the paper nor the code itself.

Its JSON (tracing-map.json) is deposited on Zenodo with its DOI once the map is validated.

Data

No dataset and no data link were found in the paper.

Data availability

All code in this paper is publicly available at GitHub: https://github.com/Jy-Yang-bot/real-time-marmoset-recognition (copy archived at Yang, 2026). This repository contains the scripts for pre-processing the images, the main facial recognition pipeline, and the analytic tools. The program generalizability was tested on additional video obtained from publicly available online sources, including a YouTube video "Common Marmoset", uploaded by Billabong Zoo, Koala & Wildlife Park on 2 June 2020 (https://www.youtube.com/watch?v=lDJNk4rjqqQ). As per McGill policy on sharing and use of images of animals involved in Research, Teaching and Testing, we cannot upload the raw videos recorded within our animal facilities into a domain-specific public archive or generic repositories. However, those raw videos can be made available upon request by reaching out to the corresponding authors (Jiayue Yang and Justine Cléry).

Reproduced under the paper's license (CC BY), from the paper cited above.

Versions

The history of this record: each version stored by the harvester or made by a correction of its authors or of the maintainers of its code, and what changed in its facts. The texts of the paper (its abstract, its availability statements) are not part of it; versions that changed only those are not listed.

Version 1, 1 October 2026: the first record

Recorded: type, language, journal, volume, pages, dates, 3 authors, 7 keywords, 6 MeSH terms, 2 funders, 61 references.

Cite

This paper

Yang, J., Wang, J., & Cléry, J. (2026). A real-time, multi-animal model for automatic face detection and identification of freely moving common marmosets based on YOLOv8 algorithms. eLife, 15, RP110932. https://doi.org/10.7554/elife.110932

BibTeX

@article{yang2026real,
author = {Yang, Jiayue and Wang, James and Cléry, Justine},
title = {{A real-time, multi-animal model for automatic face detection and identification of freely moving common marmosets based on YOLOv8 algorithms}},
journal = {eLife},
year = {2026},
month = sep,
volume = {15},
pages = {RP110932},
publisher = {eLife Sciences Publications, Ltd},
issn = {2050-084X},
doi = {10.7554/elife.110932},
url = {https://doi.org/10.7554/elife.110932},
pmid = {42808519},
pmcid = {PMC13623377}
}

RIS

TY - JOUR
AU - Yang, Jiayue
AU - Wang, James
AU - Cléry, Justine
TI - A real-time, multi-animal model for automatic face detection and identification of freely moving common marmosets based on YOLOv8 algorithms
T2 - eLife
J2 - eLife
PY - 2026
DA - 2026/09/29
VL - 15
SP - RP110932
SN - 2050-084X
PB - eLife Sciences Publications, Ltd
DO - 10.7554/elife.110932
UR - https://doi.org/10.7554/elife.110932
LA - en
ER -

CSL-JSON

{
"id": "10.7554/elife.110932",
"type": "article-journal",
"title": "A real-time, multi-animal model for automatic face detection and identification of freely moving common marmosets based on YOLOv8 algorithms",
"container-title": "eLife",
"author": [
{
"family": "Yang",
"given": "Jiayue"
},
{
"family": "Wang",
"given": "James"
},
{
"family": "Cléry",
"given": "Justine"
}
],
"container-title-short": "eLife",
"volume": "15",
"page": "RP110932",
"DOI": "10.7554/elife.110932",
"PMID": "42808519",
"PMCID": "PMC13623377",
"ISSN": "2050-084X",
"publisher": "eLife Sciences Publications, Ltd",
"URL": "https://doi.org/10.7554/elife.110932",
"language": "en",
"issued": {
"date-parts": [
[
2026,
9,
29
]
]
}
}

The tracing map gets a citation of its own once an author has validated it and it has a DOI.

Similar papers

The papers with a page that share the most with this one: the tools found in their code, their categories, datasets, cited references and authors, the rarest counting most.

[1] doi:10.3389/fnbeh.2024.1509369 [code]
SARTAB, a scalable system for automated real-time behavior detection based on animal tracking and Region Of Interest analysis: validation on fish courtship behavior.
Journal: Frontiers in behavioral neuroscience
In common: OpenCV, Pillow, PyTorch, 6 other tools, methods / tools, 2 references
[2] doi:10.1038/s41593-025-02183-y [code]
Neural population geometry and optimal coding of tasks with shared latent structure.
Journal: Nature neuroscience
In common: OpenCV, Pillow, PyTorch, 6 other tools, 3 references
[3] doi:10.1007/s43440-024-00679-1 [code]
Assessing the effects of 5-HT<sub>2A</sub> and 5-HT<sub>5A</sub> receptor antagonists on DOI-induced head-twitch response in male rats using marker-less deep learning algorithms.
Journal: Pharmacological reports : PR
In common: OpenCV, Pillow, PyTorch, 6 other tools, 3 references
[4] doi:10.1038/s42003-024-07345-5 [code]
PreyTouch: a touchscreen-based closed-loop system for studying predator-prey interactions.
Journal: Communications biology
In common: OpenCV, Pillow, PyTorch, 6 other tools, methods / tools, 2 references
[5] doi:10.7554/elife.79305 [code]
Open-source tools for behavioral video analysis: Setup, methods, and best practices.
Journal: eLife
In common: OpenCV, Pillow, PyTorch, 6 other tools, methods / tools, 2 references
[6] doi:10.3389/fninf.2025.1515873 [code]
Net2Brain: a toolbox to compare artificial vision models with human brain responses.
Journal: Frontiers in neuroinformatics
In common: OpenCV, Pillow, PyTorch, 6 other tools, methods / tools, 1 reference
[7] doi:10.1016/j.isci.2026.116825 [code]
Social hierarchy shapes behavioral and transcriptional responses to chronic stress and ketamine in male mice.
Journal: iScience
In common: OpenCV, Pillow, PyTorch, 6 other tools, 2 references
[8] doi:10.1038/s41593-026-02232-0 [code]
Entorhinal cortex represents task-relevant remote locations independently of CA1.
Journal: Nature neuroscience
In common: OpenCV, Pillow, PyTorch, 6 other tools, 2 references
[9] doi:10.7554/elife.82376 [code]
Sex, strain, and lateral differences in brain cytoarchitecture across a large mouse population.
Journal: eLife
In common: OpenCV, Pillow, PyTorch, 6 other tools, methods / tools, 1 reference
[10] doi:10.1364/boe.605322 [code]
Generalized plaque digitization framework for multi-dimensional mesoscopic images.
Journal: Biomedical optics express
In common: OpenCV, Pillow, PyTorch, 6 other tools, 1 reference

Contribute

The authors of this paper can claim it, correct its record and validate its tracing map, and the maintainers of its code (its owner, or a public member of its organization) correct what it says of their repository; anyone signed in can ask for its removal. Every request goes to OSCR's own machine, which answers it; your account page follows them.

Sign in with ORCID to claim this paper as one of its authors, correct its record or validate its tracing map: when the paper's metadata lists your ORCID iD, you are recognized at once. Maintainers of its code: sign in with GitHub, then claim the repository on your account page.

Add the badge to the code's README

OSCR: the badge of this paper

If you are an author or a maintainer of this paper's code, you can add this badge. It says what OSCR knows of the paper (its code, its validated tracing map) and links the code to this page. Paste one of these snippets under the README's title. Keep the two marks around it, so that the badge can be replaced in place and is never added twice. OSCR changes nothing in your repository.

Markdown
<!-- oscr-badge:start -->
[![OSCR](https://openscicode.org/badge/doi/10.7554/elife.110932.svg)](https://openscicode.org/badge/doi/10.7554/elife.110932)
<!-- oscr-badge:end -->
reStructuredText
.. oscr-badge:start

.. image:: https://openscicode.org/badge/doi/10.7554/elife.110932.svg
   :target: https://openscicode.org/badge/doi/10.7554/elife.110932
   :alt: OSCR

.. oscr-badge:end
HTML
<!-- oscr-badge:start -->
<a href="https://openscicode.org/badge/doi/10.7554/elife.110932"><img src="https://openscicode.org/badge/doi/10.7554/elife.110932.svg" alt="OSCR"></a>
<!-- oscr-badge:end -->

On GitHub, open the README, choose Edit (the pencil), paste the snippet under the title, then "Commit changes".

If you choose to, you can have the badge kept up to date for you, with oscr badge --write from the command line or with the GitHub Action in your repository's workflows. Every other form and option (a card, AsciiDoc, LaTeX, shields.io) is on the badge page.

Request its removal

To ask OSCR to remove this record, the copies of its authors' scripts or its tracing map, use the removal request page: signed in, you say who you are, what to remove and why, then review and confirm the request. Published rules decide every request (how).

Discussion, reproductions, activity

Discussion: code errors and mismatches between the code and the paper about this paper and its code, from readers and its authors, beside the paper and its tracing map.

Report a mismatch between the code and the paper · Report a code error (signed in)

Reproductions: reports from readers who ran the authors' code and did not get the paper's result, what they ran, with which environment, commit and data.

Report a reproduction failure (signed in)

Versions of its code: the releases of its code tied to a version of this paper (the preprint, the accepted manuscript, the version of record…), each with the tracing map versioned with it.

Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.