Binding events through the mutual synchronization of spintronic nano-neurons

The brain naturally binds events from different sources in unique concepts. It is hypothesized that this process occurs through the transient mutual synchronization of neurons located in different regions of the brain when the stimulus is presented. This mechanism of ‘binding through synchronization’ can be directly implemented in neural networks composed of coupled oscillators. To do so, the oscillators must be able to mutually synchronize for the range of inputs corresponding to a single class, and otherwise remain desynchronized. Here we show that the outstanding ability of spintronic nano-oscillators to mutually synchronize and the possibility to precisely control the occurrence of mutual synchronization by tuning the oscillator frequencies over wide ranges allows pattern recognition. We demonstrate experimentally on a simple task that three spintronic nano-oscillators can bind consecutive events and thus recognize and distinguish temporal sequences. This work is a step forward in the construction of neural networks that exploit the non-linear dynamic properties of their components to perform brain-inspired computations.

The brain naturally binds events from different sources in unique concepts.It is hypothesized that this process occurs through the transient mutual synchronization of neurons located in different regions of the brain when the stimulus is presented [1][2][3][4] .This mechanism of 'binding through synchronization' can be directly implemented in neural networks composed of coupled oscillators 5 .
To do so, the oscillators must be able to mutually synchronize for the range of inputs corresponding to a single class, and otherwise remain desynchronized.Here we show that the outstanding ability of spintronic nano-oscillators to mutually synchronize [6][7][8][9] and the possibility to precisely control the occurrence of mutual synchronization by tuning the oscillator frequencies over wide ranges allows pattern recognition.We demonstrate experimentally on a simple task that three spintronic nanooscillators can bind consecutive events and thus recognize and distinguish temporal sequences.This work is a step forward in the construction of neural networks that exploit the non-linear dynamic properties of their components to perform brain-inspired computations.
Spintronic oscillators are nanoscale devices called magnetic tunnel junctions which have the potential to be integrated by hundreds of millions in electronic chips 10 .The microwave voltages that they produce have varying amplitude and frequency in response to direct current inputs.Their non-linear dynamical properties are rich and tunable, and can be leveraged to imitate different features of biological neurons, which makes them particularly promising for neuromorphic computing [11][12][13][14][15] .The transient dynamics of a single spintronic nano-oscillator has been used to implement reservoir computing, achieving state-of-the-art results on a simple spoken digit recognition task 16,17 .Four spintronic nano-oscillators have been trained to classify spoken vowels by phase locking their oscillations to the strong input signals produced by external microwave sources 18 .
It is now essential to demonstrate that the mutual synchronization of spintronic nano-oscillators can be exploited for computing.Larger hardware networks of oscillators can be built if the oscillators directly influence each other and synchronize through the weak signals that they emit, without the need of high power-consumption amplification stages.The latter is possible with spin-torque nanooscillators due to their outstanding synchronization ranges, enhanced by factors of typically ten compared to Kuramoto model-like phase oscillators due to the coupling between their amplitude and phase [6][7][8][9][19][20][21] . In addtion, more complex tasks can be achieved by exploiting the rich interactions that emerge in assemblies of mutually coupled oscillators rather than using phase-locking to external signals 22,23 .
A primary source of inspiration to move in this direction is neuroscience, which shows that in the brain, vast groups of neurons mutually synchronize in response to external or internal stimuli, giving rise to strong oscillatory signals [1][2][3] .This process is often hypothesized to enable spatiotemporal integration of stimuli, a mechanism called 'binding through synchrony' 4 .It can be used for pattern recognition in oscillatory neural networks if mutual synchronization can be controlled and tuned to achieve the desired task 5 .
In this work we show that spintronic nano-oscillators can recognize temporal patterns through their mutual synchronization by binding together consecutive events in time.We implement a hardware neural network based on these principles with three spintronic nano-oscillators.We demonstrate that it recognizes sequences of spikes from a neuroscience-inspired database with a success rate of 94%, approaching the success rate of 96% achieved by identical and noiseless oscillators.We show that these high recognition rates stem from the possibility to precisely control the mutual synchronization of spintronic nano-oscillators by varying their frequency over large direct current input ranges.
Our experiment exploits the coupling that occurs naturally when hardware spintronic nano-oscillators are electrically connected to synchronize them with each other 9 .The set-up is shown in Fig. 1a (details on samples and set-up are given in Methods).An important feature of these nano-oscillators is that their frequency can be individually and easily controlled by varying the direct current through each oscillator.When their frequencies are well separated, the three oscillators emit microwave signals independently, and the spectrum analyzer at the output of the set-up displays three peaks (Fig. 1b).
The propagation of these microwave emissions in the line creates a coupling between the connected oscillators 9 .When the frequencies of the oscillators are brought closer together, within the mutual locking range -here of 5 MHz -, they synchronize, which results in the single peak of Fig. 1c.Its power is significantly higher than the sum of the individual emitted powers of the three disconnected oscillators measured with the same bias conditions (Extended Data Fig. 1 and 2).This distinctive feature is due to the phase coherence between oscillators characteristic of the synchronized state (see Methods) 19,20 .(e, f) Sequence example of neuron spikes in the mouse brain in presence of a piece of Cheshire (e) and Cheddar (f) respectively.(g) Inputs applied to the network, represented as the time of spikes for neuron 2 and 3.The spike of neuron 1 is set as origin of the sequence and taken as zero.Each color corresponds to a different cheese category, and each data point corresponds to a different piece of cheese.(h, i) Ramps of current generated in the network upon application of the input spike sequences described in (e) and (f), corresponding to the presentation to the mouse of a piece of Cheshire and Cheddar respectively, when the network is trained to recognize Cheddar.
We leverage this mutual synchronization phenomenon to recognize temporal sequences with a hardware neural network of three spintronic oscillators.We consider a fictitious task, in which a mouse is presented with four different categories of cheese (Fig. 1d).Each kind of cheese generates different neuron activities in the mouse brain.The temporal sequences to be classified are composed of three spikes, each recorded from three different neurons of the fictitious mouse brain.Fig. 1e and Fig. 1f illustrate sequences of spikes when the mouse is in presence of Cheshire and Cheddar cheese.By convention, the time of the first spike is taken as zero and the times of spikes for neurons 2 and 3 are shown in Fig. 1g for the whole database.The different colors correspond to different categories of cheese.Ten different samples of cheese per category are presented to the mouse, giving rise to the variability within each category.The goal of the task is to infer which type of cheese is presented to the mouse by analyzing the recorded sequence of spikes.
For this purpose, we use a mechanism initially proposed by Hopfield et al. to bind temporal features through neural synchronization 4 .A network is composed of as many neurons as there are spikes in the input sequence, and is trained to recognize a single category of input.Our dataset features three spikes, therefore we use three spintronic oscillators tuned to recognize a given kind of cheese, e.g.Cheddar.Each spike triggers a current ramp in the associated neuron.Fig. 1h is a schematic illustrating the behavior of the network activated by a spike sequence that it has not been designed to recognize, e.g.Cheshire cheese.In that case, the ramps do not intersect at any time.On the contrary when the oscillator network is activated with the spike sequence for Cheddar cheese that it has been designed to recognize, the different ramps intersect at a specific time, as illustrated in Fig. 1i.The neurons therefore transiently mutually synchronize and give rise to a large output signal as in Fig. 1c signaling that they have bonded the events together and identified the sequence as meaningful.
In this framework, training the network means finding parameters for the ramps leading to mutual synchronization of the three oscillators for all the points of the database corresponding to the Cheddar category, even if the corresponding spike times are scattered in time.Experimentally, we use the center of the 'Cheddar' data points cloud, pinpointed with an orange cross in Fig. 1g, as a target to calibrate the network, and we convert the arbitrary units of Fig. 1g to seconds.The ramps of current in oscillator 2 and oscillator 3 are therefore triggered with delays of 412 s and 308 s respectively for this calibration point.We choose the oscillators initial frequencies and the slope of the ramps of applied currents in such a way that the application of this sequence of spikes eventually leads to a set of currents ISynch = (6.8mA, 6.2 mA, 6 mA) for which the oscillators synchronize (details on the calibration procedure are given in Methods).Once this calibration is done, when a new input is presented to the network, the selected initial current conditions (Iosc1 0 , Iosc2 0 , Iosc3 0 ) = (4.9mA, 7.51 mA, 5.15 mA) and the slopes of the ramps of current (dIosc1/dt, dIosc2/dt, dIosc3/dt) = (2.5 A/s, -3.75A/s, 1.875A/s) are maintained.This translates into an enhancement of the network total emitted power above the threshold shown in red dotted line (a-b, bottom) meaning recognition.If a different cheese is presented (c-e), the ramps of current do not give rise to the mutual synchronization of the three oscillators and the total emitted power remain well below the threshold (c-e, bottom), meaning that the network distinguishes that the cheese presented is not Cheddar.Fig. 2a shows the measured oscillator responses to the sequence 'Cheddar 1' = (400 s, 294 s), which is the first entry in the class 'Cheddar'.The corresponding trained ramps of currents are triggered at t1 = 0, t2 = 400 s and t3 = 294 s in oscillator 1, 2 and 3 respectively.The three large dots in the top panel of Fig. 2 highlight the set of currents Isynch that we have used to calibrate the network, at which the oscillators synchronize.As can be seen in Fig. 2a, after ~760 seconds the direct currents flowing through the oscillators reach values approaching Isynch.At this point, the frequencies of all three oscillators become near-identical (Fig. 2a-middle) and the total emitted power peaks at Pmax = 0.743 µW.To know if the oscillators have recognized the category Cheddar, we need to assess if they have transiently synchronized or not.For this purpose, we can compare Pmax(I) to the sum of the powers of the three independent oscillators for the same current conditions Punsync(I), equal to 0.43 µW at this particular point.Here Pmax is much larger than Punsync, which shows that the oscillators have mutually synchronized and successfully recognized that the piece of cheese belongs to the Cheddar category.
The value of Punsync varies strongly with the currents I applied to the oscillators which makes it difficult to use it as a general criterion to detect synchronization for all sets of currents in the experiment.In the following we consider that the network recognizes the input pattern if the total emitted power reaches a fixed threshold value of 0.608 µW, independent of the current values (dotted red line in the bottom panel of Fig. 2) and if the frequencies of the three oscillators at that point are all equal (see Methods).Fig. 2b shows the network response to another input from the Cheddar class.For this sequence 'Cheddar2' = (392 s, 315 s), the triggered ramps of current never reach Isynch, but they get close to this value around t = 744 s, where a mutual synchronization event is observed, with the emission of a single peak accompanied with a large increase of the emitted power above the threshold.This input is therefore correctly classified as belonging to the category 'Cheddar'.This example illustrates well the interest of using mutual synchronization to categorize spread data: synchronization occurs when oscillators frequencies are close, but they do not need to be exactly identical (as in Extended Data Fig. 1).
In contrast, Fig. 2c-e show the network response to inputs of the other cheese categories, which characteristic time sequences never lead to sets of currents close to Isynch.In consequence, the three oscillators do not synchronize and the power emitted by the network remains well below the recognition threshold.In these three cases (Fig. 2c-e) the network interprets correctly that the applied input does not correspond to the class 'Cheddar'.
Table 1 shows the overall classification performances of the network.As can be seen in row 1, the network classifies correctly 9 out of 10 inputs corresponding to the class 'Cheddar'.Moreover, when inputs from other categories ('Cheshire', 'Brie', and 'Stilton') are applied to the system, the network correctly interprets that the input is not a piece of 'Cheddar'.The overall success rate for this category is 97.5%.Table 1: Recognition rates.Number of recognitions out of 10 presented samples of each cheese, when the network is trained to classify Cheddar, Brie, Cheshire and Stilton respectively.The last column refers to the percentage of times that the network responds correctly, either because it detects that the input belongs to the category it was trained to recognize or because it interprets correctly that the inputs corresponds to another cheese category.
The same three oscillators can also be trained to recognize the other categories of cheese.For this we modify the initial conditions of the network (the initial currents flowing through each oscillator Iosci 0 , and the slopes of the ramps of current triggered when an input is applied, dIosci/dt) in such a way that the oscillator currents reach Isynch only when the desired category of input is applied to the system (see Methods).Using these new calibration parameters, we repeat the recognition experiment by applying the same dataset as previously.The results are shown in Table 1: the network recognition rate for 'Brie', 'Cheshire' and 'Stilton' is respectively 92.5, 92.5 and 95%.Overall, the network responds correctly to 94% of the inputs.By comparison, a simulated network of three identical, noiseless oscillators gives a recognition rate of 96% on the same database (see Methods).
The excellent performance of this simple network comes from the match between the requirements of the algorithm and the physical properties of spintronic nano-oscillators.Here the inputs are sequences of events that are largely spread in time and need to be bonded to constitute a single concept.The algorithm does this task in two steps.First, it converts the spread timing of events in the sequence to close-by neuron frequencies by ramping the values of frequencies over wide ranges.The high frequency tunability of spintronic nano-oscillators 24 provides a straightforward hardware implementation of this property.Second the algorithm leverages neuron synchronization to bind these neighboring frequencies into a single concept, here, a cheese category.This synchronization range must be large enough to ensure that events are bonded even if different sequences encoding the same category of cheese are scattered in time.The large synchronization bandwidths accessible to spintronic nano-oscillators 6 reduce the precision requirements on the frequency, and therefore on the direct current steps, needed to achieve ramp convergence.
Complementary Metal Oxide Semiconductor (CMOS) technology-based voltage-controlled oscillators such as ring oscillators can also exhibit such characteristics, but large-area decoupling capacitors are needed to control their synchronization, and digital to analog converters to read their outputs 25 .The total silicon area occupied by a single oscillator is larger than 3x3 µm 2 , 26 whereas spin-torque nanooscillators can be scaled below 100x100 nm 2 .Using small-area oscillators is imperative, as moving beyond toy tasks will require scaling up the system.Our simple network processes inputs composed of three events, but more complex inputs will be based on a larger number of events and will require more oscillators.The original paper of Hopfield uses 40 neurons for recognizing the first ten spoken digits 4 .It has been shown recently that such large numbers of spintronic nano-oscillators can mutually synchronize, by driving them with spin-Hall torques and coupling them strongly through ferromagnetic exchange 27 .Important for scaling to even larger dimensions, the algorithm is very tolerant to device variability: as long as the oscillators synchronize over large bandwidths, current ramps can be found for every input though training 4 .Recognition can potentially be achieved in just a few tens of nanoseconds, as spintronic nano-oscillators can be tuned and synchronized within these timescales 28,29 .Finally, when the oscillators synchronize, they generate an additional direct voltage through an effect called spin-diode, that can be detected and then processed with simple and energy efficient CMOS circuits 18 .This work therefore constitutes a milestone towards the implementation of large scale oscillatory neural networks using the physical properties of spintronic nano-oscillators to compute.

