Resolving synaptic events using subsynaptically targeted GCaMP8 variants.
The 1 match · it ties a paragraph to a whole file, not to given lines: a weak match, whose lines are not tinted
- [1] § Materials and methods › CaFire program ↔ core/calculate_decay.py, the whole file · a weak match · score 0.54 · curve fit, decay function, GUI, peak
Paper
Loaded from Europe PMC by your browser, not stored by OSCR: doi.org · Europe PMC
The paper is loaded when this pane is shown.
The authors' code
Python · 130 lines · 5.1 KB · MIT · 1 match
- import numpy as np
- from tkinter import messagebox
- from scipy.optimize import curve_fit
- def decay_function(t, tau, y0):
- """
- Natural Logarithm of Decay Formula. y = y0 * e^{-t/tau}
- """
- return y0 * np.exp(-t / tau)
- def calculate_decay(app, single_peak=None, no_draw=False):
- total_peaks = len(app.marked_peaks)
- # Sort marked peaks by time
- app.marked_peaks = sorted(app.marked_peaks, key=lambda peak: peak[0])
- # If a single peak is provided, only calculate decay for that peak
- if single_peak:
- peak_index = app.marked_peaks.index(single_peak)
- peaks_to_process = [(peak_index, single_peak)]
- else:
- peaks_to_process = list(enumerate(app.marked_peaks))
- # Calculate the standard deviation range of the baseline
- baseline_mean = np.mean(app.baseline_values)
- baseline_std = np.std(app.baseline_values)
- peak_values = [peak[1] for peak in app.marked_peaks]
- mean_peak_value = np.mean(peak_values)
- ratio = (mean_peak_value - baseline_mean) / baseline_std
- if (ratio <= 5):
- baseline_upper = baseline_mean
- elif (ratio > 5 and ratio <= 10):
- baseline_upper = baseline_mean + baseline_std
- else:
- baseline_upper = baseline_mean + 2 * baseline_std
- baseline_range = (baseline_mean - 2 * baseline_std, baseline_upper)
- for i, (current_peak_time, current_peak_value) in peaks_to_process:
- # Skip if decay has already been calculated for this peak
- if app.decay_calculated[i]:
- continue
- current_peak_index = app.time[app.time == current_peak_time].index[0]
- # Define next peak index if it exists
- if i + 1 < len(app.marked_peaks):
- next_peak_index = app.time[app.time == app.marked_peaks[i + 1][0]].index[0]
- else:
- next_peak_index = len(app.df_f)
- # Find the first point in the range between the current peak and the next peak that is in the baseline range
- search_range = app.df_f[current_peak_index:next_peak_index]
- baseline_points = np.where((search_range >= baseline_range[0]) &
- (search_range <= baseline_range[1]))[0]
- if len(baseline_points) > 0:
- # Found a point in the baseline range, use the first point
- min_index_between_peaks = current_peak_index + baseline_points[0]
- else:
- # Not found a point in the baseline range, use the minimum value point
- min_index_between_peaks = np.argmin(search_range) + current_peak_index
- # Prepare data for fitting
- t_data = app.time[current_peak_index:min_index_between_peaks + 1].values
- t_data_range = t_data - t_data[0] # Make time start from 0
- y_data_original = np.array(app.df_f[current_peak_index:min_index_between_peaks + 1])
- # Ensure initial value is valid
- y0 = y_data_original[0]
- if np.isnan(y0) or y0 == 0:
- y0 = 0.001
- # Fit decay function
- try:
- # Calculate scaling factors for normalization
- t_scale = t_data_range.max()
- y_scale = np.max(y_data_original) - np.min(y_data_original)
- if y_scale < 0.01:
- y_scale = 0.01
- # Normalize both time and y data
- t_norm = t_data_range / t_scale
- y_data_norm = y_data_original / y_scale
- y0_norm = y0 / y_scale
- # Fit using normalized data
- popt, _ = curve_fit(
- lambda t, tau_norm: decay_function(t * t_scale, tau_norm * t_scale, y0_norm),
- t_norm,
- y_data_norm,
- p0=[0.5],
- bounds=(0.0001, np.inf)
- )
- # Convert normalized tau back to real scale
- tau_fitted = popt[0] * t_scale
- # Generate fitting curve using real time scale
- t_fit = np.linspace(0, t_data_range[-1], 100)
- y_fit_norm = decay_function(t_fit, tau_fitted, y0_norm)
- # Scale y values back to original magnitude
- y_fit = y_fit_norm * y_scale
- # Plot fitting curve
- decay_line, = app.ax.plot(
- t_data[0] + t_fit, # Add back actual starting time
- y_fit,
- color='#FF00FF',
- linestyle='--'
- )
- app.decay_lines.append(decay_line)
- app.decay_line_map[(current_peak_time, current_peak_value)] = decay_line
- app.tau_values[(current_peak_time, current_peak_value)] = tau_fitted
- app.decay_calculated[i] = True
- # Update progress
- if not single_peak:
- progress = 0.7 + (0.3 * (i + 1) / total_peaks)
- app.progress_bar.set(progress)
- app.update() # Force update GUI
- if not no_draw:
- app.canvas.draw()
- except RuntimeError:
- messagebox.showwarning(title="Warning", message=f"Decay fitting failed for peak at {current_peak_time}.")
- if not no_draw:
- app.update_table() # Update table
calculate_decay.py at commit bab466e, under MIT · at the source
Overview
- University of Southern California, Department of Neurobiology Los Angeles United States
- USC Neuroscience Graduate Program Los Angeles United States
- Department of Physiology, Tulane University School of Medicine New Orleans United States
Abstract
While genetically encoded Ca2+ indicators are valuable for visualizing neural activity, their speed and sensitivity have had limited performance when compared to chemical dyes and electrophysiology, particularly at synaptic compartments. We addressed these limitations by engineering a suite of next-generation GCaMP8-based indicators, targeted to presynaptic boutons, active zones, and postsynaptic compartments at the Drosophila neuromuscular junction. We first validated these sensors to be superior to previous versions and synthetic dyes. Next, we developed a Python-based analysis program, CaFire, which enables the automated quantification of evoked and spontaneous Ca²+ signals. Using CaFire, we show a ratiometric presynaptic GCaMP8m sensor accurately captures physiologically relevant presynaptic Ca2+ changes with superior sensitivity and similar kinetics compared to chemical dyes. Moreover, we test the ability of an active zone-targeted, ratiometric GCaMP8m sensor to report differences in Ca²+ between release sites. Finally, a newly engineered postsynaptic GCaMP8m, positioned near glutamate receptors, detects quantal events with temporal and signal resolution comparable to electrophysiological recordings. These next-generation indicators and analytical methods demonstrate that GCaMP8 sensors, targeted to synaptic compartments, can now achieve the speed and sensitivity necessary to resolve Ca2+ dynamics at levels previously only attainable with chemical dyes or electrophysiology.
Reproduced under the paper's license (CC BY), from the paper cited above.
Repositories
Its files are read in the Code ↔ Paper reader above, with 1 match between paragraphs and lines of code.
linj7/CaFire
bab466e9d51dd3cbdf982051be7a0bb823a260b5, 25 February 2026Availability: 1 check, the latest on 30 September 2026: the link answers
- 30 September 2026: the link answers
19 files
- app/
CaFire.py , Python, 71 lines - core/
app_state.py , Python, 171 lines - core/
apply_threshold.py , Python, 100 lines - core/
calculate_baseline.py , Python, 26 lines - core/
calculate_decay.py , Python, 130 lines, 1 match - core/
calculate_rise.py , Python, 413 lines - core/
event_handlers.py , Python, 235 lines - main.py, Python, 11 lines
- ui/
dialogs.py , Python, 880 lines - ui/
event_handlers.py , Python, 65 lines - ui/
main_window.py , Python, 482 lines - ui/
widgets.py , Python, 68 lines - ui/
window.py , Python, 78 lines - utils/
file_utils.py , Python, 279 lines - utils/
image_utils.py , Python, 24 lines - utils/
navigation_utils.py , Python, 166 lines - utils/
table_operations_utils.p , Python, 353 linesy - LICENSE, License, 23 lines
- README.md, Text, 102 lines
doi:10.5281/zenodo
Availability: 1 check, the latest on 28 September 2026: the link is dead (HTTP 404)
- 28 September 2026: the link is dead (HTTP 404)
Zenodo 1552996
Availability: 1 check, the latest on 30 September 2026: the link answers (HTTP 200)
- 30 September 2026: the link answers (HTTP 200)
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:
- 3 repositories of the authors' code, each at its verified commit, with its license and how the link was found in the paper;
- 17 scripts, each with its path and the digest of its content;
- 1 match 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 relevant data is included in the publication, primarily in Supplementary file 1. All fly stocks and molecular constructs generated in this study will be shared upon request. We are also in the process of depositing newly generated Scar8f/
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, pages, dates, 10 authors, 7 keywords, 6 MeSH terms, 1 funder, 64 references, 14 RRIDs.
Cite
This paper
Chen, J., Lin, J., He, K., Wang, L., Han, Y., Qiu, C., Wheeler, J. M., Daly, C. M., Macleod, G. T., & Dickman, D. K. (2026). Resolving synaptic events using subsynaptically targeted GCaMP8 variants. eLife, 14, RP107939. https://
BibTeX
@article{chen2026resolvi
author = {Chen, Jiawen and Lin, Junhao and He, Kaikai and Wang, Luyi and Han, Yifu and Qiu, Chengjie and Wheeler, Jasmine M and Daly, Catherine M and Macleod, Gregory T and Dickman, Dion K},
title = {{Resolving synaptic events using subsynaptically targeted GCaMP8 variants}},
journal = {eLife},
year = {2026},
month = mar,
volume = {14},
pages = {RP107939},
publisher = {eLife Sciences Publications, Ltd},
issn = {2050-084X},
doi = {10.7554/
url = {https://
pmid = {41769864},
pmcid = {PMC12952790}
}
RIS
TY - JOUR
AU - Chen, Jiawen
AU - Lin, Junhao
AU - He, Kaikai
AU - Wang, Luyi
AU - Han, Yifu
AU - Qiu, Chengjie
AU - Wheeler, Jasmine M
AU - Daly, Catherine M
AU - Macleod, Gregory T
AU - Dickman, Dion K
TI - Resolving synaptic events using subsynaptically targeted GCaMP8 variants
T2 - eLife
J2 - Elife
PY - 2026
DA - 2026/
VL - 14
SP - RP107939
SN - 2050-084X
PB - eLife Sciences Publications, Ltd
DO - 10.7554/
UR - https://
LA - en
ER -
CSL-JSON
{
"id": "10.7554/
"type": "article-journal",
"title": "Resolving synaptic events using subsynaptically targeted GCaMP8 variants",
"container-title": "eLife",
"author": [
{
"family": "Chen",
"given": "Jiawen"
},
{
"family": "Lin",
"given": "Junhao"
},
{
"family": "He",
"given": "Kaikai"
},
{
"family": "Wang",
"given": "Luyi"
},
{
"family": "Han",
"given": "Yifu"
},
{
"family": "Qiu",
"given": "Chengjie"
},
{
"family": "Wheeler",
"given": "Jasmine M"
},
{
"family": "Daly",
"given": "Catherine M"
},
{
"family": "Macleod",
"given": "Gregory T"
},
{
"family": "Dickman",
"given": "Dion K"
}
],
"container-title-short":
"volume": "14",
"page": "RP107939",
"DOI": "10.7554/
"PMID": "41769864",
"PMCID": "PMC12952790",
"ISSN": "2050-084X",
"publisher": "eLife Sciences Publications, Ltd",
"URL": "https://
"language": "en",
"issued": {
"date-parts": [
[
2026,
3,
2
]
]
}
}
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.1002/advs.202510538 [code]
- Temporal and Cell-Specific Regulation of Synaptic Homeostasis by the Chromatin Remodeler Chd1.Journal: Advanced science (Weinheim, Baden-Wurttemberg, Germany)In common: pandas, SciPy, Matplotlib, 1 other tool, drosophila, cellular / molecular, 8 references, author Chengjie Qiu
- [2] doi:10.1038/s41592-026-03065-2 [code]
- PinkyCaMP: an mScarlet-based calcium sensor with enhanced brightness, photostability and multiplexing capabilities.Journal: Nature methodsIn common: pandas, SciPy, Matplotlib, 1 other tool, optical imaging (calcium, voltage, 2-photon), cellular / molecular, 9 references
- [3] doi:10.1016/j.isci.2026.116099
- Complete muscle denervation triggers compensatory sprouting of a bystander tonic motor neuron in &
lt;i& gt;Drosophila& lt;/ i& gt; larvae. Journal: iScienceIn common: drosophila, cellular / molecular, 7 references - [4] doi:10.1002/advs.202515887 [code]
- An Open-Source Pipeline for Calcium Imaging and All-Optical Physiology in Human Stem Cell-Derived Neurons.Journal: Advanced science (Weinheim, Baden-Wurttemberg, Germany)In common: pandas, SciPy, Matplotlib, 1 other tool, optical imaging (calcium, voltage, 2-photon), 4 references
- [5] doi:10.1111/ejn.70480 [code]
- Astrocyte Proximity Protects Synapses From Human Amyloid-Beta Induced Degeneration in a Mouse Ex Vivo Model of Early Alzheimer's Disease.Journal: The European journal of neuroscienceIn common: pandas, SciPy, Matplotlib, 1 other tool, cellular / molecular, 5 references
- [6] doi:10.1111/ejn.70582 [code]
- Multifiber Array-Based Photometry System for Multiregional Functional Mapping in the Mouse Brain.Journal: The European journal of neuroscienceIn common: Pillow, pandas, SciPy, 2 other tools, optical imaging (calcium, voltage, 2-photon), 3 references
- [7] doi:10.1038/s41467-026-72710-3 [code]
- A modular multi-color fluorescence microscope for simultaneous tracking of cellular activity and behavior.Journal: Nature communicationsIn common: Pillow, pandas, SciPy, 2 other tools, optical imaging (calcium, voltage, 2-photon), drosophila, 2 references
- [8] doi:10.1364/boe.600665 [code]
- NeuroSeg-MF: robust neuron segmentation in two-photon Ca&
lt;sup& gt;2+& lt;/ sup& gt; imaging using multi-feature fusion and detection-guided SAM. Journal: Biomedical optics expressIn common: Pillow, pandas, SciPy, 2 other tools, optical imaging (calcium, voltage, 2-photon), 3 references - [9] doi:10.3389/fnsyn.2026.1832103 [code]
- Automated ROI detection allows rapid quantification of synaptic activity across tens of thousands of synapses in cell culture.Journal: Frontiers in synaptic neuroscienceIn common: Pillow, pandas, SciPy, 2 other tools, optical imaging (calcium, voltage, 2-photon), cellular / molecular, 3 references
- [10] doi:10.1016/j.xpro.2026.104659 [code]
- Protocol for simultaneous in vivo two-photon imaging and locomotion quantification during olfactory stimulation and pharmacology in walking Drosophila.Journal: STAR protocolsIn common: Pillow, pandas, SciPy, 2 other tools, optical imaging (calcium, voltage, 2-photon), drosophila, 2 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.
Claim this paper
Correct its record
Say what each link of this record is, remove the ones that are not the paper's, add the ones that are missing. The correction becomes a new version of the record, in its Versions section.
Validate its tracing map
You validate the map as this page shows it: 3 repositories of the authors' code, each at its verified commit and with its license, 17 scripts, and 1 match between paragraphs and code (see the Code and Map sections). It then receives a DOI on Zenodo, with you (your ORCID iD) and OSCR as its creators; the code itself is not deposited.
The map's fingerprint: sha256:24c799fd90df20da…
Add the badge to its README
The badge links the code to this page. Copy one of these into the README of the paper's code: only you decide where it goes, and nothing is changed for you.
Markdown
[, paste the snippet at the top, then “Commit changes…” and, to review it first, “Create a new branch and start a pull request”. You open the pull request; OSCR asks for no permission.
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: questions and error reports about this paper and its code, from signed-in readers and its authors. It opens with sign-in.
Reproductions: reports from readers who ran the authors' code: what they reproduced, with which environment, commit and data. It opens with sign-in.
Activity: what happens around this paper: new versions of its record, its map's validation, discussions and reproductions. It opens with sign-in.
