Binary image classification using collective optical modes of an array of nanolasers

I. INTRODUCTION

Section:

ChooseTop of pageABSTRACTI. INTRODUCTION <<II. MODELIII. BINARY CLASSIFICATIO...IV. RESULTSV. DISCUSSIONVI. CONCLUSIONSREFERENCESPrevious sectionNext sectionPhotonic artificial neural networks (ANNs) are sparking a revolution in artificial intelligence (AI) systems because they have the potential of being much faster and energy efficient than current silicon technology.1–31. P. R. Prucnal, B. J. Shastri, and M. C. Teich, Neuromorphic Photonics (CRC Press, 2017).2. G. Van der Sande, D. Brunner, and M. C. Soriano, “Advances in photonic reservoir computing,” Nanophotonics 6, 561–576 (2017). https://doi.org/10.1515/nanoph-2016-01323. G. Wetzstein, A. Ozcan, S. Gigan, S. Fan, D. Englund, M. Soljačić, C. Denz, D. A. B. Miller, and D. Psaltis, “Inference in artificial intelligence with deep optics and photonics,” Nature 588, 39–47 (2020). https://doi.org/10.1038/s41586-020-2973-6 In these big data days where datacenters consume enormous amounts of power and the increase in computing performance based on the increasing number of transistors is reaching fundamental miniaturization limits (Moore’s law), faster and more energy efficient AI systems are urgently needed.Impressive advances have been made in improving the performance of photonic ANNs, designing hardware that mimics neural synapses, developing efficient training methods, expanding the number of nodes, and integrating them into silicon chips.4–94. X. Lin, Y. Rivenson, N. T. Yardimci, M. Veli, Y. Luo, M. Jarrahi, and A. Ozcan, “All-optical machine learning using diffractive deep neural networks,” Science 361, 1004–1008 (2018). https://doi.org/10.1126/science.aat80845. J. Bueno, S. Maktoobi, L. Froehly, I. Fischer, M. Jacquot, L. Larger, and D. Brunner, “Reinforcement learning in a large-scale photonic recurrent neural network,” Optica 5, 756–760 (2018). https://doi.org/10.1364/optica.5.0007566. T. W. Hughes, M. Minkov, Y. Shi, and S. Fan, “Training of photonic neural networks through in situ backpropagation and gradient measurement,” Optica 5, 864–871 (2018). https://doi.org/10.1364/optica.5.0008647. R. Hamerly, L. Bernstein, A. Sludds, M. Soljačić, and D. Englund, “Large-scale optical neural networks based on photoelectric multiplication,” Phys. Rev. X 9, 021032 (2019). https://doi.org/10.1103/physrevx.9.0210328. J. Feldmann, N. Youngblood, C. D. Wright, H. Bhaskaran, and W. H. P. Pernice, “All-optical spiking neurosynaptic networks with self-learning capabilities,” Nature 569, 208–214 (2019). https://doi.org/10.1038/s41586-019-1157-89. P. Antonik, N. Marsal, D. Brunner, and D. Rontani, “Human action recognition with a large-scale brain-inspired photonic computer,” Nat. Mach. Intell. 1, 530–537 (2019). https://doi.org/10.1038/s42256-019-0110-8 As a recent example, a specialized photonic processor has been demonstrated with a performance that is 2–3 orders of magnitude higher than the equivalent digital electronic processor.1010. M. Miscuglio and V. J. Sorger, “Photonic tensor cores for machine learning,” Appl. Phys. Rev. 7, 031404 (2020). https://doi.org/10.1063/5.0001942 Moreover, a survey of the best-in-class integrated photonic devices has reported that silicon photonics can compete with the best-performing electronic ANNs, reaching sub-pJ per MAC (multiply-accumulate operations) and foreseeing, for sub-wavelength photonics, performances of few fJ/MAC.1111. A. R. Totović, G. Dabos, N. Passalis, A. Tefas, and N. Pleros, “Femtojoule per MAC neuromorphic photonics: An energy and technology roadmap,” IEEE J. Sel. Top. Quantum Electron. 26, 1–15 (2020). https://doi.org/10.1109/jstqe.2020.2975579ANNs require activation functions that, in photonics, typically rely on strongly nonlinear mechanisms, such as optical bistability or saturable absorption.12,1312. Y. Shen, N. C. Harris, S. Skirlo, M. Prabhu, T. Baehr-Jones, M. Hochberg, X. Sun, S. Zhao, H. Larochelle, D. Englund, and M. Soljačić, “Deep learning with coherent nanophotonic circuits,” Nat. Photonics 11, 441–446 (2017). https://doi.org/10.1038/nphoton.2017.9313. M. Miscuglio, A. Mehrabian, Z. Hu, S. I. Azzam, J. George, A. V. Kildishev, M. Pelton, and V. J. Sorger, “All-optical nonlinear activation function for photonic neural networks,” Opt. Mater. Express 8, 3851–3863 (2018). https://doi.org/10.1364/ome.8.003851 Usual implementations with coherent nanophotonic circuits require additional nonlinear materials, such as graphene layers, which are integrated in a second stage,1212. Y. Shen, N. C. Harris, S. Skirlo, M. Prabhu, T. Baehr-Jones, M. Hochberg, X. Sun, S. Zhao, H. Larochelle, D. Englund, and M. Soljačić, “Deep learning with coherent nanophotonic circuits,” Nat. Photonics 11, 441–446 (2017). https://doi.org/10.1038/nphoton.2017.93 which increase the technological complexity. Alternatively, a laser cavity features a natural activation function in the form of gain—instead of absorption—saturation at the laser threshold. Moreover, in semiconductor quantum wells or quantum dots, cross-gain saturation leads to strong nonlinear mode competition, providing a mode selectivity mechanism that we attempt to exploit in this work. In a different approach, laser-based ANNs have also been used for simulating spin Hamiltonians,14,1514. N. Davidson, “Simulating spins with coupled lasers,” in Laser Science (Optical Society of America, 2017), p. LW6F–3.15. V. Pal, S. Mahler, C. Tradonsky, A. A. Friesem, and N. Davidson, “Rapid fair sampling of the XY spin Hamiltonian with a laser simulator,” Phys. Rev. Res. 2, 033008 (2020). https://doi.org/10.1103/physrevresearch.2.033008 multimode vertical-cavity surface-emitting lasers (VCSELs) have been shown to enable parallel ANNs,1616. X. Porte, A. Skalli, N. Haghighi, S. Reitzenstein, J. A. Lott, and D. Brunner, “A complete, parallel and autonomous photonic neural network in a semiconductor multimode laser,” J. Phys.: Photonics 3, 024017 (2021). https://doi.org/10.1088/2515-7647/abf6bd and a laser with intracavity spatial light modulator (SLM) has been implemented as a rapid solver for the phase retrieval problem.1717. C. Tradonsky, I. Gershenzon, V. Pal, R. Chriki, A. Friesem, O. Raz, and N. Davidson, “Rapid laser solver for the phase retrieval problem,” Sci. Adv. 5, eaax4530 (2019). https://doi.org/10.1126/sciadv.aax4530A most appealing candidate for laser-based integrated ANNs is a nanolaser. Nanolasers have huge potential for becoming the key building blocks of scalable, photonic computing systems, which are able to provide both high-performance and ultra-low energy consumption.1818. S. S. Deka, S. Jiang, S. H. Pan, and Y. Fainman, “Nanolaser arrays: Toward application-driven dense integration,” Nanophotonics 10, 149–169 (2021). https://doi.org/10.1515/nanoph-2020-0372 Remarkably, nanolaser technology has experimented a huge progress in recent years, enabling dense integration of laser nanosources on photonic microchips. Today, a myriad of cavity designs and materials come to maturity for realizing nanolaser arrays with advantages in terms of ultracompact footprints, low thresholds, and room-temperature operation.1919. C.-Z. Ning, “Semiconductor nanolasers and the size-energy-efficiency challenge: A review,” Adv. Photonics 1, 014002 (2019). https://doi.org/10.1117/1.ap.1.1.014002 Among these technological platforms, we can identify photonic crystal and metallo-dielectric and coaxial-metal nanolasers together with plasmonic lasers or spasers; in addition, quantum-dot-based micropillar lasers feature microcavity properties that make them promising for applications in, e.g., reservoir computing.2020. J. Große, T. Heuser, D. Brunner, I. Fischer, and S. Reitzenstein, “Nanophotonic hardware for reservoir computing-spectrally homogeneous microlaser arrays,” in The European Conference on Lasers and Electro-Optics (Optical Society of America, 2019), p. jsi_1_5. The common key physical mechanism of both micro and nanolasers leading to low energy consumption is their high quality factors (Q) combined with potentially high spontaneous emission factors (β),which ultimately bring the device operation deep into the thresholdless and few-photon regime. Furthermore, lasers with micro/nanocavities have two additional assets: (i) Evanescent coupling between neighboring cavities may lead to strong optical coupling, and consequently, a micro/nano laser array can be robust against fabrication imperfections. (ii) Intercavity coupling can be tailored by design with unprecedented control in photonic crystal platforms, which enable choosing both the magnitude and sign of the coupling parameters.21–2321. P. Hamel, S. Haddadi, F. Raineri, P. Monnier, G. Beaudoin, I. Sagnes, A. Levenson, and A. M. Yacomotti, “Spontaneous mirror-symmetry breaking in coupled photonic-crystal nanolasers,” Nat. Photonics 9, 311–315 (2015). https://doi.org/10.1038/nphoton.2015.6522. S. Haddadi, P. Hamel, G. Beaudoin, I. Sagnes, C. Sauvan, P. Lalanne, J. A. Levenson, and A. M. Yacomotti, “Photonic molecules: Tailoring the coupling strength and sign,” Opt. Express 22, 12359–12368 (2014). https://doi.org/10.1364/oe.22.01235923. B. Garbin, A. Giraldo, K. J. H. Peters, N. G. R. Broderick, A. Spakman, F. Raineri, A. Levenson, S. R. K. Rodriguez, B. Krauskopf, and A. M. Yacomotti, “Spontaneous symmetry breaking in a coherently driven nanophotonic Bose-Hubbard dimer,” Phys. Rev. Lett. 128, 053901 (2022). https://doi.org/10.1103/PhysRevLett.128.053901 As far as (i) is concerned, photonic crystal platforms are well suited since the evanescent intercavity coupling leads to large mode splitting that usually overcomes the resonance linewidths.2424. S. Ishii, K. Nozaki, and T. Baba, “Photonic molecules in photonic crystals,” Jpn. J. Appl. Phys. 45, 6108–6111 (2006). https://doi.org/10.1143/jjap.45.6108

