In Vitro to In Vivo: Bidirectional and High-Precision Generation of In Vitro and In Vivo Neuronal Spike Data
April 13, 2026
Computational Modeling
Custom Analysis
MaxLab Live
MaxOne
MaxOne Chip
Method Development
Spike Sorting
Masanori Shimono
Download Resource
Back
Access Resource
Abstract
Details
Translational neuroscience relies on both in vitro slice recordings and in vivo recordings. Their spontaneous population dynamics are observed under decisively different conditions, and across independent experiments, there is typically no clear neuron-to-neuron correspondence. Here, we formulate a one-step-ahead, 1 ms binned, bidirectional transfer task between in vitro and in vivo multineuronal spike trains and provide a standardized evaluation procedure for generation across markedly different recording preparations. We train an autoregressive transformer on 1 ms binned, 128-unit binary sequences and introduce Dice loss to directly optimize spike-event overlap under extreme class imbalance, comparing it with Binary Focal Cross-Entropy (γ = 2.0). Across 12 mouse datasets (6 in vitro HD-MEA sessions and 6 in vivo Neuropixels sessions), the method achieves strong within-domain performance and remains above chance for cross-domain generation (ROC-AUC 0.70 ± 0.09 for in vitro → in vivo; 0.80 ± 0.10 for in vivo → in vitro). Because spike events are rare, we report Precision–Recall curves and PR-AUC alongside ROC-AUC to reflect minority-event quality. The present results should be interpreted as predictive generation under preparation/domain shift rather than as direct evidence of preserved causal biological dynamics; whether the framework also reflects features such as E/I balance or oscillatory structure remains an important question for future validation. To our knowledge, this is the first demonstration of bidirectional, time-resolved generation between unpaired in vitro and in vivo population spike trains without assuming cell correspondence, and the framework can be adapted to other sparse neural event data and related event-based datasets when domain-specific validation criteria are defined.