Diffraction neural network optical classification method and system based on dual-wavelength differential modulation
By introducing a single diffraction layer and a dual-wavelength differential modulation mechanism into the optical computing system, the problem of accuracy degradation caused by assembly errors of multilayer diffraction devices is solved, achieving efficient and accurate optical classification, which is suitable for portable and embedded optical computing platforms.
Patent Information
- Application Number
- CN202511525624.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-24
- Publication Date
- 2025-11-21
AI Technical Summary
Existing optical computing systems based on deep neural networks are prone to positional deviations and angular errors during the assembly and alignment of multilayer diffraction devices, leading to a decrease in classification accuracy. Furthermore, the systems are highly complex and difficult to maintain efficiency and robustness in practical applications.
A data-driven end-to-end training strategy is adopted to optimize the phase distribution of a single diffraction layer. Combined with a dual-wavelength differential modulation mechanism, the input light field is modulated by two coherent light sources of different wavelengths. Optical classification is performed through differential normalization operations to eliminate interlayer alignment errors and simplify the system structure.
It significantly improves the accuracy and robustness of optical classification, reduces system complexity, and is easy to integrate into portable or embedded optical computing platforms, making it suitable for fields such as medical image analysis and target recognition in unmanned systems.
Smart Images

Figure CN120995183A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of optical computing and optical information processing technology. More specifically, this invention relates to an optical classification method and system based on a diffraction neural network using dual-wavelength differential modulation. Background Technology
[0002] With the rapid development of artificial intelligence and big data technologies, deep neural networks (DNNs) have been widely applied in many fields such as image recognition, object detection, speech analysis, and signal processing, and are gradually becoming an important core technology driving the progress of an intelligent society. However, the computation process of existing deep neural networks typically relies on electronic hardware platforms, such as GPUs (Graphics Processing Units) and TPUs (Tensor Processing Units). Although these platforms have achieved significant results in parallel computing and high-efficiency operation, their development is gradually approaching the limits of the physical performance of electronic devices: there are significant bottlenecks in processing speed, energy efficiency, and parallel scalability. In particular, as Moore's Law gradually becomes obsolete, the advantages of traditional electronic devices in terms of size reduction and computing power improvement are gradually diminishing, further driving the demand for new and efficient computing models.
[0003] Against this backdrop, optical computing has gradually attracted widespread attention. Unlike electronic computing, optical computing utilizes photons as information carriers, naturally possessing advantages such as high-speed propagation, low energy consumption, and highly parallel processing. By diffracting, interfering, and modulating the incident light field through optical elements, computational inference processes similar to deep neural networks can be realized within the "optical domain." In recent years, the concept of Diffractive Deep Neural Network (D2NN) has been proposed and gradually matured. This method arranges multiple diffraction structures in space, modulating the input signal layer by layer during propagation, so that the light intensity distribution on the output plane corresponds to the result of a specific classification task. Since the optical system does not consume additional energy during propagation and modulation and has parallel processing capabilities, D2NN has shown great potential in tasks such as handwritten digit recognition, image classification, and signal recognition. However, most existing D2NN schemes rely on multi-layer diffraction modulator cascade structures. Although this architecture can achieve high recognition accuracy in theoretical simulations, it has exposed a series of prominent problems in actual physical experiments and engineering applications.
[0004] During the assembly and alignment of multilayer diffraction devices, positional and angular deviations are unavoidable. These minute geometric errors cause discrepancies between the actual light field propagation and the theoretical model. Particularly in the visible light and shorter wavelength range, these errors are further amplified, severely impacting the reliability of the final classification results. As errors accumulate during the propagation of the light field across multiple layers, the output signal gradually deviates from the expected result of the trained model, leading to a decline in classification performance. For example, when there are micrometer-level deviations between layers, the recognition accuracy may decrease significantly.
[0005] Therefore, how to effectively avoid interlayer alignment errors, reduce system complexity, and improve classification accuracy and environmental robustness while ensuring the high efficiency of optical computing has become a key technical problem in the current research and application of optical neural networks. Summary of the Invention
[0006] One object of the present invention is to solve at least the above-mentioned problems and / or defects, and to provide at least the advantages described below.
[0007] To achieve these objectives and other advantages of the present invention, a diffraction neural network-based optical classification method based on dual-wavelength differential modulation is provided, comprising: S1. A data-driven end-to-end training strategy is adopted, and the phase distribution of a single diffraction layer is optimized using a deep learning backpropagation algorithm. S2. Load the encoding corresponding to the input information through the input layer connected to the computer; S3. Two coherent light sources of different wavelengths are introduced at the front end of the input layer to illuminate the code sequentially or in parallel, so as to form an input light field that is transmitted to a single diffraction layer. S4. After the single diffraction layer modulates the input light field, the output light field is detected by a detector set on the detection surface. S5. The computer connected to the detector performs differential normalization calculations on the light intensity of different wavelengths, and then obtains the discrimination signal for each category using the following formula. S c Complete optical classification: In the above formula, c is the category index, and ϵ is a small constant. I λ+,i Let represent the intensity distribution of the positive signal corresponding to the i-th probe sub-region. I λ-,i Let N be the intensity distribution of the negative signal corresponding to the i-th probe sub-region, N be the total number of pixels, and T be the hyperparameter temperature.
[0008] Preferably, in S1, the phase distribution training method for a single diffraction layer is as follows: S10. Randomly select 50 grayscale images from the dataset as mini-batch training data; S11. Upsample the original image, and use zero-padding as the upsampling method; S12. Simulate the input object through λ using the Rayleigh-Sommerfeld equation. + and λ - After irradiation, the output light intensity modulated by a single diffraction layer u i ( x , y , z 1): In the above formula, t ( x , y , z 1) indicates z = z Complex amplitude transmission coefficient at position 1 h i ( x , y , z 1- z 0) represents the impulse response function, and * indicates convolution operation. u i ( x , y , z 0) indicates z = z The complex optical field at position 0; After all modulation is completed, the intensity distribution is obtained on the detection surface. I i ( x , y It is represented by the following formula: In the above formula, h i ( x , y , z - z 1) To be from the plane z = z 1 spread to z = z The transfer function at a location is used to describe the diffraction transfer characteristics of the light field during propagation; S13. Calculate the softmax cross-entropy loss L using the following formula: In the above formula, B represents the number of samples included in one training iteration. Indicates the first m The sample at the th iReal labels on the class, For the first m The sample at the th i The network output corresponding to the class; S14. Use the Adam optimizer for backpropagation to update neuron phases, with a learning rate of 0.005 and a decay rate of 0.98 epochs × 10⁻⁶. -3 ; S15. After 50 training cycles, the phase distribution training of the single diffraction layer is considered complete when the loss stabilizes.
[0009] Preferably, the input layer has a grid size of 168×168 and a pixel pitch of 8µm; The single diffraction layer contains 200×200 trainable neurons, each neuron is 8µm in size, and the neurons are interconnected by Rayleigh-Sommerfeld diffraction optics, supporting a phase modulation range of 0 to 2π. The detection surface is located 5 cm downstream of the diffraction layer. The detection surface is divided into 10 sub-regions, each with a size of 80 µm, and each sub-region corresponds to an optical classification.
[0010] An optical classification system, applied in a diffraction neural network-based optical classification method using dual-wavelength differential modulation, includes: Two coherent light sources with different wavelengths; A semi-transparent, semi-reflective mirror that matches the laser output direction of each coherent light source; The input layer is located downstream of the semi-transparent mirror; A single diffraction layer is set between the detector surface and the input layer; A detector mounted on the detection surface.
[0011] This invention offers at least the following advantages: First, it employs a single diffraction layer instead of a multi-layer structure. Deep learning is used to train and optimize the phase distribution of the single diffraction layer, enabling it to produce differentiated outputs under different wavelengths of incident light. All optical information processing is completed within this single layer. Compared to existing technologies, this single-layer structure significantly reduces the complexity of the optical system and completely avoids the accuracy degradation caused by the accumulation of inter-layer alignment errors during the actual assembly and adjustment of multi-layer diffraction deep neural networks. Secondly, this invention introduces a dual-wavelength differential detection mechanism in conjunction with a single diffraction layer. That is, two coherent light sources with different wavelengths are introduced at the input end, and optical classification is completed by performing differential normalization calculation on the light intensity corresponding to different wavelengths. This method, by introducing a dual-wavelength differential detection mechanism, obtains complementary spatial frequency information, effectively overcoming the feature loss and non-negativity constraint problems existing in single-wavelength systems, thereby significantly improving classification accuracy under the same hardware conditions.
[0012] Thirdly, the optical system corresponding to this invention, due to the combination of dual-wavelength differential detection mechanism and single diffraction layer, significantly reduces the complexity of the optical path compared to the prior art because it uses fewer hardware parameters. At the same time, the overall structure is compact and the optical components are small, making it easy to integrate into portable or embedded optical computing platforms. It is suitable for widespread application in multiple fields such as medical image analysis and target recognition in unmanned systems where high speed, power consumption and accuracy are required.
[0013] Other advantages, objectives and features of the present invention will become apparent in part from the following description, and in part from those skilled in the art through study and practice of the invention. Attached Figure Description
[0014] Figure 1 This is a block diagram of the optical system of the present invention; Among them, laser I-1, laser II-2, semi-transparent mirror-3, input layer-4, inter-diffraction layer-5, and detector-6. Detailed Implementation
[0015] The present invention will now be described in further detail with reference to the accompanying drawings, so that those skilled in the art can implement it based on the description.
[0016] A diffraction neural network optical classification method based on dual-wavelength differential modulation is proposed. The technical approach involves introducing two coherent light sources with different wavelengths at the input layer front end, namely, a first wavelength λ... + Second wavelength λ - Two sets of light fields are generated under dual-wavelength illumination. After propagating through a single diffraction layer, the wavelength-dependent intensity distribution is obtained on the detection surface by a detector. I λ+ and I λ- The detection surface is divided into multiple detection regions, each corresponding to a category. This is achieved by analyzing λ... + and λ - The corresponding light intensity is subjected to differential normalization to obtain the discrimination signal for each category: In the above formula, c is the category index, and ϵ is a small constant used to prevent instability caused by the denominator approaching zero in actual calculations. I λ+,i Let represent the intensity distribution of the positive signal corresponding to the i-th probe sub-region. I λ-,i Let N be the intensity distribution of the negative signal corresponding to the i-th probe sub-region, N be the total number of pixels, and T be the hyperparameter temperature, which is usually taken as 0.1.
[0017] The difference mechanism not only overcomes the limitation that light intensity signals are naturally non-negative, but also significantly improves feature discrimination, thereby enhancing classification accuracy. Using the cross-entropy loss function as the optimization objective, combined with gradient descent (such as the Adam optimizer), the phase parameters are iteratively updated until convergence.
[0018] Furthermore, the specific implementation steps of the present invention include: S1. A data-driven end-to-end training strategy is adopted, and the phase distribution of a single diffraction layer is optimized using a deep learning backpropagation algorithm. In S1, the main approach is to train the model using an electronic neural network to obtain a phase distribution that conforms to the physical modulation parameters. Specifically, this step employs a data-driven end-to-end training strategy, utilizing a deep learning backpropagation algorithm to optimize the phase distribution of a single diffraction layer. Training uses deep learning to optimize the phase parameters of the single diffraction layer. For the input datasets: MNIST and Fashion-MNIST, each containing 60,000 training samples and 10,000 test samples. Fifty grayscale images are randomly selected from the datasets as a mini-batch (batch size=32). The original images are upsampled and zero-padding is applied. Forward propagation: The input object is in λ... + and λ - Under downward illumination, the output intensity I is generated by modulation through a single diffraction layer. λ+ and I λ- Using the Rayleigh-Sommerfeld equations to simulate propagation, the modulated optical field is: In the above formula, t ( x , y , z 1) indicates z = z Complex amplitude transmission coefficient at position 1 h i ( x , y , z 1- z 0) represents the impulse response function, and * indicates convolution operation. u i ( x , y , z 0) indicates z = z The complex optical field at position 0; The intensity distribution is obtained on the detection surface after all modulation is completed: In the above formula, h i ( x , y ,z - z 1) From the plane z = z 1 spread to z = z Transfer function at location; Loss calculation: Using softmax cross-entropy (SCE) loss: In the above formula, B represents the batch size, which is the number of samples included in one training session. Indicates the first m The sample at the th i The true label on the class is usually one-hot encoded, that is, when the sample belongs to the class, the true label is generated by the first hot encoding. i The value is 1 for the specified category and 0 for all other categories. For the first m The sample at the th i The network output corresponding to the class; The backpropagation process uses the Adam optimizer (learning rate 0.005, decay rate 0.98 epochs × 10). -3 ) S2. Load the encoding corresponding to the input information through the input layer connected to the computer; In S2, the input layer is sized as a 168×168 grid with an 8µm pixel pitch. Input objects (such as MNIST handwritten digits or Fashion-MNIST fashion items) are encoded as amplitude-modulated wavefronts. The original object size is 28×28 pixels, upsampled to 168×168 via nearest-neighbor interpolation, and zero-padding is applied to match the network size.
[0019] S3. Two coherent light sources of different wavelengths are introduced at the front end of the input layer to illuminate the code sequentially or in parallel, so as to form an input light field that is transmitted to a single diffraction layer. In S3, a single diffraction layer is located 5 cm downstream of the input layer and contains 200 × 200 trainable neurons, each 8 µm in size. The neurons are interconnected via Rayleigh-Sommerfeld diffraction optics, supporting phase modulation from 0 to 2π, and utilize a sigmoid activation function. This layer shares modulation parameters for both wavelengths; S4. After the single diffraction layer modulates the input light field, the output light field is detected by a detector set on the detection surface. In S4, the detector plane is located 5 cm downstream of the diffraction layer and is divided into 10 sub-regions (each 80 µm), corresponding to 10 categories (C = [c0, c1, ..., c9]). λ is captured using a detector. + (1064nm, positive signal) and λ -Given the intensity distribution at (532nm, negative signal), the optical diffraction propagation model can be simplified to: Here, L represents the system optical operator used to describe the mathematical mapping relationship of the input light field after passing through the optical system. In specific implementations, this operator can correspond to optical diffraction propagation, optical convolution, or a full optical transformation composed of a modulation layer and a detector layer. For the input light field, and .
[0020] S4. The computer connected to the detector performs differential normalization calculations on the light intensity of different wavelengths, and then obtains the discrimination signal for each category using the following formula. S c Complete optical classification: In the above formula, c is the category index, and ϵ is a small constant used to prevent instability caused by the denominator approaching zero in actual calculations. I λ+,i Let represent the intensity distribution of the positive signal corresponding to the i-th probe sub-region. I λ-,i Let N be the intensity distribution of the negative signal corresponding to the i-th probe sub-region, N be the total number of pixels, and T be the hyperparameter temperature, which is usually taken as 0.1.
[0021] The method of this invention eliminates the assembly and adjustment errors caused by multi-layer devices through a single-layer diffraction structure and introduces a dual-wavelength differential detection mechanism to overcome the limitation of non-negativity of light intensity signals. Thus, while ensuring structural simplification, it significantly improves classification accuracy and robustness, and has important engineering value and application prospects.
[0022] An optical system, such as Figure 1 As shown, it includes: Two coherent light sources with different wavelengths, such as wavelength λ + Laser I1 with a wavelength of 1064nm, wavelength λ - =532nm laser II2, wherein laser I1 is a 1064nm continuous wave (CW) infrared laser (e.g., Nd:YAG laser, power ~50-100mW, ensuring single-mode and coherence), and laser II2 is a 532nm continuous wave green laser (e.g., frequency-second Nd:YAG or DPSS laser, power ~50-100mW, coherent); A semi-transparent and semi-reflective mirror 3, which is matched with the laser output direction of each coherent light source, is used to transmit the light generated by each laser sequentially or in parallel (ensuring no crosstalk) to the input layer. Set up an input layer 4 downstream of the semi-transparent mirror. The input layer uses an amplitude modulator (SLM or similar device) for encoding input, such as a reflective DMD (e.g., Texas Instruments DLP series, such as DLP6500, resolution 1920x1080, micromirror size ~6.5µm). In actual use, the input pattern is loaded by connecting to a computer (via USB or PCIe interface) and using software (such as DLP LightCrafter). A single diffraction layer 5 is positioned between the detector surface and the input layer. This single diffraction layer employs a phase-modulated SLM or a 3D-printed phase plate, such as a reflective phase-only LC-SLM (e.g., Meadowlark Optics or Holoeye PLUTO series, resolution 1920x1080, pixel pitch ~8µm, supports 0-2π phase modulation, broadband coverage 532-1064nm). The trained phase distribution is loaded (using Holoeye SLM Pattern Generator software to convert the phase map to a grayscale image, followed by sigmoid activation normalization). A detector 6 is positioned on the detector surface, such as a CCD camera placed 5cm from the diffraction layer. When the light field propagates to the detector surface, a filter and CCD work together (to achieve wavelength separation) to separate λ. + and λ - Intensity is calculated to facilitate the determination of light intensity in different regions using a differential algorithm later.
[0023] The above solution is merely an illustration of a preferred example and is not limited thereto. When implementing this invention, appropriate substitutions and / or modifications can be made according to the user's needs.
[0024] Although embodiments of the present invention have been disclosed above, they are not limited to the applications listed in the specification and embodiments. It can be applied to various fields suitable for the present invention. Other modifications can be readily made by those skilled in the art. Therefore, without departing from the general concept defined by the claims and their equivalents, the present invention is not limited to the specific details and examples shown and described herein.
Claims
1. An optical classification method based on a diffraction neural network using dual-wavelength differential modulation, characterized in that, include: S1. A data-driven end-to-end training strategy is adopted, and the phase distribution of a single diffraction layer is optimized using a deep learning backpropagation algorithm. S2. Load the encoding corresponding to the input information through the input layer connected to the computer; S3. Two coherent light sources of different wavelengths are introduced at the front end of the input layer to illuminate the code sequentially or in parallel, so as to form an input light field that is transmitted to a single diffraction layer. S4. After the single diffraction layer modulates the input light field, the output light field is detected by a detector set on the detection surface. S5. The computer connected to the detector performs differential normalization calculations on the light intensity of different wavelengths, and then obtains the discrimination signal for each category using the following formula. S c Complete optical classification: In the above formula, c is the category index, and ϵ is a small constant. I λ+,i Let represent the intensity distribution of the positive signal corresponding to the i-th probe sub-region. I λ-,i Let N be the intensity distribution of the negative signal corresponding to the i-th probe sub-region, N be the total number of pixels, and T be the hyperparameter temperature.
2. The optical classification method based on diffraction neural network with dual-wavelength differential modulation as described in claim 1, characterized in that, In S1, the phase distribution training method for a single diffraction layer is as follows: S10. Randomly select 50 grayscale images from the dataset as mini-batch training data; S11. Upsample the original image, and use zero-padding as the upsampling method; S12. Simulate the input object through λ using the Rayleigh-Sommerfeld equation. + and λ - After irradiation, the output light intensity modulated by a single diffraction layer u i ( x , y , z 1): In the above formula, t ( x , y , z 1) indicates z=z Complex amplitude transmission coefficient at position 1 h i ( x , y , z 1- z 0) represents the impulse response function, and * indicates convolution operation. u i ( x , y , z 0) indicates z=z The complex optical field at position 0; After all modulation is completed, the intensity distribution is obtained on the detection surface. I i ( x , y It is represented by the following formula: In the above formula, h i ( x , y , z - z 1) From the plane z=z 1 spread to z=z Transfer function at location; S13. Calculate the softmax cross-entropy loss L using the following formula: In the above formula, B represents the number of samples included in one training iteration. Indicates the first m The sample at the th i Real labels on the class, For the first m The sample at the th i The network output corresponding to the class; S14. Use the Adam optimizer for backpropagation to update neuron phases, with a learning rate of 0.005 and a decay rate of 0.98 epochs × 10⁻⁶. -3 ; S15. After 50 training cycles, the phase distribution training of the single diffraction layer is considered complete when the loss stabilizes.
3. The optical classification method based on diffraction neural network with dual-wavelength differential modulation as described in claim 1, characterized in that, The input layer has a 168×168 grid size and a pixel pitch of 8µm. The single diffraction layer contains 200×200 trainable neurons, each neuron is 8µm in size, and the neurons are interconnected by Rayleigh-Sommerfeld diffraction optics, supporting a phase modulation range of 0 to 2π. The detection surface is located 5 cm downstream of the diffraction layer. The detection surface is divided into 10 sub-regions, each with a size of 80 µm, and each sub-region corresponds to an optical classification.
4. An optical classification system, applied in the optical classification method based on dual-wavelength differential modulation diffraction neural network as described in any one of claims 1-3, characterized in that, include: Two coherent light sources with different wavelengths; A semi-transparent, semi-reflective mirror that matches the laser output direction of each coherent light source; The input layer is located downstream of the semi-transparent mirror; A single diffraction layer is set between the detector surface and the input layer; A detector mounted on the detection surface.
Citation Information
Patent Citations
Multi-task diffraction neural network equipment based on multi-wavelength parallelism and processing method
CN115809694A
Cited By
Dynamic holographic generation method and system of reconfigurable diffraction neural network
CN121187094A
Light diffraction neural network classification method and system based on ensemble learning
CN122637042A