In this work, we propose a photonic ANN based on an array of nanolasers, which is able to process and classify two classes of images. As a proof-of-concept demonstration, we process a database containing images of handwritten numbers. In terms of ANN architectures, our scheme corresponds to an input layer given by the input image (pixels in a 2D real space), an output decision layer given by the optical spectrum (pixels in the 1D frequency space), and hidden layers given by the nanolaser array. The input image is encoded into a spatially modulated pump beam. Therefore, each input pixel may excite many different nanolasers, and each nanolaser emission is connected to many output pixels because of the Fourier transformation that is performed all-optically. Thus, the result of the classification task—to fix the ideas, yes if the image has a handwritten zero, no otherwise—is read from the optical spectrum of the light emitted by the nanolaser array. Consequently, we can select a set of modes such that they are activated—i.e., pumped above laser threshold—only for a given set of input images (handwritten zeros), and they remain off—i.e., below threshold—otherwise. The key idea is that the spatial profile of the pump is appropriately designed such that when it encodes a specific type of image, it activates a particular set of modes of the array.

Similarly to the optical computing framework demonstrated in Ref. 2525. U. Teğin, M. Yıldırım, İ. Oğuz, C. Moser, and D. Psaltis, “Scalable optical learning operator,” Nat. Comput. Sci. 1, 542–549 (2021). https://doi.org/10.1038/s43588-021-00112-0, based on nonlinear mode interactions in a multimode fiber, in our implementation, the activation function is non-local as self and cross-gain saturation result in thresholding functions with high mode competition and selectivity. A crucial advantage of our setup is the use of nanolasers, which have ultra-low power consumption and very small footprint.This work is organized as follows: Sec.  presents the model used to describe the nanolaser array and introduces the definition of a particular type of collective mode, known as zero-mode. Section  describes the use of zero-mode lasing for binary classification, i.e., to determine whether an image that is encoded in the spatial profile of the pump corresponds (yes/no) to a particular digit. The dataset used, the machine learning algorithm developed to optimize the system’s performance, and its implementation are described in Secs. and . Sections –– present the results obtained, the discussion, and the conclusions, respectively.

