OSCR

Distinct roles of cortical layer 5 subtypes in associative learning.

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 · all tie a paragraph to a whole file without given lines: weak matches, whose lines are not tinted
  1. [1] § Methods › Computational model › IT network pretraining ↔ ET_IT_striatum-main.zip/preTrain_IT_network/IT_NN.py, the whole file · a weak match · score 0.70 · auto encoder, unsupervised learning, bottleneck, reconstructed, loss, decoder · Report a mismatch
  2. [2] § Methods › Computational model ↔ ET_IT_striatum-main.zip/ValueBased_model/Value_lNN.py, the whole file · a weak match · score 0.64 · synaptic weights, neural network, sigmoid, linear, modeled, prediction · Report a mismatch
  3. [3] § Methods › Computational model › IT network pretraining ↔ ET_IT_striatum-main.zip/ValueBased_model/Value_lNN.py, the whole file · a weak match · score 0.59 · synaptic weights, neural network, loss · 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 · 74 lines · 3.1 KB · CC-BY-4.0 · 2 matches

  1. import torch
  2. import torch.nn as nn
  3. import torch.optim as opt
  4. from torch.distributions.bernoulli import Bernoulli
  5. class Striatum_lNN(nn.Module):
  6. def __init__(self, input_s, IT_inpt_s, ln_rate, h_size, thalamic_input_lr=1e-3):
  7. """ Implement a Striatal network as a linear neural network, lNN, trying to predict the rwd """
  8. super().__init__()
  9. self.thalamic_input_s = input_s
  10. self.IT_inpt_s = IT_inpt_s
  11. # Striatum takes input x, IT input and ET input, initialise different synaptic weights for each
  12. self.W_thalamus = nn.Linear(input_s, h_size)
  13. #self.W_IT = nn.Linear(self.IT_inpt_s, h_size)
  14. self.W_IT = nn.Linear(self.IT_inpt_s, h_size)
  15. self.l_habituation = nn.Linear(h_size, 1)
  16. #self.l_rwd_pred = nn.Linear(h_size+self.thalamic_input_s, 1)
  17. self.l_rwd_pred = nn.Linear(2*h_size, 1)
  18. with torch.no_grad():
  19. self.l_rwd_pred.bias.copy_(torch.randn(1) * 0.1 - 5 *torch.ones(1)) ## Initialise values close to zero
  20. self.l_habituation.bias.copy_(torch.randn(1) * 0.1 - 5 *torch.ones(1)) ## Initialise values close to zero
  21. # Define optimizer
  22. self.optimizer = opt.Adam([
  23. #self.optimizer = opt.SGD([
  24. {'params': self.W_IT.parameters()},
  25. {'params': self.l_rwd_pred.parameters()},
  26. {'params': self.W_thalamus.parameters(), 'lr':thalamic_input_lr},
  27. {'params': self.l_habituation.parameters(), 'lr':thalamic_input_lr}
  28. ], lr=ln_rate )#, momentum=0.8)
  29. def forward(self, thalamic_pre, IT_pre):
  30. """ Process the cortical inputs through the two separate striatal components, then unify the two to make a prediction"""
  31. #thalamic_post = torch.relu(self.W_thalamus(thalamic_pre.view(-1,self.thalamic_input_s)))
  32. #IT_post = torch.relu(self.W_IT(IT_pre.view(-1,self.IT_inpt_s)))
  33. # include thalamic input as skip connection
  34. #IT_post = torch.cat([thalamic_pre.view(-1,self.thalamic_input_s), IT_post], dim=1)
  35. thalamic_post = self.W_thalamus(thalamic_pre.view(-1,self.thalamic_input_s))
  36. IT_post = self.W_IT(IT_pre.view(-1,self.IT_inpt_s))
  37. comb_inpt = torch.cat([thalamic_post.detach(), IT_post], dim=1) # thalamic weights only trained to pred rwd without cortex
  38. rwd_pred = torch.sigmoid(self.l_rwd_pred(comb_inpt))
  39. noCortex_rwd_pred = torch.sigmoid(self.l_habituation(thalamic_post))
  40. return rwd_pred.squeeze(), noCortex_rwd_pred.squeeze()
  41. def update(self, rwd_pred, noCortex_rwd_pred, RPE_grad):
  42. """ update the newtork based on observed rwd"""
  43. #torch.sum(rwd_pred,dim=0,keepdim=True).unsqueeze(0).backward(gradient=RPE.unsqueeze(0))
  44. batch_rwd_pred = torch.sum(rwd_pred) # use sum since they are all independent batches
  45. rwd_pred.backward(gradient=RPE_grad)
  46. no_cortex_loss = torch.mean((rwd_pred.detach() - noCortex_rwd_pred)**2) # Striatum tries to learn its own predictions from contrical inputs using the thalamic inputs
  47. no_cortex_loss.backward()
  48. self.optimizer.step()
  49. self.optimizer.zero_grad()
  50. return no_cortex_loss.detach().item()