Simulations with ideal oscillators
The pattern recognition scheme of the experiment was simulated with a network of three identical noiseless oscillators, using the database of Fig. 1g.The only parameter that differs from one simulated oscillator i from the other one is its applied direct current   .The simulated oscillators correspond to vortex-based spin-torque oscillators as in the experiment.Their dynamics follows the differential Extended data Figure 4. Parameters used to simulate oscillators through the Thiele equation.
A fourth order Runge-Kutta scheme is used to solve simultaneously the three coupled differential Thiele equations corresponding to the three coupled oscillators.The integration time step was set to 0.01 ns.Simulations are achieved at T = 0 K (no thermal noise).As in the experiment, the simulated oscillators are electrically coupled through the sum of their individual microwave alternative current emissions.The expression of these common current    is described as follows 18 : Here Δ  is the mean resistance variation caused by the vortex core gyrotropic motion,   is the direct current flowing through the i-th oscillator,   is its mean electrical resistance,  0 = 50 Ω is the load impedance and  = 2 3 . The main variables extracted from the simulations are the three steady state frequency (f1, f2, f3) of the three oscillators obtained at a given set of direct currents (I1, I2, I3).As in the experiment, a given direct current set (I1, I2, I3) corresponds to a step of the current ramp of the network.In order to extract (f1, f2, f3) from the simulations, first the instantaneous frequency of each oscillator is determined through the simulated cartesian trajectory and velocity of the vortex core over 5 µs.Then, the steady state frequency is computed by evaluating the temporal average of the instantaneous frequency over only the last 60% of the simulated time trace corresponding to 3 µs.Due to the electrical coupling, these steady-state frequencies differ from those obtained in the individual uncoupled case.Depending on the direct current received by each oscillator, their frequencies are pulled and can eventually merge leading to a mutual synchronization.As in experiments, a recognition event corresponds to a mutual synchronization of all the three oscillators to a common frequency.In order to systematically detect this type of events in simulations, we analyze the frequency difference between the three oscillators as follows: Here  ℎ is a threshold value set to 0.1 MHz.Following criteria a) and b), if the three oscillators remain mutually synchronized for at least three consecutive direct current ramp steps corresponding to at least 13 µs, then the simulated network is considered to be in a recognition state.The initial value I 0 and slope value dI/dt of the direct current ramps in simulations are calibrated following the method described in the section "Trained initial conditions to classify each category of cheese / Calibration parameters".Extended data Figure 5 shows the trained calibration parameters used for each input that the network is trained to classify.Following the same procedure used in experiments, the simulated recognition performances are evaluated for each class of cheese using the associated initial conditions (Extended data Figure 5).The recognition rates obtained through this procedure are shown in Extended data Figure 6.Overall, the network responds correctly to 96% of the inputs.