II. MODEL

Section:

ChooseTop of pageABSTRACTI. INTRODUCTIONII. MODEL <<III. BINARY CLASSIFICATIO...IV. RESULTSV. DISCUSSIONVI. CONCLUSIONSREFERENCESPrevious sectionNext sectionWe consider a two-dimensional nanocavity array (shown in blue in Fig. 1), which consists of m × n cavities in the x and y directions, respectively. For simplicity, we only consider nearest-neighbor coupling and further assume that the resonance frequencies are the same for all the cavities (without loss of generality, we set them to be zero). The system is described by the following coupled-mode equations:idam,ndt=κx(am−1,n+am+1,n)+κy(am,n−1+am,n+1)+i(gm,n−γ)am,n.(1)Here, am,n are the field amplitudes, gm,n stand for the gain rates, which are the elements of the matrix that represents the spatial pump pattern (P = ), and γ is the optical loss rate, which is assumed the same for all the cavities; κx and κy are the coupling rates in x and y directions, respectively, assumed real. Although a small dissipative coupling is commonly used to describe loss-splitting in photonic crystal cavity arrays, its effect does not qualitatively change the results and has been neglected for simplicity.For the numerical calculations, we normalize the time in Eq. (1) to the timescale T = 0.2λ2/πcΔλ, where λ is the cavity-resonance frequency, c is the speed of light, and Δλ is the resonance linewidth. For typical photonic crystal nanolasers with λ = 1550 nm and quality factors of Q ∼ 4000, Δλ ≈ 0.4 nm, and hence T ≈ 1.27 ps. We then re-scale all the rates as γ → γT, gm,n → gm,nT, κx → κxT, and κy → κyT. Dissipation and coupling parameters can be modified through Q-factor and evanescent coupling engineering, respectively, which provides important degrees of freedom in the coupled cavity design. Throughout this work, we will fix γ = 0.2 and κx = κy = 1, consistent with standard coupled photonic crystal nanolaser geometries (see Sec. ).Next, we rewrite these equations in Dirac notationi∂|ψ〉∂t=H|ψ〉,(2)whereH=∑m,n(κx|am,n〉〈am+1,n|+κy|am,n〉〈am,n+1|+h.c.)+i(gm,n−γ)|am,n〉〈am,n|.(3)Here, h.c. stands for the Hermitian conjugate, and|ψ〉=(a1,1,a1,2,…,am,n)T(4)is the wavefunction, which is a vector containing the m × n complex amplitudes.A 2D cavity array as modeled by Eq. (1) may feature important symmetries such as the chiral—also known as the sublattice—symmetry, where H (not necessarily Hermitian) anti-commutes with a unitary operator. In the case of non-Hermiticity provided by a gain/loss distribution in a coupled cavity Hamiltonian verifying (κx,κy)∈R, the prevailing underlying symmetry is the non-Hermitian particle–hole (NHPH) symmetry.26,2726. L. Ge, “Symmetry-protected zero-mode laser with a tunable spatial profile,” Phys. Rev. A 95, 023812 (2017). https://doi.org/10.1103/physreva.95.02381227. F. Hentinger, M. Hedir, B. Garbin, M. Marconi, L. Ge, F. Raineri, J. A. Levenson, and A. M. Yacomotti, “Direct observation of zero modes in a non-Hermitian optical nanocavity array,” Photon. Res. 10(2), 574–586 (2022). https://doi.org/10.1364/PRJ.440050 In this case, the Hamiltonian in Eq. (3) satisfies the anticommutation relation HCT=−CTH, where C is the unitary operator and T is the time reversal operator.2626. L. Ge, “Symmetry-protected zero-mode laser with a tunable spatial profile,” Phys. Rev. A 95, 023812 (2017). https://doi.org/10.1103/physreva.95.023812Both chiral and particle–hole symmetries apply to arrays that can be decomposed in two sublattices A and B, where coupling only takes place between cavities from different sublattices. In the case of the 2D square lattice displayed in Fig. 1, the sublattices A and B are defined by the schematized checkerboard (red and blue sites in Fig. 1). Consequently, a 2D cavity array with nearest-neighbor coupling can be mapped to a bi-hidden-layer network, each hidden layer corresponding to one sublattice (see schematics next to the checkerboard, Fig. 1). Importantly, both layers are coupled to the input matrix I and also to the output layer that is the eigenmode spectrum, R(ε) (Fig. 1, right column).To investigate the properties of the NHPH symmetry, we diagonalize the Hamiltonian, H|ϕi⟩ = ɛi|ϕi⟩, where ɛi and |ϕi⟩ are the eigenvalues and the eigenvectors, respectively. Note that R(εi) and [−I(εi)] are the frequency and net loss rate of the ith mode, respectively. According to the anticommutation relation, we have thatH(CT|ϕi〉)=−CT(H|ϕi〉)=−CTεi|ϕi〉=−εi*(CT|ϕi〉).(5)

