OSCR

Homeostatic dendritic neuron based on co-integrated volatile and non-volatile memristors for neuromorphic processing.

Code ↔ Paper

2 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.

2 blocks of code here have a permanent identifier (oscr:b:…), listed with the matches below: citable for good, with a page of its own. Select a match and press Cite to copy it. What a block identifier is.

The 2 matches
  1. [1] § Methods › Preprocessing for the speech command dataset ↔ GSC/data.py, lines 33 to 149 · score 0.70 · speech commands, 4 kHz, spectrograms, Mel, word, audio · block oscr:b:PJYKBD68F9ED9-9 · Report a mismatch
  2. [2] § Methods › Preprocessing for the fault diagnosis dataset ↔ CWRU/data_process_CRWU.py, lines 43 to 118 · score 0.52 · inner, outer, diameters, ball, baseline, fault · block oscr:b:569JA7C12C0FX-0 · 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 · 167 lines · 5.6 KB · no license · 1 match

  1. import torch
  2. import torchaudio
  3. import matplotlib.pyplot as plt
  4. import IPython.display as ipd
  5. from torchaudio.datasets import SPEECHCOMMANDS
  6. import os
  7. import json
  8. import numpy as np
  9. import torch
  10. import librosa
  11. from sklearn.preprocessing import normalize
  12. import numpy as np
  13. import librosa
  14. class SubsetSC(SPEECHCOMMANDS):
  15. def __init__(self, subset: str = None):
  16. super().__init__(r"/root/", download=False)
  17. def load_list(filename):
  18. filepath = os.path.join(self._path, filename)
  19. with open(filepath) as fileobj:
  20. return [os.path.join(self._path, line.strip()) for line in fileobj]
  21. if subset == "validation":
  22. self._walker = load_list("validation_list.txt")
  23. elif subset == "testing":
  24. self._walker = load_list("testing_list.txt")
  25. elif subset == "training":
  26. excludes = load_list("validation_list.txt") + load_list("testing_list.txt")
  27. excludes = set(excludes)
  28. self._walker = [w for w in self._walker if w not in excludes]
  29. class SpeechCommandsDataset:
  30. def __init__(self, batch_size=256, device="cuda"):
  31. self.device = torch.device(device)
  32. self.batch_size = batch_size
  33. self.train_set = SubsetSC("training")
  34. self.test_set = SubsetSC("testing")
  35. self.val_set = SubsetSC("validation")
  36. self.labels_file = "speechcommand_labels.json"
  37. if os.path.exists(self.labels_file):
  38. with open(self.labels_file, 'r') as f:
  39. self.labels = json.load(f)
  40. else:
  41. self.labels = sorted(list(set(datapoint[2] for datapoint in self.train_set)))
  42. with open(self.labels_file, 'w') as f:
  43. json.dump(self.labels, f)
  44. self.train_loader = self._create_data_loader(self.train_set, shuffle=True)
  45. self.test_loader = self._create_data_loader(self.test_set, shuffle=False)
  46. self.val_loader = self._create_data_loader(self.val_set, shuffle=False)
  47. def _create_data_loader(self, dataset, shuffle):
  48. if self.device == "cuda":
  49. num_workers = 8
  50. pin_memory = True
  51. else:
  52. num_workers = 0
  53. pin_memory = False
  54. return torch.utils.data.DataLoader(
  55. dataset,
  56. batch_size=self.batch_size,
  57. shuffle=shuffle,
  58. collate_fn=self.collate_fn,
  59. num_workers=num_workers,
  60. pin_memory=pin_memory,
  61. )
  62. def label_to_index(self, word):
  63. return torch.tensor(self.labels.index(word))
  64. def index_to_label(self, index):
  65. return self.labels[index]
  66. def pad_sequence(self, batch):
  67. batch = [item.t() for item in batch]
  68. batch = torch.nn.utils.rnn.pad_sequence(batch, batch_first=True, padding_value=0.)
  69. return batch.permute(0, 2, 1)
  70. def mel_spectrogram(self, wav):
  71. sr =16000
  72. delta_order=2
  73. stack=True
  74. S = librosa.feature.melspectrogram(y=wav,
  75. sr=sr,
  76. n_fft=int(30e-3*sr),
  77. hop_length=int(10e-3*sr),
  78. n_mels=40,
  79. fmax=4000,
  80. fmin=20
  81. )
  82. M = np.max(np.abs(S))
  83. if M > 0:
  84. feat = np.log1p(S / M)
  85. else:
  86. feat = S
  87. if delta_order is not None:
  88. feat_list = [feat.T]
  89. for k in range(1, delta_order + 1):
  90. feat_list.append(librosa.feature.delta(feat, order=k).T)
  91. if stack:
  92. return np.stack(feat_list)
  93. else:
  94. return np.expand_dims(feat.T, 0)
  95. else:
  96. return np.expand_dims(feat.T, 0)
  97. def rescale(self, input):
  98. std = np.std(input, axis=1, keepdims=True)
  99. std[std == 0] = 1
  100. return input / std
  101. def collate_fn(self, batch):
  102. tensors, targets = [], []
  103. for waveform, _, label, *_ in batch:
  104. tensors += [waveform]
  105. targets += [self.label_to_index(label)]
  106. tensors = self.pad_sequence(tensors)
  107. tensors = self.mel_spectrogram(tensors.numpy())
  108. tensors = self.rescale(tensors)
  109. tensors = torch.tensor(tensors, dtype=torch.float64).squeeze(3).permute(3, 0, 1, 2)
  110. targets = torch.stack(targets)
  111. return tensors, targets
  112. def play_audio(self, index=0):
  113. waveform, sample_rate = self.train_set[index][0], self.train_set[index][1]
  114. return ipd.Audio(waveform.numpy(), rate=sample_rate)
  115. def play_resampled_audio(self, index=0, new_sample_rate=8000):
  116. waveform, sample_rate = self.train_set[index][0], self.train_set[index][1]
  117. transform = torchaudio.transforms.Resample(orig_freq=sample_rate, new_freq=new_sample_rate)
  118. transformed = transform(waveform)
  119. return ipd.Audio(transformed.numpy(), rate=new_sample_rate)
  120. def plot_audio(self,index=0):
  121. waveform, sample_rate, *_ = self.train_set[index]
  122. print("Shape of waveform: {}".format(waveform.size()))
  123. print("Sample rate of waveform: {}".format(sample_rate))
  124. plt.plot(waveform.t().numpy())
  125. if __name__ == "__main__":
  126. dataset = SpeechCommandsDataset()
  127. dataset.test_loader
  128. dataset.train_loader
  129. dataset.play_audio()
  130. dataset.play_resampled_audio()
  131. dataset.plot_audio()
  132. a = dataset.test_loader
  133. for batch_idx, (inputs, targets) in enumerate(a):
  134. print(f"Batch {batch_idx + 1}:")
  135. print(f"Inputs: {inputs.shape}")
  136. print(f"Targets: {targets.shape}")
  137. if batch_idx == 1:
  138. break