Value_lNN.py, under CC-BY-4.0 · at the source

Overview

Authors: Sara Moberg1,2, Michele Garibbo3,4, Camille Mazo5, Ariel Gilad6, Dietmar Schmitz1,7,8,9,10,11, Rui Ponte Costa3, Matthew E Larkum2, Naoya Takahashi5
  1. Charité - Universitätsmedizin Berlin, corporate member of Freie Universität Berlin and Humboldt Universität zu Berlin, Einstein Center for Neurosciences Berlin, Berlin, Germany
  2. Institute for Biology, Humboldt University of Berlin, Berlin, Germany
  3. Centre for Neural Circuits and Behaviour, Department of Physiology, Anatomy and Genetics, University of Oxford, Oxford, United Kingdom
  4. Bristol Computational Neuroscience Unit, Intelligent Systems Lab, Faculty of Engineering, University of Bristol, Bristol, United Kingdom
  5. University of Bordeaux, CNRS, Interdisciplinary Institute for Neuroscience, IINS, UMR 5297, Bordeaux, France
  6. Department of Medical Neurobiology, Faculty of Medicine, Institute for Medical Research Israel-Canada (IMRIC), The Hebrew University of Jerusalem, Jerusalem, Israel
  7. Charité - Universitätsmedizin Berlin, corporate member of Freie Universität Berlin and Humboldt Universität zu Berlin, Neuroscience Research Center, Berlin, Germany
  8. Charité - Universitätsmedizin Berlin, corporate member of Freie Universität Berlin and Humboldt Universität zu Berlin, NeuroCure Cluster of Excellence, Berlin, Germany
  9. Bernstein Center for Computational Neuroscience Berlin, Berlin, Germany
  10. German Center for Neurodegenerative Diseases (DZNE) Berlin, Berlin, Germany
  11. Max-Delbrück Center for Molecular Medicine in the Helmholtz Association, Berlin, Germany
Journal: Nature communications, volume 17, issue 1, article 2648
Dates: received 16 December 2024; accepted 4 January 2026; published online 20 March 2026
Type: Research article · Language: English
License: CC BY
Identifiers: DOI 10.1038/s41467-026-68307-5 · PMID 41862437 · PMCID PMC13004866 · OpenAlex W7138904036
Open access: gold, a free copy (OpenAlex)
Status: code verified (how the code is found and verified)
Categories: mouse (organism), systems (subfield)
Methods: Connectivity, Statistics, Machine learning, Preprocessing, fMRI & imaging, Single-unit activity, calcium imaging, Smoothing, state filtering, decompositions
Keywords: Sensory processing, Barrel cortex, Cortex
MeSH: Association Learning*, Neurons*, Somatosensory Cortex*, Animals, Conditioning, Classical, Cues, Male, Mice, Mice, Transgenic, Reward, Vibrissae (* major topic)
Topic: Memory and Neural Mechanisms (Cognitive Neuroscience, Neuroscience), according to OpenAlex
Funding: EC | Horizon 2020 Framework Programme (EU Framework Programme for Research and Innovation H2020) (670118/ERC ActiveCortex, 101148941, 785907/HBP, 945539/HBP, SGA1-3: 72070/HBP, 101055340/ERC Cortical Coupling); RCUK | Engineering and Physical Sciences Research Council (EP/X029336/1); Deutsche Forschungsgemeinschaft (EXC-2049 – 390688087, 327654276/SFB1315, LA 3442/3-1, LA 3442/6-1, EXC-2049 - 390688087); Conseil Régional Aquitaine; Université de Bordeaux; European Research Council (101055340); Einstein Stiftung Berlin (Einstein Foundation Berlin) (A-2021-644, EZ-2014-226); Biotechnology and Biological Sciences Research Council (BB/X013340/1); Fondation pour la Recherche Médicale (EQU202403018077); Wellcome Trust (S122871-115); Centre National de la Recherche Scientifique; Agence Nationale de la Recherche (French National Research Agency) (ANR-24-CE16-7349, ANR-24-CE37-5761); RCUK | Biotechnology and Biological Sciences Research Council (BB/X013340/1); Schlumberger Foundation (FSER202401018842)
Citations: cited by 3 papers (Europe PMC); 52 references in the paper