Therefore, CT|ϕi〉 is also an eigenvector of H with eigenvalue −εi*. We can denote the new eigenvector and eigenvalue as |ϕj〉=CT|ϕi〉 and εj=−εi*, respectively. Consequently, the NHPH symmetry possess two phases, the symmetry broken phase with εj=−εi*,i≠j and the symmetric phase with εi=−εi*, which implies that the NHPH-symmetric modes are zero-modes, defined by the condition R[εj]=0, and they are simultaneous eigenvectors of H and CT. Importantly, two eigenvalues that initially have different energies may upon variation of the pump parameter collide on the imaginary axis at an exceptional point and create a pair of NH zero-modes: this phenomenon is called the spontaneous restoration of the NHPH symmetry.

Zero-modes have captivated the attention of the scientific community because of the revolutionary concept of Majorana bound states. They constitute their own anti-particles and host non-Abelian braiding statistical properties, a most promising approach for fault tolerant topological quantum computation. In photonics, non-Hermitian zero-modes have been recently demonstrated in an array composed by three nanocavities.2727. F. Hentinger, M. Hedir, B. Garbin, M. Marconi, L. Ge, F. Raineri, J. A. Levenson, and A. M. Yacomotti, “Direct observation of zero modes in a non-Hermitian optical nanocavity array,” Photon. Res. 10(2), 574–586 (2022). https://doi.org/10.1364/PRJ.440050