data.py at commit c0d39bd, no license · at the source

Overview

Authors: Licheng Zhang1,2, Teng Zhang3, Pek Jun Tiw3, Xulei Wu1, Yuqi Su1,2, Yuchao Yang1,2,3,4
  1. New Cornerstone Science Laboratory, Guangdong Provincial Key Laboratory of In-Memory Computing Chips, School of Electronic and Computer Engineering, Shenzhen Graduate School, Peking University,Shenzhen, China
  2. Peng Cheng Laboratory,Shenzhen, China
  3. New Cornerstone Science Laboratory, Beijing Advanced Innovation Center for Integrated Circuits, School of Integrated Circuits, Peking University,Beijing, China
  4. Center for Brain Inspired Intelligence, Chinese Institute for Brain Research (CIBR),Beijing, China
Journal: Nature communications, volume 17, issue 1, article 6918
Dates: received 30 June 2025; accepted 15 May 2026; published online 28 May 2026
Type: Research article · Language: English
License: CC BY-NC-ND
Identifiers: DOI 10.1038/s41467-026-73669-x · PMID 42209470 · PMCID PMC13388921 · OpenAlex W7162672775
Open access: gold, a free copy (OpenAlex)
Status: code verified (how the code is found and verified)
Methods: Spectral & time-frequency
Keywords: Electronic devices
MeSH: Dendrites*, Homeostasis*, Neural Networks, Computer*, Neurons*, Signal Processing, Computer-Assisted*, Action Potentials, Models, Neurological (* major topic)
Topic: Advanced Memory and Neural Computing (Electrical and Electronic Engineering, Engineering), according to OpenAlex
Citations: cited by 1 paper (Europe PMC); 69 references in the paper