Figure 1 :
Figure 1: Binding temporal sequences through synchrony.(a) Schematic of the experimental set-up with three spin torque nano-oscillators electrically connected in series and coupled through the microwave currents they emit.(b, c) Microwave output emitted by the network of three coupled oscillators when they are not (b) and when they are (c) synchronized.(d) Schematic of the fictitious mouse to which four different categories of cheese are presented.Each category generates different activities in the three neurons of the mouse brain.(e, f) Sequence example of neuron spikes in the mouse brain in presence of a piece of Cheshire (e) and Cheddar (f) respectively.(g) Inputs applied to the network, represented as the time of spikes for neuron 2 and 3.The spike of neuron 1 is set as origin of the sequence and taken as zero.Each color corresponds to a different cheese category, and each data point corresponds to a different piece of cheese.(h, i) Ramps of current generated in the network upon application of the input spike sequences described in (e) and (f), corresponding to the presentation to the mouse of a piece of Cheshire and Cheddar respectively, when the network is trained to recognize Cheddar.

Fig 2 .
Fig 2. Three hardware spintronic nano-oscillators recognize cheddar.Response of the oscillator network trained to recognize Cheddar to spikes sequences generated in the mouse brain when a piece of Cheddar (a,b) or a different cheese (c-e) is presented.The spike sequences generate ramps of currents (top) which translate into variations of the oscillators frequencies (middle) and the network total emitted power (bottom).If a piece of Cheddar is presented (a,b), the ramps of current and their associated variations of frequencies lead to transient mutual synchronization of the three oscillators.This translates into an enhancement of the network total emitted power above the threshold shown in red dotted line (a-b, bottom) meaning recognition.If a different cheese is presented (c-e), the ramps of current do not give rise to the mutual synchronization of the three oscillators and the total emitted power remain well below the threshold (c-e, bottom), meaning that the network distinguishes that the cheese presented is not Cheddar.
a) If | 1 −  2 | ≤  ℎ and | 2 −  3 | ≤  ℎ then the three oscillators are mutually synchronized b) Otherwise, the three oscillators are considered to be not synchronized all together.

6 .
Recognition rates obtained through the simulated network of coupled oscillators.
18 the gyrovector,   ̂ is the damping,   is the potential energy of the vortex,    is the spin-transfer force, and    is a common microwave current    .This model successfully describes experimental results with spin-torque nano-oscillators and can easily be generalized to nonlinear auto-oscillators as van der Pol oscillators18.The parameters used for the Thiele equation in the simulation are expressed in Extended Data Fig.4.