Abstract

Adaptive behavior relies on associating sensory cues with rewarding or aversive outcomes. In mammals, the primary sensory cortex processes stimuli and distributes information to cortical and subcortical targets. Layer 5 (L5) contains two major projection neuron classes, intratelencephalic (IT) and extratelencephalic (ET); however, their roles in associative learning remain unclear. Using transgenic mice, we identified IT and ET neurons in primary somatosensory cortex and tracked their activity with longitudinal two-photon imaging during Pavlovian conditioning with whisker stimulation. IT neurons stably encoded stimulus identity across training, whereas ET neurons showed dynamic changes that paralleled the emergence of anticipatory licking. Chemogenetic silencing of each subtype impaired learning in distinct, phase-specific ways. A reinforcement-learning model reproduced these dynamics, suggesting that IT neurons provide stable sensory representations needed to form cue-reward associations, while ET neurons encode reward expectation to refine behavior. These findings reveal complementary, cell-type-specific contributions of L5 neurons to associative learning.

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.

Zenodo 17720603

License: CC-BY-4.0
State: the link answers, verified on 30 September 2026
Evidence: files inventoried
Size: 2 files
Software Heritage: not checked
Found in: “Code availability”
Not found: README, license file, CITATION.cff, environment file, tests, continuous integration, documentation
Tools: PyTorch (7 files), NumPy (6 files), Matplotlib (3 files)
Availability: 1 check, the latest on 30 September 2026: the link answers (HTTP 200)
  • 30 September 2026: the link answers (HTTP 200)
8 files
At the source:

Code availability

The code used in this study are available via Zenodo at 10.5281/zenodo.17720603.

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

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;
  • 7 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

The data used in this study are available via Zenodo at 10.5281/zenodo.17720603. Source data are provided with this paper.

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, 30 September 2026: the first record

Recorded: type, language, journal, volume, issue, pages, dates, 8 authors, 3 keywords, 11 MeSH terms, 14 funders, 50 references.

Cite

This paper

Moberg, S., Garibbo, M., Mazo, C., Gilad, A., Schmitz, D., Costa, R. P., Larkum, M. E., & Takahashi, N. (2026). Distinct roles of cortical layer 5 subtypes in associative learning. Nature communications, 17(1), 2648. https://doi.org/10.1038/s41467-026-68307-5

BibTeX

