dataesr/scientific-paragraphs-categorization huggingface dataset:
For instance, in some human recordings featuring large natural heartbeat-and breathing-induced motion which is fast relative to the timescale at which AP motion tracking is stable, which is typically around 1Hz due to the sparsity of spiking activity, motion tracking in the AP band can be unreliable or impossible, corresponding visually to a lack of structure in the spike raster plot (Fig. 2. c, i). However, we found that motion tracking in the spatiotemporally smooth LFP band was consistently reliable in such datasets, even when performing nonrigid registration at high temporal resolution (250Hz). In Fig. 2. c, we focused on a human Neuropixels 1 recording made with a long two-column channel configuration  16  , featuring thousands of microns of drift across the entire recording made up of fast motion oscillations of approximately 500µm around a long-term drift which extended over approximately 1mm.
LFP-based nonrigid motion estimation visually appeared to track fast moving features present not only in the LFP band but also in scatter plots of spike positions (Fig. 2. c, i, detail plots). When visualizing the positions of spikes after correction using the nonrigid LFP-based motion estimate in scatter plots versus time (Fig. 2. c, ii) and spike amplitude (Fig. 2. c, iii), isolated clusters of these spike positions became apparent. Waveforms extracted from the detected events leading to the spikes visualized in these scatter plots had well-stereotyped shapes Fig. 2. c, iv), indicating that the LFP-based motion estimate was able to stabilize the positions of single units, validating the utility of cross-band registration in the estimation of extensive and fast drift in a dataset which would be challenging or impossible to process based on AP data alone.
Tracking long-range drift during probe insertion in non-human primates. A key advantage of the decentralized motion estimation framework is its ability to tolerate large nonstationarities in its input data, so that it does not require the same population of neurons to be present throughout an entire recording session. We thus hypothesized that DREDge would be able to track long-range drift surpassing the length of the probe, which would enable users to map the neural population recorded around the probe as it advances into the brain, in a manner similar to the previous tetrode study of  Mechler et al. 37. To test this hypothesis, we implemented DREDge on long insertion datasets (N = 2, Fig. 4  and Supp. Fig. 11 ) recorded from rhesus macaque using Neuropixels 1. 0-NHP probes  33. The probe was inserted from the motor cortex targeting globus pallidus internus (GPi) in the basal ganglia using a commercial drive system (Fig.
6;34. DREDge's motion traces (left column, blue) and motion-corrected spike rasters (middle column) match the quality of Kilosort's (left column, red; right column) on NP1 and NP2 data (i, ii). Unlike Kilosort (KS), DREDge also performs well when applied to the short and dense layout of the NP Ultra probe (iii). b In n = 47 datasets from the International Brain Lab's repeated site experiment  32  , DREDge reliably outperforms KS on nonrigid spike-based registration according to a simple metric of registration quality (see Section 4. 9). We computed this stability metric on unregistered, KS-registered, and DREDge-registered spike positions; here, the vertical position of a dot in the scatter shows the metric value after DREDge's correction, and the horizontal position shows either the unregistered metric value (gray) or the value after KS' correction (orange).
c,d In n = 12 Neuropixels Ultra recordings with both natural and imposed zig-zag motion, DREDge reliably performs well relative to no correction and KS, leading to improvements in two metrics of stability. In c, we apply the metric study described in b to these NP Ultra datasets; colors and axes have the same meanings. In d, we plot the number of implausibly large jumps (motion estimation time bins with > 10µm/s drift; see also Section 4. 9) which appear in DREDge's and KS' motion estimates; note that these large jumps are much more frequent in the KS output. Further visualizations of DREDge's improvements in these NP Ultra recordings appear in Supp. Figs. 15  and 16. Estimating motion in acute mouse recordings. Thus far, Neuropixels recordings have been made most frequently in mice. Since the mouse brain is much smaller than the primate brain, and since recordings made in mice may leverage experimental techniques such as head fixing which cannot be applied for instance in the human recordings discussed above, these recordings typically feature less extensive drift.
Thus we were motivated to interrogate the extent to which DREDge could improve over Kilosort in mouse recordings. We began by comparing DREDge's nonrigid spike-based motion estimation to that of KS on Neuropixels 1 and 2 datasets in which relatively small (⇠50µm amplitude) vertical zig-zag probe was imposed via a micromanipulator (see Methods) where KS had previously been shown to perform well  6. In these recordings, DREDge recapitulated the performance of KS (Fig. 5. a, i and ii). We compared DREDge to KS qualitatively in these datasets both by plotting the algorithms' estimated nonrigid motion traces over a raster plot of spike positions over time (left), and by making raster plots of spike "registered positions" over time (i. e. , positions offset inversely to the estimated motion; right, middle).
In both NP1 and NP2, these algorithms' estimated motion traces are similar and appear to qualitatively track the motion visible in the unregistered spike rasters, leading to well-stabilized registered raster plots. Still, in qualitatively similar recordings with natural drift of a similar magnitude made by the International Brain Lab, DREDge reliably yielded improvements over KS. KS had already been employed by the International Brain Lab (IBL) in its motion estimation and spike sorting pipeline  20. To perform a large scale comparison between DREDge and IBL's application of KS on these datasets, we designed a metric of registration quality: taking inspiration from KS' internal template heuristic, we computed the mean correlation of all time bins of each recording's spike raster (before or after registration by KS or DREDge) with the raster's temporal mean (see Section 4.
This probe features a much smaller recording area than those of Neuropixels 1 or 2 (a vertical extent of 282µm when recording a dense channel neighborhood near the tip, versus 2880µm for NP2 and 3840µm for NP1 in their dense layouts), with the same number of recording channels in a much denser layout (6 columns of 48 electrodes with 6µm vertical and horizontal spacing). In this case, the raster plot of DREDge's registered spike position revealed stably localized spikes from individual neuronal sources in a recording featuring both artificially imposed and other motion which were both substantial relative to the size of the recording area (Fig. 5. a, iii). When applying DREDge and KS to n = 12 similar NP Ultra datasets, we repeatedly observed such improvements (Fig. 5. c,d). Since these datasets featured motion which was much larger relative to the recording area than in the IBL datasets, accurate motion estimation will have a larger impact on the recording.
Indeed, as visualized in the left panel of Fig. 5. c, applying the template correlation metric analysis used above in the IBL Neuropixels study showed that DREDge led to larger improvements than we had observed in the IBL experiment. In the NP Ultra data, DREDge's mean difference relative to no registration was 0. 1 and relative to KS was 0. 06; these values were both significantly different from 0 (two-sided paired t-test p < 0. 01 in both cases). To validate the application of this metric as a measure of registration quality in these datasets, we also visualized the raw and motion-corrected spiking activity in 7 of these recordings in Supp. Fig. 15. We also plotted the frame-by-frame correlation to the template in all 12 recordings in Supp. Fig. 16. Further, we observed that DREDge tended to produce motion estimates with fewer physically implausible jump artifacts than KS on these datasets.
5. a to fit inside the 282µm span of the NP Ultra probe; we found similar improvements in DREDge's tracking relative to KS in this setting (Supp. Fig. 17 ). Together, these experiments increased our confidence in DREDge's improvement in performance relative to KS in NP Ultra data and in general as the amplitude of motion increases relative to the length of the recorded area. and two chronic NP1 implantations. DREDge is on par with or better than KS according to a simple metric of inter-session correlation (left; see Section 4. 9; here we show the template correlation's mean and standard error over sessions in each recording), and both methods improve on no registration. Further, according to a simple metric which counts non-physical jump artifacts (Section 4. 9), the DREDge motion estimate is substantially more stable across this collection of chronic datasets (right); here, each dot shows the number of jumps in a single session, and each dataset contains many sessions.
Plots including the horizontal spike positions used to select spikes for these clusters appear in Supp. Fig. 18. We found that waveforms extracted on the maximum-amplitude channel at times corresponding to each of these spikes corresponded to well-stereotyped waveform shapes (Fig. 6. d), suggesting that the spikes did come from drifting single units, each of which were present across several sessions of the chronic recording; this provided evidence that, in this case, DREDge was tracking the probe trajectory more accurately than KS while also improving the stability of the motion estimate. To test whether such improvements were repeatable, we computed metrics of DREDge's performance against Kilosort's on all 10 datasets. As in the previous section, we began by studying the mean template correlation metric (see Section 4.
Discussion We have presented DREDge, a robust decentralized registration algorithm for both spiking and local field potential extracellular electrophysiology data recorded via dense multi-electrode probes. We approaches, especially when generalizing to new probe types. Finally, we were able to track motion across days and months in chronic recordings in mice. DREDge's code is fully open-source, and its modular implementation makes it easy to integrate into existing pipelines. It is already possible to integrate DREDge into current state-of-the-art spike sorting pipelines, such as Kilosort  27  , by using its motion estimate to drive motion-correction interpolation of the AP band as a preprocessing step via the SpikeInterface framework  19. Further, DREDge is being integrated into new spike sorting pipelines which use a drift estimate to make their core routines drift-aware rather than relying on interpolation to correct for motion before sorting  35.
versity (to EMT). EMT is supported by the Grossman center and the Brain and Behavior Research Foundation. CW, JB, EV, and LP are funded by Simons Foundation 344 543023, NSF Neuronex Award DBI-1707398 and the Gatsby Charitable Foundation. EV is also supported by K99MH128772. The rat brain in vivo data has been recorded within the Hungarian Brain Research Program Grant (NAP2022-I-2/2022). DM is also supported by the OTKA Hungarian postdoctoral grant (PD143582). The views and conclusions contained in this document are those of the authors and do not represent the official policies, either expressed or implied, of the funding sources. The funders had no role in the study design, data collection, analysis, decision to publish, or preparation of the manuscript.
Preprocessing of action potential band data. For input into DREDge, raw electrophysiology data in the action potential band (300-6000Hz) passes through several steps, starting with quality control and filtering, then spike event detection and localization, and finally a rasterization step which leads to a binned spatiotemporal representation of spiking activity. These steps can be thought of as modular components that can be chosen according to user preference so that DREDge's motion estimation step itself becomes another module in a bigger electrophysiology pipeline. In the experiments conducted for this work, the initial filtering, detection, and localization steps were chosen to suit each data source. For the International Brain Lab (IBL) mouse recordings  32  , the IBL's electrophysiology preprocessing pipeline  20  , including highpass filtering, analog-to-digital converter (ADC) offset correction, dead and noisy channel detection, and spatial highpass filtering, was reproduced using modular components available in the SpikeInterface framework  19.
Spike detections and localizations for input into DREDge were computed using the corresponding module from  35  , which relies on the point source model of Boussard et al. 36  to localize the spike events relative to the probe. Kilosort-based motion estimates were collected from IBL's own runs of pyKilosort, a Python port of Kilosort 2. 5  6  , and these motion estimates, in turn, used pyKilosort's detected and localized spike events using raw data preprocessed as for DREDge  20. Once a collection of spike times, amplitudes, and localization features has been collected, DREDge processes these into a rasterized representation. Given spatial and temporal bin sizes h d , h t (typically 1 micron and 1 second, respectively) leading to D bins along the length of the probe and T bins across time, all spikes landing in each spatiotemporal bin are collected.
At UCSF, two 27G subdermal needle electrodes (Ambu, Columbia, MD) were placed in the skin were soldered separately to the probe flex-interconnect to serve as ground and reference using lead-free solder and two strands of twisted 36 AWG copper wire. Data acquisition was performed using open-source acquisition software to record the neural data which include SpikeGLX (http://billkarsh. github. io/SpikeGLX/) and OpenEphys (Siegle et al. 64  , https://open-ephys. org/gui). Since Neuropixels 1 probes enable 384 recording channels to address 960 electrodes across the probe shank, two different acquisition maps were used. At MGH, both one map (short column map) targeting the lower portion of the probe (the most distal channels) and a second map ('long column' map) recording two rows of contacts along the entire length of the electrode were used in different cases.
The data collected at UCSF all included two rows of contacts along the entire length of the electrode. For the sake of timing and correlating task activity with the neural activity, TTL triggers via a parallel port produced either during a task via MATLAB or custom code from a separate computer were sent to both the National Instruments and IMEC recording systems, via a parallel port system. This TTL output sent synchronization triggers via the SMA input to the IMEC PXIe acquisition module card to allow for added synchronizing triggers which were also recorded on an additional breakout analog and digital input/output board (BNC-2110, National Instruments) connected via a PXIe board (PXIe-6341 module, National Instruments)  15. For the simple visual task, stimuli were presented on an LCD computer monitor (58×30 cm, ASUS) placed in front of the participant and with the use of the Psychophysics toolbox  65.
Acknowledgements We would like to thank  Yangling Chou ,  Daniel Soper ,  Aaron Tripp ,  Fausto Minidio ,  Alex Zhang ,  Alexandra O'Donnell , and  Michael Okun  for their help in data collection. We would like to especially thank the patients for their willingness to participate in this research. We thank  Matteo Carandini ,  Jennifer Colonell ,  Olivier Winter ,  Andrew Zimnik , and the  International Brain Lab  for helpful discussions and data coordination. We thank  Alessio Buccino ,  Gaelle Chapuis ,  Margot Elmaleh ,  Samuel Garcia ,  Pierre Yger , and also the  Simons Collaboration  on the  Global Brain Spike Sorting Working group  for many useful discussions. This research was supported by the  ECOR  and  K24-NS088568  (to SSC) and the  Tiny Blue Dot Foundation  (to SSC and ACP) and  NIH  grant  U01NS121616  (to ZMW).
Data availability com/Center-For-Neurotechnology/CorticalNeuropixelProcessingPipeline). The burst suppression ratio (BSR) was computed using an automated method (https://github. com/drasros/bs_ detector_icueeg). Psychtoolbox-3 (http://psychtoolbox. org/) with io64 parallel port drivers and MATLAB functions were used to drive TTL trigger pulses for alignment as well as run the visual task.
f Left: Relative variance averaged across 10 seconds of baseline activity per participant (different color dot lines and asterisks are different participants). Asterisks, p < 0. 00001; pairwise Wilcoxon rank sum tests per participant. Right: Relative variance averaged across channels during baseline activity per participant (averaged across time, different color dot lines and asterisks are different participants). Asterisks, p < 0. 00001; pairwise Wilcoxon rank sum tests per participant. g Common median LFP (across channels) of detected interictal epileptiform discharges (IIDs) before and after motion-correction interpolation, recorded in a patient with intractable epilepsy during an open craniotomy to remove epileptogenic tissue. h Spontaneous LFP per channel shown as a colormap and with a zoomed-in voltage trace of the same data for a detected IID before and after motion-corrected interpolation, showing that the IID survives the processing.
c,d In n = 12 Neuropixels Ultra recordings with both natural and imposed zig-zag motion, DREDge reliably performs well relative to no correction and KS, leading to improvements in two metrics of stability. In c, we apply the metric study described in b to these NP Ultra datasets; colors and axes have the same meanings. In d, we plot the number of implausibly large jumps (motion estimation time bins with > 10µm/s drift; see also Section 4. 9) which appear in DREDge's and KS' motion estimates; note that these large jumps are much more frequent in the KS output. Further visualizations of DREDge's improvements in these NP Ultra recordings appear in Supp. Figs. 15 and 16.
d Waveforms extracted on the detection channels for spikes in each cluster reveal well-stereotyped shapes, validating the motion estimate. e Comparisons to KS in two chronic NP2. 4 implantations (separated into 4 shanks each) and two chronic NP1 implantations. DREDge is on par with or better than KS according to a simple metric of inter-session correlation (left; see Section 4. 9; here we show the template correlation's mean and standard error over sessions in each recording), and both methods improve on no registration. Further, according to a simple metric which counts non-physical jump artifacts (Section 4. 9), the DREDge motion estimate is substantially more stable across this collection of chronic datasets (right); here, each dot shows the number of jumps in a single session, and each dataset contains many sessions.
5's Matlab code (available at https://github. com/ MouseLand/Kilosort/tree/v2. 5/). Kilosort 2. 5 exposes one parameter to control the registration, nBlocks, which controls the number of nonrigid blocks (rectangular windows rather than Gaussian profiles); the number of blocks used is 2•nBlocks 1 (see line 58 of align block2. m). When constructing its three-dimensional spike histogram, Kilosort uses a spatial bin size of 5µm and a temporal bin size controlled by the algorithm's global batch size (expressed in samples), which leads to approximately 2. 18s temporal bins in data sampled at 30kHz, although this will vary with the sampling rate; we did not find improvements in some exploratory experiments when tuning the spatial bin size and did not attempt to adjust the temporal bin size. The most important parameters which we adjusted in our experiments were Kilosort 2.
5's two search radius parameters (like our max disp um above), defaults are well suited to data with fairly small drift dominated by a rigid component, we found it essential to adjust them in recordings with larger drift or nonrigid drift whose overall amplitude was larger than 25µm. Our Kilosort 2. 5 fork with modifications to expose these parameters is available at https://github. com/cwindolf/Kilosort/tree/modded-v2. 5.
Each cell was coupled through a light guide of 31 mm thickness to either a R4144 or R11833 PMT from Hamamatsu. For this experiment, 48 cells arranged in two different setups, with 30 and 18 cells at 2 and 1. 5 m flight paths, respectively, were used. The signals from the β-detector and MONSTER were used as the start and stop signals, respectively, to measure the neutrons' time-of-flight (TOF). A picture of the whole ensemble can be seen in Figure  1. All the detector signals were registered with a custom digital DAQ system developed at CIEMAT based on ADQ14DC digitizers from Teledyne SP Devices with 14 bits vertical resolution, 1 GSample/s sampling rate, and 4 channels  [5]. The complete setup required 60 channels. The system integrates custom pulse shape analysis software also developed at CIEMAT to analyze the registered signals online.
The used pulse shape analysis routines did not add any dead time to the measurement. The data was collected in cycles of implantation and decay adapted to the half-lives of the isotopes involved for maximizing the activity of the neutron emitters with respect to the other implanted isobars. During the cycle, the ion beam was switched on and off by electrostatic deflection at the switchyard of the IGISOL beam line. The cycle also included an initial time interval for background measurement and a final time interval for removal of the long-lived activity of the decay products.
The aim of this paper is to extend the method of García-Cortés et al. [1]  to (i) partition the genetic mean and variance, (ii) implement the method in AlphaPart R package, and (iii) apply the partitioning method to estimated breeding values following the work of  [6]  and  [7]. We used simulation to demonstrate the methodology and provide insights on how to use the AlphaPart R package  [10]  to analyse real data.
) to genetic mean over time: µ a t with t = 1, 2,. , m. Technically this is achieved by sub-setting the a 1 , a 2 ,. , a p and averaging each subset to obtain µ a j t where p j=1 µ a j t = µ a t. This method has been implemented in the AlphaPart R package  [10, 15]. The AlphaPart R package efficiently calculates the partitions by leveraging the sparse T -1  [11] [12] [13] [14] , and enables a straightforward summary by one variable, such as year, or combination of variables (interaction), such as year and sex. We refer to this variable as x * t , with t = 1, 2,. , m , and m representing the number of distinct categories. Importantly, AlphaPart enables the use of any function to summarise the partitions of breeding values, i. e. , f a j. To enable the use of variance as one of the summary functions in AlphaPart, we extend the partitioning method to analyse the contribution of paths to genetic variance.
AlphaPart implementation The partitioning method is implemented in the Alp-haPart R package  [10, 18]. The main input for the analysis is a data frame (data) with: • pedigree information for individual (id), sire  (Fid)  and dam (Mid); • partition variable (path)-colPath; • breeding values for one or multiple traits-colBV; • grouping variable ( x * t ) used to compute the conditional expectations such as generation, birth year, location, etc. We partition the breeding values (BV) by paths using: We summarise the partitions using the grouping variable (time) using: where object is an object of class AlphaPart with breeding value partitions, by represents the column by which summary function FUN is applied. For this work, we included an extra argument cov that controls how the covariances are displayed in the output.