Abstract

The abstract is not reproduced here: the paper's license (CC BY-NC-ND) does not allow it. Read it in the paper, at the publisher or on Europe PMC.

Repositories

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

Zenodo 20073414

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

lichengzhangcim/homeostatic-dendritic-neuron

License: none: the authors keep all their rights
State: the link answers, verified on 28 September 2026
Evidence: files inventoried
Commit: c0d39bd18fc41af4c68bd4985ba85d0b0f9a3a31, 16 December 2025
Languages: Python (12)
Size: 15 files, 12 scripts
Software Heritage: not archived
Found in: the Zenodo archive record
Holds: README
Not found: license file, CITATION.cff, environment file, tests, continuous integration, documentation
Tools: PyTorch (11 files), NumPy (4 files), Matplotlib (3 files), scikit-learn (2 files), SciPy (2 files)
Availability: 1 check, the latest on 28 September 2026: the link answers
  • 28 September 2026: the link answers
13 files

Code availability statement

The paper has a code availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:

  • it points to the authors' code: Zenodo 20073414

Read it in the paper: doi.org/10.1038/s41467-026-73669-x.

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:

  • 2 repositories of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
  • 24 scripts, each with its path and the digest of its content;
  • 2 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

Datasets cited

Data availability statement

The paper has a data availability statement. Its license (CC BY-NC-ND) does not allow reproducing it here; in short, from what the harvester recognized in it:

Read it in the paper: doi.org/10.1038/s41467-026-73669-x.

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

Recorded: type, language, journal, volume, issue, pages, dates, 6 authors, 1 keyword, 7 MeSH terms, 62 references.

Cite

This paper

Zhang, L., Zhang, T., Tiw, P. J., Wu, X., Su, Y., & Yang, Y. (2026). Homeostatic dendritic neuron based on co-integrated volatile and non-volatile memristors for neuromorphic processing. Nature communications, 17(1), 6918. https://doi.org/10.1038/s41467-026-73669-x

BibTeX