@article{moberg2026distinct,
author = {Moberg, Sara and Garibbo, Michele and Mazo, Camille and Gilad, Ariel and Schmitz, Dietmar and Costa, Rui Ponte and Larkum, Matthew E and Takahashi, Naoya},
title = {{Distinct roles of cortical layer 5 subtypes in associative learning}},
journal = {Nature communications},
year = {2026},
month = mar,
volume = {17},
number = {1},
pages = {2648},
publisher = {Nature Publishing Group},
issn = {2041-1723},
doi = {10.1038/s41467-026-68307-5},
url = {https://doi.org/10.1038/s41467-026-68307-5},
pmid = {41862437},
pmcid = {PMC13004866}
}

RIS

TY - JOUR
AU - Moberg, Sara
AU - Garibbo, Michele
AU - Mazo, Camille
AU - Gilad, Ariel
AU - Schmitz, Dietmar
AU - Costa, Rui Ponte
AU - Larkum, Matthew E
AU - Takahashi, Naoya
TI - Distinct roles of cortical layer 5 subtypes in associative learning
T2 - Nature communications
J2 - Nat Commun
PY - 2026
DA - 2026/03/20
VL - 17
IS - 1
SP - 2648
SN - 2041-1723
PB - Nature Publishing Group
DO - 10.1038/s41467-026-68307-5
UR - https://doi.org/10.1038/s41467-026-68307-5
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41467-026-68307-5",
"type": "article-journal",
"title": "Distinct roles of cortical layer 5 subtypes in associative learning",
"container-title": "Nature communications",
"author": [
{
"family": "Moberg",
"given": "Sara"
},
{
"family": "Garibbo",
"given": "Michele"
},
{
"family": "Mazo",
"given": "Camille"
},
{
"family": "Gilad",
"given": "Ariel"
},
{
"family": "Schmitz",
"given": "Dietmar"
},
{
"family": "Costa",
"given": "Rui Ponte"
},
{
"family": "Larkum",
"given": "Matthew E"
},
{
"family": "Takahashi",
"given": "Naoya"
}
],
"container-title-short": "Nat Commun",
"volume": "17",
"issue": "1",
"page": "2648",
"DOI": "10.1038/s41467-026-68307-5",
"PMID": "41862437",
"PMCID": "PMC13004866",
"ISSN": "2041-1723",
"publisher": "Nature Publishing Group",
"URL": "https://doi.org/10.1038/s41467-026-68307-5",
"language": "en",
"issued": {
"date-parts": [
[
2026,
3,
20
]
]
}
}

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.7554/elife.111876 [code]
Distinct sensorimotor encoding in tuft dendrites and somata associated with action, correction, and learning.
Journal: eLife
In common: PyTorch, Matplotlib, NumPy, mouse, 10 references
[2] doi:10.1126/sciadv.aef3715
A cortical output channel for perceptual categorization.
Journal: Science advances
In common: mouse, 11 references
[3] doi:10.7554/elife.98349
Learning enhances behaviorally relevant representations in apical dendrites.
Journal: eLife
In common: mouse, 10 references
[4] doi:10.1038/s41467-024-48924-8
Organization of corticocortical and thalamocortical top-down inputs in the primary visual cortex.
Journal: Nature communications
In common: systems, mouse, 9 references
[5] doi:10.1523/eneuro.0060-22.2022 [code]
Dendritic Compartmentalization of Learning-Related Plasticity.
Journal: eNeuro
In common: Matplotlib, NumPy, mouse, 7 references
[6] doi:10.1073/pnas.2508836122 [code]
Autism-associated <i>Scn2a</i> haploinsufficiency disrupts in vivo dendritic signaling and impairs flexible decision-making.
Journal: Proceedings of the National Academy of Sciences of the United States of America
In common: mouse, 8 references
[7] doi:10.1038/s41593-022-01245-9 [code]
Pyramidal cell types drive functionally distinct cortical activity patterns during decision-making.
Journal: Nature neuroscience
In common: 9 references
[8] doi:10.1073/pnas.2308670120 [code]
A thalamocortical substrate for integrated information via critical synchronous bursting.
Journal: Proceedings of the National Academy of Sciences of the United States of America
In common: systems, 4 references, author Matthew E Larkum
[9] doi:10.7554/elife.83702 [code]
History information emerges in the cortex during learning.
Journal: eLife
In common: systems, mouse, 3 references, author Ariel Gilad
[10] doi:10.1038/s41467-023-43066-9
Nigrostriatal dopamine modulates the striatal-amygdala pathway in auditory fear conditioning.
Journal: Nature communications
In common: mouse, 7 references

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.1038/s41467-026-68307-5.svg)](https://openscicode.org/badge/doi/10.1038/s41467-026-68307-5)
<!-- oscr-badge:end -->
reStructuredText
.. oscr-badge:start

.. image:: https://openscicode.org/badge/doi/10.1038/s41467-026-68307-5.svg
   :target: https://openscicode.org/badge/doi/10.1038/s41467-026-68307-5
   :alt: OSCR

.. oscr-badge:end
HTML
<!-- oscr-badge:start -->
<a href="https://openscicode.org/badge/doi/10.1038/s41467-026-68307-5"><img src="https://openscicode.org/badge/doi/10.1038/s41467-026-68307-5.svg" alt="OSCR"></a>
<!-- oscr-badge:end -->

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)

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