III. BINARY CLASSIFICATION USING THE ZERO-MODES

Section:

ChooseTop of pageABSTRACTI. INTRODUCTIONII. MODELIII. BINARY CLASSIFICATIO... <<IV. RESULTSV. DISCUSSIONVI. CONCLUSIONSREFERENCESPrevious sectionNext sectionThe symmetric phase can be observed when the array is pumped in a selective manner.2626. L. Ge, “Symmetry-protected zero-mode laser with a tunable spatial profile,” Phys. Rev. A 95, 023812 (2017). https://doi.org/10.1103/physreva.95.023812 Unlike the zero-modes protected by chiral symmetry that satisfy ɛi = −ɛi and thus are restricted to ɛi = 0, the zero-modes warranted by NHPH symmetry satisfy R[εi]=0; therefore, they are free to move on the imaginary axis. Consequently, the NH zero-modes are robust, and one can manipulate them by controlling the pump pattern. Upon pumping the array with an appropriate spatial pattern, a zero-mode can reach the lasing threshold, I[εi]=0, before the other modes.On the other hand, if the spatially distributed pump cannot spontaneously restore the symmetric phase, a non-zero mode will lase. Thus, the pump patterns can be classified into two groups according to their ability to excite a zero-mode: the ones that can lead to zero-mode lasing and the ones that cannot. Therefore, for classification purposes, if the frequency separation between zero and non-zero modes is large enough such that they can be spectrally resolved using optical filters before detection, zero-mode lasing can be used for binary classification. For a proof-of-concept demonstration, we consider an 8 × 8 array, and we use a freely available database of images of handwriting numbers (details are presented in Sec. ).Let us consider an image of a handwritten zero, for instance, the one shown in Fig. 1, top left corner, and resize it to a 8 × 8 matrix of pixel values, I(1). To encode the image information into the pump profile, P(1), we define an appropriate transformation matrix M such that P(1)=MI(1), where the absolute value ensures that the elements of the pump profile are not negative. Then, P(1) is projected onto the nanolaser array by using a SLM. The transformation M has to be chosen such that the resulting pump pattern P(1) efficiently excites a zero-mode (R[εi(1)]=0) in such a way that it can reach the lasing threshold, I[εi(1)]=0 (Fig. 1, right column, top). Note that there can be many zero-modes in the spectrum because a multiplicity of NH zero-modes can be generated, each one having a different imaginary part. However, in the general case, only one will eventually reach the laser threshold as the pumping is increased.2626. L. Ge, “Symmetry-protected zero-mode laser with a tunable spatial profile,” Phys. Rev. A 95, 023812 (2017). https://doi.org/10.1103/physreva.95.023812For image classification, we need not only that one particular input image containing a handwritten zero, I(1), leads to lasing zero-mode (i.e., to a yes answer) but also that any image containing a handwritten zero, I(k), leads to lasing zero-mode (Fig. 1, middle row). Conversely, when the input is not a zero digit, we want that a non-zero mode turns on (Fig. 1, bottom row). Therefore, the key idea is to optimize the coefficients of the transformation matrix M such that a zero-mode turns on if and only if the input image corresponds to a handwritten zero digit.