@article{zhang2026homeostatic,
author = {Zhang, Licheng and Zhang, Teng and Tiw, Pek Jun and Wu, Xulei and Su, Yuqi and Yang, Yuchao},
title = {{Homeostatic dendritic neuron based on co-integrated volatile and non-volatile memristors for neuromorphic processing}},
journal = {Nature communications},
year = {2026},
month = may,
volume = {17},
number = {1},
pages = {6918},
publisher = {Nature Publishing Group},
issn = {2041-1723},
doi = {10.1038/s41467-026-73669-x},
url = {https://doi.org/10.1038/s41467-026-73669-x},
pmid = {42209470},
pmcid = {PMC13388921}
}

RIS

TY - JOUR
AU - Zhang, Licheng
AU - Zhang, Teng
AU - Tiw, Pek Jun
AU - Wu, Xulei
AU - Su, Yuqi
AU - Yang, Yuchao
TI - Homeostatic dendritic neuron based on co-integrated volatile and non-volatile memristors for neuromorphic processing
T2 - Nature communications
J2 - Nat Commun
PY - 2026
DA - 2026/05/28
VL - 17
IS - 1
SP - 6918
SN - 2041-1723
PB - Nature Publishing Group
DO - 10.1038/s41467-026-73669-x
UR - https://doi.org/10.1038/s41467-026-73669-x
LA - en
ER -

CSL-JSON

{
"id": "10.1038/s41467-026-73669-x",
"type": "article-journal",
"title": "Homeostatic dendritic neuron based on co-integrated volatile and non-volatile memristors for neuromorphic processing",
"container-title": "Nature communications",
"author": [
{
"family": "Zhang",
"given": "Licheng"
},
{
"family": "Zhang",
"given": "Teng"
},
{
"family": "Tiw",
"given": "Pek Jun"
},
{
"family": "Wu",
"given": "Xulei"
},
{
"family": "Su",
"given": "Yuqi"
},
{
"family": "Yang",
"given": "Yuchao"
}
],
"container-title-short": "Nat Commun",
"volume": "17",
"issue": "1",
"page": "6918",
"DOI": "10.1038/s41467-026-73669-x",
"PMID": "42209470",
"PMCID": "PMC13388921",
"ISSN": "2041-1723",
"publisher": "Nature Publishing Group",
"URL": "https://doi.org/10.1038/s41467-026-73669-x",
"language": "en",
"issued": {
"date-parts": [
[
2026,
5,
28
]
]
}
}

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.1038/s41467-026-68905-3 [code]
Homogeneous integration of two-dimensional material-based optoelectronic neurons and ferroelectric synapses for neuromorphic vision.
Journal: Nature communications
In common: PyTorch, SciPy, Matplotlib, 1 other tool, 1 reference, 3 authors
[2] doi:10.1038/s41467-022-31747-w [code]
A calibratable sensory neuron based on epitaxial VO<sub>2</sub> for spike-based neuromorphic multisensory system.
Journal: Nature communications
In common: PyTorch, NumPy, 2 references, 2 authors
[3] doi:10.3389/fnins.2024.1449181 [code]
Exploring neural oscillations during speech perception via surrogate gradient spiking neural networks.
Journal: Frontiers in neuroscience
In common: PyTorch, SciPy, Matplotlib, 1 other tool, 5 references
[4] doi:10.1038/s41467-022-35747-8 [code]
Introducing the Dendrify framework for incorporating dendrites to spiking neural networks.
Journal: Nature communications
In common: SciPy, Matplotlib, NumPy, 6 references
[5] doi:10.3389/fnins.2022.865897 [code]
A surrogate gradient spiking baseline for speech command recognition.
Journal: Frontiers in neuroscience
In common: PyTorch, NumPy, 5 references
[6] doi:10.1038/s41467-026-68858-7 [code]
Bioinspired spiking architecture enables energy constrained touch encoding.
Journal: Nature communications
In common: SciPy, Matplotlib, NumPy, 4 references
[7] doi:10.1038/s41467-024-52132-9 [code]
An emergent attractor network in a passive resistive switching circuit.
Journal: Nature communications
In common: 2 references, author Yuchao Yang
[8] doi:10.3389/fnins.2022.945037 [code]
MAP-SNN: Mapping spike activities with multiplicity, adaptability, and plasticity into bio-plausible spiking neural networks.
Journal: Frontiers in neuroscience
In common: PyTorch, SciPy, Matplotlib, 1 other tool, 4 references
[9] doi:10.1038/s41467-025-63771-x [code]
Efficient and robust temporal processing with neural oscillations modulated spiking neural networks.
Journal: Nature communications
In common: PyTorch, scikit-learn, SciPy, 2 other tools, 3 references
[10] doi:10.3389/fnins.2022.1079357 [code]
STSC-SNN: Spatio-Temporal Synaptic Connection with temporal convolution and attention for spiking neural networks.
Journal: Frontiers in neuroscience
In common: PyTorch, scikit-learn, SciPy, 2 other tools, 3 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-73669-x.svg)](https://openscicode.org/badge/doi/10.1038/s41467-026-73669-x)
<!-- oscr-badge:end -->
reStructuredText
.. oscr-badge:start

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

.. oscr-badge:end
HTML
<!-- oscr-badge:start -->
<a href="https://openscicode.org/badge/doi/10.1038/s41467-026-73669-x"><img src="https://openscicode.org/badge/doi/10.1038/s41467-026-73669-x.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.