In the following, we describe the machine learning procedure employed, which allows us to obtain the linear transformation, M, that optimizes the performance of the binary image classifier.

A. Machine learning optimization of the linear transformation matrix

Clearly, the choice of the transformation matrix, M, is crucial for obtaining a good classification performance. As previously stated, we are interested in using the zero-modes as detectors of a class of input images, and thus, we want a zero-mode to turn on if and only if the pump pattern encodes an image that represents the digit of choice. In this section and Sec. , we will describe how to optimize the array elements of M in order to obtain the best possible classification skills.We have employed the digit dataset freely available at the University of California–Irvine (UCI) ML repository,2828. D. Dua and C. Graff, UCI Machine Learning Repository (University of California, School of Information and Computer Science, Irvine, CA, 2019). which is a standard dataset for assessing the performance of image recognition systems. We used images that have a resolution that fits the size of the nanolaser array (8 × 8). In order to keep the calculation time reasonably low, we analyzed a subset of 360 images. We aim at training the nanolaser array to recognize a particular digit. Specifically, we can either distinguish between 0s and 1s (one-vs-one classifier) or between 0s and any other digit (one-vs-all classifier). Both classifiers can be used as building blocks of a multiclass classifier (see Sec. ).

Typically, the simplest implementation of a machine learning (ML) algorithm for a binary classifier would iteratively adjust its parameters to obtain a good separation between the two populations of the data it is trained with (training set). Then, its performance is assessed by looking at new, previously unseen data (testing set). Here, we follow this same paradigm. We randomly split the data into two parts: the training set, containing 75% of the samples (270 images), and the testing set, with the remaining 25% (90 images). The two sets are sampled so that each contains, on average, the same proportion of the two classes of images. In the case of the one-vs-all classifier, we downsampled the number of images containing digits 1–9, so the two classes (zero and non-zero digits) are balanced (i.e., zero digits are 50% of the total).

To train the classifier, we have to build a link between its parameters and the classification performance. The idea is to define a smooth cost function correlated with the system errors. In this way, minimizing the cost function improves the performance. The smoothness of the cost function is crucial for designing a numerically stable procedure.

As explained previously, we want a zero-mode to turn on when the input image corresponds to the right class (e.g., a handwritten zero). In addition, we want the gap between the lasing zero-mode and the other modes to be as large as possible as this will increase the classifier’s robustness to noise. Therefore, we define the “spectral gap” of a given image labeled k that is encoded in a pump pattern P(k) and an associated Hamiltonian, H(k), with eigenvalues εi(k) asΔε(k)=maxi:Rεi(k)≤δIεi(k)−maxi:Rεi(k)>δIεi(k),(6)where δ is a parameter that represents the spectral resolution of the experimental detection system, i.e., the bandwidth of the optical filter that will select a given mode. Ideally, δ is a very small number as the detector should allow to resolve modes with small detuning (see Sec. ). We will call the selected modes, the subset of modes for which Rεi(k)≤δ. These modes are either zero-modes or non-zero modes with very small real part. Physically, Δɛ(k) corresponds to the gain difference between the lasing mode (e.g., a selected one) and the first nonlasing mode belonging to the other subset (e.g., unselected one).We note that since at least one mode will lase, either the first or the second term in the rhs of Eq. (6) is null. In particular, if a selected mode lases, the first term is 0 and Δɛ(k) is positive, while it is negative otherwise. The value of the spectral gap depends on the input image and on the linear transformation matrix, M. Our goal is to correlate Δɛ(k) with the image class. For this reason, we use the following cost function:C=−∑k∈I[εi(k)(α)]=0, which is a root-finding problem. To improve performance, we replace the max with a differentiable softmax function σ(k)(α),σ(k)(α)=log∑i=164expI[εi(k)(α)].(A1)(3)

Calculate the spectrum of the Hamiltonian, pumped by the adjusted pump.

(4) Calculate the “spectral gap” [Eq. (6)] and obtain the result of the classification task from the sign of the gap: if Δɛ(k) > 0, the lasing mode is a selected mode (i.e., it is either a zero-mode or a non-zero mode with very small real part) and the answer is yes; else, the lasing mode is a non-selected mode and the answer is no.From the numerical point of view, the most demanding part of the pipeline is to calculate α to adjust the pump. The reason is that every evaluation of the softmax function at a different α implies the resolution of an eigenvalue problem. The cheapest operation of the pipeline is the calculation of the pump previous to the adjustment. We stress that this is the only operation that in an experimental setup would have to be performed numerically. All the other steps would come “for free” from the dynamics of the nanolaser array, performed optically at the hardware level. In addition, as discussed in Sec. , the matrix multiplication could also be implemented all-optically using a passive 2D metasurface.

留言 (0)

沒有登入
gif