Optical calculation chip, optical calculation apparatus, and control method thereof
By designing optical computing chips with multiple transmitters and multiple receivers, parallel processing of spectral signals and superimposed grayscale values are realized, solving the problems of complex structure and calculation logic of existing optical computing chips, and improving computing efficiency and accuracy.
Patent Information
- Application Number
- CN202510142117.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-02-08
- Publication Date
- 2025-05-13
AI Technical Summary
The structure and computing logic of existing optical computing chips are relatively complex, making it difficult to achieve efficient parallel computing and simple computing logic.
An optical computing chip is designed, including a plurality of transmitters and a receiving part, each of which includes a plurality of transmitters, and the transmitter transmits spectral signals of the same wavelength, and the receiving part is used to receive spectral signals of the same wavelength and superimpose their grayscale values to obtain calculation results.
By processing multiple data points in parallel, the calculation efficiency is significantly improved, signal processing is simplified, stability and reliability are improved, and the calculation is completed directly in the optical domain, simplified the calculation steps, and improved the calculation speed and accuracy.
Smart Images

Figure CN119986899A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of optical computing technology, and in particular to an optical computing chip, an optical computing device and a control method thereof. Background Art
[0002] Optical computing chips usually include light sources, optical waveguides, modulators, detectors, optical switches and distributors. The light source is used to generate optical signals for transmission; the optical waveguide is used to guide the optical signal to propagate within the chip; the modulator converts the electrical signal into an optical signal and modulates the light source to carry information; the detector converts the optical signal into an electrical signal again to facilitate the interface with the electronic system; the optical switch and distributor are used to switch and distribute the optical signal. In the related technology, the structure and computing logic of the optical computing chip are relatively complex. Summary of the invention
[0003] Embodiments of the present application provide an optical computing chip, an optical computing device, and a control method thereof.
[0004] In a first aspect, an embodiment of the present application provides an optical computing chip, including:
[0005] A plurality of transmitting units, each of which comprises a plurality of transmitters, and the plurality of transmitters of each transmitting unit are adapted to transmit spectral signals having the same wavelength;
[0006] A plurality of receiving parts are provided corresponding to the plurality of transmitting parts, and each of the receiving parts is used to receive a plurality of the spectral signals with the same wavelength and is suitable for superimposing the grayscale values of the spectral signals with the same wavelength to obtain a calculation result.
[0007] In one embodiment, a plurality of emitting portions are arranged in an array.
[0008] In one embodiment, the wavelengths of the spectrum signals emitted by the emitters of different emission parts are arranged differently.
[0009] In one embodiment, the plurality of receiving portions are arranged in an array.
[0010] In one embodiment, the receiving unit includes a spectral chip, which is used to receive a plurality of spectral signals with the same wavelength, and is suitable for superimposing the grayscale values corresponding to the plurality of spectral signals with the same wavelength to obtain a calculation result.
[0011] In one embodiment, there is a distance H between each of the transmitting portions and the corresponding receiving portion, wherein 1 nm ≤ H ≤ 1 kkm.
[0012] In one embodiment, the optical computing chip further includes a power control unit, which is electrically connected to the plurality of transmitters, and is used to control the power of the plurality of transmitters according to a plurality of operands of the data matrix to be calculated.
[0013] In one embodiment, the optical computing chip also includes a decoding control unit, which is electrically connected to the power control unit. The decoding control unit is used to receive operation instructions and multiple data matrices to be calculated, and is suitable for decoding the operation instructions and adjusting the multiple data matrices to be calculated according to the decoding results so that the multiple data matrices are suitable for logical addition operations.
[0014] In one embodiment, the optical computing chip further includes a result correction unit, which is used to perform carry correction processing on the calculation results of the multiple receiving units when overflow occurs.
[0015] In a second aspect, an embodiment of the present application provides an optical computing device, including:
[0016] The optical computing chip as described above;
[0017] A control module is used to obtain multiple data matrices and operation instructions, send multiple data matrices and operation instructions to the optical computing chip, and receive calculation results of multiple receiving units.
[0018] In a third aspect, an embodiment of the present application provides a control method based on the optical computing device as described above, comprising the following steps.
[0019] Obtain multiple data matrices and operation instructions;
[0020] Controlling at least part of the multiple emitters of the emitting unit to emit multiple spectral signals according to the operation instruction and multiple data matrices to be calculated;
[0021] The receiving unit is controlled to receive the plurality of spectral signals, and the receiving unit is controlled to superimpose the grayscale values corresponding to the plurality of spectral signals with the same wavelength to obtain a calculation result.
[0022] In one embodiment, the precision of the grayscale value is n, where n is a positive integer, the plurality of data matrices to be calculated include a first data matrix and a second data matrix, the operand of the first data matrix includes a, and the operand of the second data matrix includes b, wherein 0≤a+b≤2 n .
[0023] In one embodiment, 0≤a≤2 n-1 , and 0≤b≤2 n-1 .
[0024] Beneficial effects of the embodiments of the present application:
[0025] In an embodiment of the present application, each transmitting unit includes multiple transmitters, which can simultaneously transmit spectral signals of the same wavelength. This design enables the optical computing chip to process multiple data points in parallel, significantly improving the computing efficiency. The spectral signals emitted by the same transmitting unit have the same wavelength, which simplifies the processing of the signal by the receiving unit. The corresponding receiving unit only needs to receive and process the spectral signals of the same wavelength, without distinguishing and screening signals of multiple different wavelengths, which reduces the complexity of signal processing and improves the stability and reliability of the optical computing chip. The receiving unit superimposes the grayscale values of the spectral signals of the same wavelength to obtain the calculation results. This calculation method avoids the complex circuits and algorithms in traditional electronic calculations, and directly completes the calculation process in the optical domain, which not only simplifies the calculation steps, but also improves the calculation speed and accuracy, and the calculation logic is simpler and easier to operate, and also makes the structure of the optical computing chip relatively simple. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For those skilled in the art, other drawings can be obtained based on these drawings without creative work.
[0027] Figure 1 is a schematic diagram of the structure of an optical computing chip provided in an embodiment of the present application;
[0028] Figure 2 yes Figure 1 A schematic diagram of the structures corresponding to the multiple transmitting units and the multiple receiving units shown;
[0029] Figure 3 is a schematic diagram of the structure of multiple transmitting units provided in an embodiment of the present application;
[0030] Figure 4 is a schematic diagram of the structure of multiple receiving units provided in an embodiment of the present application;
[0031] Figure 5 A schematic diagram of the structure of a control module of a hardware operating environment involved in an embodiment of the present application;
[0032] Figure 6 It is a flowchart of a control method of an optical computing device provided in an embodiment of the present application.
[0033] Description of reference numerals:
[0034] 100. Optical computing chip; 10. Transmitting unit; 11. Transmitter; a. Spectral signal; 20. Receiving unit; 21. Spectral chip; 30. Power control unit; 40. Decoding control unit; 50. Result correction unit; 60. Receiving logic control unit. DETAILED DESCRIPTION
[0035] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present application. In addition, it should be understood that the specific implementation methods described herein are only used to illustrate and explain the present application, and are not used to limit the present application. In the present application, unless otherwise stated, the directional words such as "upper" and "lower" used generally refer to the upper and lower parts of the device in actual use or working state, specifically the drawing direction in the accompanying drawings; while "inside" and "outside" refer to the outline of the device.
[0036] Combine the following Figures 1 to 6 The optical computing chip 100, the optical computing device and the control method thereof of the present application are described.
[0037] Reference Figures 1 to 3 The optical computing chip 100 includes multiple transmitting units 10 and multiple receiving units 20, each transmitting unit 10 includes multiple emitters 11, and the multiple emitters 11 of each transmitting unit 10 are suitable for transmitting spectral signals a with the same wavelength. Corresponding to the multiple transmitting units 10, each receiving unit 20 is used to receive multiple spectral signals a with the same wavelength and is suitable for superimposing the grayscale values of the spectral signals a with the same wavelength to obtain a calculation result.
[0038] In the embodiment of the present application, each transmitting unit 10 includes a plurality of transmitters 11, which can simultaneously transmit spectral signals a with the same wavelength. This design enables the optical computing chip 100 to process multiple data points in parallel, significantly improving the computing efficiency. The spectral signals a emitted by the same transmitting unit 10 have the same wavelength, which simplifies the processing of the signal by the receiving unit 20. The corresponding receiving unit 20 only needs to receive and process the spectral signals a with the same wavelength, without distinguishing and screening signals with multiple different wavelengths, which reduces the complexity of signal processing and improves the stability and reliability of the optical computing chip 100. The receiving unit 20 superimposes the grayscale values of the spectral signals a with the same wavelength to obtain the calculation results. This calculation method avoids the complex circuits and algorithms in traditional electronic calculations, and directly completes the calculation process in the optical domain, which not only simplifies the calculation steps, but also improves the calculation speed and accuracy, and the calculation logic is simpler and easier to operate, and also makes the structure of the optical computing chip 100 relatively simple.
[0039] Reference Figure 2 and Figure 3 In one embodiment, a plurality of transmitting units 10 are arranged in an array, so that the transmitting units 10 arranged in an array can process multiple data points in parallel, and each transmitting unit 10 can independently transmit an optical signal, thereby realizing efficient parallel computing. The transmitting units 10 arranged in an array can more easily realize precise control and adjustment of the light beam. The design of the array arrangement makes the optical computing chip 100 easier to expand and upgrade. As computing needs increase, the computing power of the chip can be expanded by increasing the number of transmitting units 10. The transmitting units 10 arranged in an array can be more easily integrated with other optical components or electronic components. This highly integrated design helps to reduce the size and weight of the chip, reduce manufacturing costs, and improve the overall performance and reliability of the system. In the array arrangement, even if a certain transmitting unit 10 fails or fails, other transmitting units 10 can still continue to work, thereby ensuring the normal operation of the optical computing chip 100. This design enhances the fault tolerance of the chip and improves the stability and reliability of the optical computing chip 100. The array-arranged transmitting units 10 can make data processing more localized. Each transmitting unit 10 can be regarded as a small data processing unit, and they communicate through short-distance optical interconnections. This localized data processing method reduces the need for long lines, thereby reducing signal delays and power consumption. The array-arranged transmitting units 10 can be locally connected through an optical bus or an optical network, reducing the need for global interconnection. Through the array arrangement, the relative positions between the transmitting units 10 can be made more compact, thereby reducing the number of long lines. This helps to reduce signal delays and power consumption, and improve the overall performance of the system.
[0040] It should be noted that the present application does not limit the distance between adjacent transmitting units 10 , and the distance between adjacent transmitting units 10 can be set as needed.
[0041] In one embodiment, the wavelengths of the spectral signals a emitted by the emitters 11 of different emitting units 10 are set differently, so that the spectral signals a of different wavelengths can be more easily distinguished and identified. In an optical communication or optical sensing system, each emitting unit 10 uses optical signals of different wavelengths for communication or sensing, which can significantly reduce interference and misjudgment between signals. By adjusting the wavelengths of different emitting units 10, a variety of different functions and applications can be achieved. For example, in an optical computing chip 100, optical signals of different wavelengths can be used to perform different computing tasks or implement different logical functions.
[0042] In addition, wavelength diversity can also be used to build complex optical networks to achieve more efficient data transmission and signal processing. In an optical system, a certain transmitting unit 10 or an optical signal of a certain wavelength may be affected by interference or failure. However, since other transmitting units 10 use different wavelengths for communication or sensing, these interferences or failures will not have a fatal impact on the entire system. This wavelength redundancy design enables the system to continue to operate when some components fail, improving the stability and reliability of the system. In the optical computing chip 100, the use of an optical bus structure can make the connection between the transmitting units 10 more flexible and efficient. By optimizing the layout and design of the optical bus, the length and complexity of the connection can be further reduced.
[0043] It should be noted that, in other embodiments, the wavelengths of the spectral signals a emitted by the emitters 11 of different emitting units 10 may also be set to be the same or partially the same and partially different. Specifically, the present application does not limit this.
[0044] Reference Figure 2 and Figure 4In one embodiment, a plurality of receiving units 20 are arranged in an array. In this way, a plurality of receiving units 20 arranged in an array can process a plurality of optical signals in parallel, which means that the chip can process more data at the same time. This parallel processing capability is important for improving the overall performance of the optical computing chip. The receiving units 20 arranged in an array can be easily expanded. By increasing the number of receiving units 20, the data processing capability of the optical computing chip 100 can be further improved. The receiving units 20 arranged in an array can improve the signal-to-noise ratio by spatial diversity. When a certain receiving unit 20 is affected by interference or noise, other receiving units 20 can still receive effective optical signals, thereby improving the overall signal quality. In optical communication, signal loss is an important issue. By using the receiving units 20 arranged in an array, optical signals can be captured and received more effectively, reducing signal loss and bit error rate. The receiving units 20 arranged in an array can provide higher resolution and clearer images. By receiving optical signals simultaneously by multiple receiving units 20, finer image details can be reconstructed. The receiving units 20 arranged in an array can realize multi-channel communication. Each receiving unit 20 can be used as an independent communication channel to transmit different data or perform different communication tasks. This multi-channel communication capability can significantly improve the communication capacity and flexibility of the system.
[0045] In one embodiment, the receiving unit 20 includes a spectral chip 21, which is used to receive multiple spectral signals a with the same wavelength, and is suitable for superimposing the grayscale values corresponding to the multiple spectral signals a with the same wavelength to obtain a calculation result, so that the spectral chip 21 can accurately receive and distinguish spectral signals a with different wavelengths. By superimposing the grayscale values of multiple spectral signals a with the same wavelength, random errors can be averaged, thereby improving the accuracy of signal processing. The superposition calculation of grayscale values is relatively simple, thereby improving the efficiency of signal processing. The spectral chip 21 has a high sensitivity to the wavelength and intensity of the optical signal, and can accurately capture and distinguish signals from different sources. In the presence of noise or interference, by superimposing the grayscale values of multiple spectral signals a with the same wavelength, the influence of noise can be reduced and the anti-interference ability of the optical computing chip 100 can be improved.
[0046] It should be noted that the spectral chip 21 can accurately capture and distinguish these signals through its high-precision photoelectric elements and signal processing circuits. In image processing, the grayscale value represents the brightness information of the image. For color images, a grayscale image can be obtained by performing specific processing on the values of the three channels of red (R), green (G), and blue (B). The grayscale value usually ranges from 0 to 255, where 0 represents black and 255 represents white. When the spectral chip 21 receives multiple spectral signals a with the same wavelength, it converts these signals into corresponding grayscale values. Subsequently, the chip performs superposition processing on these grayscale values. The superposition method may be a simple arithmetic mean or other more complex algorithms. The purpose of superposition is to average random errors and improve the accuracy and stability of signal processing. By superimposing the grayscale values of multiple spectral signals a with the same wavelength, the influence of noise and interference can be reduced, thereby obtaining more accurate calculation results.
[0047] In one embodiment, there is a spacing H between each transmitting unit 10 and the corresponding receiving unit 20, wherein 1nm≤H≤1kkm, so that the spacing H ranges from 1 nanometer (nm) to 1 kilometer (kkm), covering a wide space from micro to macro. This design allows the spacing between the transmitting unit 10 and the receiving unit 20 to be flexibly adjusted according to the specific application scenario. Such a wide spacing range allows a variety of technical means to be used to achieve signal transmission and reception. For example, at the microscopic scale, advanced physical principles such as quantum entanglement and photon tunneling can be used; at the macroscopic scale, optical fiber communication, radio waves and other technical means can be used. By precisely controlling the spacing H between the transmitting unit 10 and the receiving unit 20, problems such as attenuation, scattering and interference during signal transmission can be optimized, thereby improving signal quality. At an appropriate spacing, the signal can be transmitted at a higher rate and lower loss. This helps to improve the overall performance and efficiency of the communication system. Reasonable spacing design helps to reduce the impact of the external environment on the system, such as electromagnetic interference, temperature changes, etc., thereby improving the stability of the system. In harsh environments, such as high temperature, high pressure or strong radiation, an appropriate spacing can protect the transmitting unit 10 and the receiving unit 20 from damage, ensuring continuous and stable operation of the system.
[0048] Reference Figure 1In some embodiments, the optical computing chip 100 further includes a power control unit 30, which is electrically connected to the plurality of emitters 11. The power control unit 30 is used to control the power of the plurality of emitters 11 according to the plurality of operands of the data matrix to be calculated. In this way, the power control unit 30 can adjust the power of the emitters 11 in real time according to the operands in the data matrix. This dynamic adjustment helps to ensure that each emitter 11 outputs the most suitable power during the calculation process, thereby improving the accuracy of the calculation. By precisely controlling the power of the emitter 11, the power control unit 30 can avoid unnecessary energy waste, which helps to improve the energy utilization efficiency of the entire optical computing chip 100 and extend the service life of the device. Under high-power operation, the emitter 11 may generate excessive heat, causing the optical computing chip 100 to overheat. The power control unit 30 can effectively reduce the risk of overheating and protect the hardware of the optical computing chip 100 from damage by limiting the power output of the emitter 11. When a transmitter 11 fails or its performance degrades, the power control unit 30 can adjust the power of other transmitters 11 to compensate for this defect, thereby improving the fault tolerance and reliability of the entire optical computing chip 100. Different computing tasks and data matrices may require different transmitter 11 power configurations. The power control unit 30 can flexibly adjust the power of the transmitter 11 to adapt to a variety of algorithms and data processing requirements. When processing large-scale data matrices and complex computing tasks, the power control unit 30 can ensure that the transmitter 11 operates at the optimal power, thereby improving computing performance and shortening computing time.
[0049] It should be noted that the power control unit 30 includes a microcontroller (MCU), a power regulation circuit, a feedback and monitoring circuit, and other auxiliary components. The MCU, as the core of the power control unit 30, is responsible for receiving and processing operands from the data matrix, and calculating the power required for each transmitter 11 based on these operands. The MCU may include components such as program space, master-slave I2C controller, digital diagnostic monitoring register, oscillator, temperature sensor, voltage regulator, ADC (analog-to-digital converter) and DAC (digital-to-analog converter) to achieve complex control logic and precise power regulation. The power regulation circuit includes a laser diode driver and a digital automatic power control (DAPC) circuit. The laser diode driver is responsible for converting the control signal output by the MCU into a current or voltage signal that can drive the transmitter 11 (such as a laser diode). It may include an input stage, an amplification stage, an output stage, a burst control stage, and an APC (automatic power control) circuit to ensure that the transmitter 11 outputs with stable power. The digital automatic power control (DAPC) circuit is an advanced power control technology that samples the current of the built-in photodiode of the laser, compares it with the reference voltage, and adjusts the drive bias current through a digital state machine and register control to achieve precise power control. The feedback and monitoring circuit includes a photodiode and an analog-to-digital converter (ADC). The photodiode is used to sample the intensity of the optical signal of the transmitter 11 and convert it into a current signal. This current signal is used for feedback and monitoring the power output of the transmitter 11. The ADC is used to convert the analog current signal output by the photodiode into a digital signal for processing and monitoring by the MCU. Other auxiliary components include a temperature sensor, a voltage regulator, and a serial interface circuit. The temperature sensor is used to monitor the temperature of the power control unit 30 and the transmitter 11 to ensure that they operate within a safe operating temperature range. The voltage regulator is used to provide a stable power supply voltage to ensure the stable operation of the power control unit 30 and the transmitter 11. The serial interface circuit is used for the MCU to communicate with other external devices (such as computers, data storage devices, etc.) to achieve data transmission and storage.
[0050] Reference Figure 1In some embodiments, the optical computing chip 100 further includes a decoding control unit 40, which is electrically connected to the power control unit 30. The decoding control unit 40 is used to receive operation instructions and multiple data matrices to be calculated, and is suitable for decoding the operation instructions and adjusting the multiple data matrices to be calculated according to the decoding results so that the multiple data matrices are suitable for logical addition operations. In this way, the decoding control unit 40 is a key component in the optical computing chip 100. It is responsible for receiving external operation instructions and multiple data matrices to be calculated. These operation instructions are usually transmitted in the form of coding, and the decoding control unit 40 needs to decode them, that is, convert them into a format or signal that can be recognized inside the chip. After decoding, the decoding control unit 40 will adjust the multiple data matrices to be calculated according to the decoding results. This adjustment is to make the format, size or arrangement of the data matrix meet the requirements of the logical addition operation. The existence of the decoding control unit 40 enables the optical computing chip 100 to directly receive and process the coded operation instructions and data matrices without additional conversion steps, which greatly improves the chip's computing efficiency and enables it to complete complex computing tasks faster. By adjusting the data matrix, the decoding control unit 40 can enable the optical computing chip 100 to process data matrices of different types and sizes. The decoding control unit 40 can also optimize the process of logical addition operations by adjusting the data matrix. By ensuring that the format and arrangement of the data matrix meet the operation requirements, the errors and unnecessary calculations in the operation process can be reduced, thereby improving the accuracy and efficiency of the operation.
[0051] It should be noted that logical addition is a basic mathematical operation. In optical computing, it is usually achieved through the superposition effect of light. That is, when two or more beams of light illuminate the same physical space area at the same time, the light intensity of the area is roughly their linear superposition, thereby achieving arithmetic addition. Furthermore, by setting a suitable threshold between "the sum of n beams of light" and "the sum of (n-1) beams of light", the "logical AND" operation can be achieved through binarization.
[0052] The decoding control unit 40 is a key component in the optical computing chip 100, and may contain multiple sub-components or modules to achieve its functions. The following is a summary of the components that the decoding control unit 40 may contain: instruction receiving module, decoder, data matrix processing module, control logic module, interface circuit and storage unit. The instruction receiving module is responsible for receiving external operation instructions. These instructions are usually transmitted in the form of encoding, and the instruction receiving module needs to be able to accurately capture and store these instructions. The decoder is one of the core components of the decoding control unit 40. It is responsible for decoding the received encoded instructions, that is, converting them into a format or signal that can be recognized inside the chip. The decoding process may involve parsing, checking and converting the bit stream of the instruction. The data matrix processing module is responsible for processing multiple data matrices to be calculated. It may contain multiple sub-modules, such as a data alignment module, a data scaling module and a data rearrangement module, which work together to ensure that the format, size or arrangement of the data matrix meets the requirements of logical addition operations. The control logic module is responsible for generating corresponding control signals based on the decoding results and the processing requirements of the data matrix. These control signals are sent to other parts of the chip (such as the power control unit 30, the logic addition unit, etc.) to instruct them to perform corresponding operations. The interface circuit is used to decode the communication between the control unit 40 and other components or external devices. It may include a serial interface, a parallel interface, or other types of communication interfaces to ensure the correct transmission and synchronization of data. The storage unit is used to temporarily store decoded instructions, processed data matrices, and control signals generated by the control logic module. This helps to ensure the integrity and traceability of the data and provide fast access when needed.
[0053] It should be noted that, in some embodiments, the addition and subtraction logic is decoded into the switch of the transmitter 11 through the control module, so that the addition and subtraction logic can be completed at the speed of light in a matrix parallel manner.
[0054] Reference Figure 1In one embodiment, the optical computing chip 100 further includes a result correction unit 50, which is used to perform carry correction processing on the calculation results of the multiple receiving units 20 when overflow occurs. In this way, the result correction unit 50 is an important component of the optical computing chip 100, and its main function is to monitor and process the calculation results of the multiple receiving units 20. When overflow occurs in these calculation results (that is, the calculation results exceed the preset range or precision), the result correction unit 50 will trigger the carry correction processing mechanism. Carry correction processing is a mathematical adjustment method used to restore the correct value of the calculation result when it overflows. In optical computing, due to the parallelism and high speed of light, the calculation results may be generated very quickly, so the result correction unit 50 needs to have the ability to respond quickly and accurately correct. The carry correction processing may involve operations such as detection, shifting, addition or subtraction of overflow bits to ensure the accuracy of the final result. The result correction unit 50 is connected to the multiple receiving units 20 through some form of interface or communication mechanism. The receiving unit 20 is responsible for performing the actual calculation task and transmitting the calculation result to the result correction unit 50. The result correction unit 50 monitors and analyzes the received calculation results, and when an overflow is detected, the carry correction process is triggered. The existence of the result correction unit 50 can significantly improve the calculation accuracy of the optical computing chip 100. By real-time monitoring and processing of overflow conditions, the result correction unit 50 can ensure the correctness of the final result and avoid calculation errors caused by overflow. When performing large-scale or high-precision calculations, the stability of the results is crucial. The result correction unit 50 helps to enhance the calculation stability of the optical computing chip 100 by processing overflow conditions, so that it can maintain stable performance in various application scenarios. Although the result correction unit 50 increases a certain amount of calculation overhead, the accuracy improvement and stability enhancement it brings can indirectly optimize the overall calculation efficiency. By reducing the repeated calculations or error processing time caused by calculation errors, the result correction unit 50 helps to improve the overall performance of the optical computing chip 100.
[0055] Reference Figure 1 In one embodiment, the optical computing chip 100 also includes a receiving logic control unit 60, which is electrically connected to the multiple receiving units 20. The receiving logic control unit 60 controls which part of the current calculation the data calculated by each receiving unit 20 belongs to, and whether the output result is independent or needs to be combined with other receiving units 20 to obtain a complete result; the receiving logic control unit 60 controls the cycle of a calculation, that is, the time to complete a calculation, when a calculation starts, when it ends, and when the result output from the receiving unit 20 is valid.
[0056] In a second aspect, the present application also provides an optical computing device, the optical computing device comprising the optical computing chip 100 and a control module (see Figure 5 ), the specific structure of the optical computing chip 100 refers to the above embodiment. Since the optical computing device adopts all the technical solutions of all the above embodiments, it at least has all the beneficial effects brought by the technical solutions of the above embodiments, which will not be described one by one here. The control module is used to obtain multiple data matrices and operation instructions, send multiple data matrices and operation instructions to the optical computing chip 100, and receive the calculation results of multiple receiving units 20.
[0057] It should be noted that the control module, as the core control unit of the entire optical computing device, is first responsible for reading multiple data matrices and operation instructions from external storage devices (such as memory, hard disk, etc.) or network communication interfaces. The data matrix may contain a large amount of numerical data for various mathematical operations or matrix operations; the operation instructions specify the specific operations to be performed on these data matrices, such as addition, multiplication, convolution, etc. The control module sends the acquired data matrix and operation instructions to the optical computing chip 100 through some form of interface (such as a serial interface, a parallel interface, a high-speed bus, etc.). After the optical computing chip 100 completes the operation, the calculation results are sent back to the control module through the same interface or another set of interfaces. The control module is responsible for receiving these calculation results and further processing or storing them as needed. Through the collaborative work of the control module and the optical computing chip 100, the high-speed parallel processing capability of optical computing can be fully utilized. The optical computing chip 100 can process multiple data matrices and operation instructions at the same time, thereby significantly improving the computing efficiency and shortening the computing time. The optical computing chip 100 usually has a strong computing power and can handle complex mathematical operations and matrix operations. Through the scheduling and management of the control module, the optical computing device can give full play to its computing power and complete various difficult computing tasks.
[0058] Reference Figure 6 In a third aspect, the present application further provides a control method based on the above optical computing device, comprising the following steps:
[0059] Step S100: Acquire multiple data matrices and operation instructions.
[0060] It should be noted that there are many types of operation instructions. For example, the operation instructions may include addition, multiplication, convolution and other operation instructions.
[0061] Step S200 , controlling the multiple emitters 11 of at least part of the transmitting unit 10 to emit multiple spectrum signals a according to the operation instruction and the multiple data matrices to be calculated.
[0062] It should be noted that in this step, the optical computing device first receives operation instructions from an external or internal control module. These instructions clearly specify what type of calculation is to be performed on the data matrix to be calculated. The control module inside the optical computing device is responsible for parsing these instructions and determining the corresponding calculation steps and the required data matrix. According to the operation instructions and the size of the data matrix, the control module will select part or all of the transmitting units 10 to work. Each transmitter 11 is configured to be able to emit a spectral signal a of a specific wavelength, which will be used in subsequent calculation processes. After receiving the instructions from the control module, the selected transmitter 11 begins to emit a spectral signal a. The parameters such as the wavelength, intensity and duration of these signals are precisely controlled to ensure that they can accurately represent the information in the data matrix.
[0063] Step S300 , controlling the receiving unit 20 to receive a plurality of spectral signals a, and controlling the receiving unit 20 to superimpose the grayscale values corresponding to the plurality of spectral signals a with the same wavelength to obtain a calculation result.
[0064] In this step, after the transmitting unit 10 emits the spectral signal a, these signals propagate in space and are received by the receiving unit 20 corresponding to the transmitting unit 10. According to the requirements of the operation instruction, the receiving unit 20 will superimpose the grayscale values corresponding to multiple spectral signals a with the same wavelength emitted by the same transmitting unit 10. By superimposing the grayscale values, the receiving unit 20 can calculate the total grayscale value corresponding to each wavelength, which reflects the sum of the intensities of all spectral signals a at the wavelength. After completing the superposition of the grayscale values, the receiving unit 20 will generate a calculation result.
[0065] It should be noted that there is a mapping relationship between the gray value and the calculation result. After the gray value is obtained, the value of the operand superposition can be obtained according to the mapping relationship. The mapping relationship between the gray value and the calculation result can be an empirical formula obtained through experimental measurement, or it can be a derivation result based on a mathematical model. Since the technology for establishing the mapping relationship is mature, this application will not be repeated here.
[0066] In addition, grayscale value is also called gray level or brightness value, which is a numerical value used to describe the brightness of pixels in an image. In a grayscale image, each pixel is assigned a grayscale value, which is usually an integer between 0 (black) and 255 (white). The size of the grayscale value reflects the brightness of the pixel. The larger the value, the brighter it is, and the smaller the value, the darker it is.
[0067] In an embodiment of the present application, the control method can process multiple data matrices and operation instructions at the same time, and realizes parallel processing of data by controlling multiple transmitters 11 of the transmitting unit 10 to emit multiple spectral signals a. This parallel computing method significantly improves the speed and efficiency of data processing. The transmission speed of the spectral signal a is extremely fast, far exceeding the transmission speed of traditional electronic signals, which makes the transmission of data in the optical computing device faster and further improves the overall computing efficiency. The control method controls the receiving unit 20 to superimpose the grayscale values corresponding to multiple spectral signals a with the same wavelength, thereby obtaining an accurate calculation result. This superposition method can ensure the accuracy and stability of the calculation result and avoid calculation errors caused by signal interference or transmission errors. The optical computing device usually has a high sensitivity and can accurately detect and process weak spectral signals a, which enables the control method to maintain a high calculation accuracy when processing low signal-to-noise ratio or weak signals. The control method can flexibly configure the working state of the transmitting unit 10 and the receiving unit 20 according to different operation instructions and data matrices, so that the power consumption generated by the optical computing device during data transmission and processing is low, which helps to reduce energy consumption and carbon emissions, and is in line with the current trend of green computing and sustainable development. Optical computing devices are usually manufactured using environmentally friendly materials, reducing pollution and damage to the environment.
[0068] In one embodiment, the precision of the grayscale value is n, where n is a positive integer, the plurality of data matrices to be calculated include a first data matrix and a second data matrix, the operand of the first data matrix includes a, and the operand of the second data matrix includes b, wherein 0≤a+b≤2 n , so the grayscale value precision is n, which means that it can accurately represent the range from 0 to 2 n-1 When the sum of operands a and b is in the range of 0 to 2n, it can be ensured that there will be no loss of precision due to exceeding the gray value representation range during the calculation process. Since the sum of operands a and b does not exceed 2n, this avoids erroneous results caused by data overflow during the calculation process, ensuring the accuracy and reliability of the calculation results. By limiting the sum of the operands to the range of 0 to 2n, the representation range of the gray value can be fully utilized, which avoids the waste of resources (such as unnecessary storage space or calculation time) caused by the excessive gray value range. Limiting the range of the sum of the operands can simplify the calculation process and reduce the calculation complexity, which helps to improve the calculation efficiency and reduce the calculation cost. By limiting the range of the sum of the operands, the accumulation of errors during the calculation process can be reduced, which helps to improve the stability and reliability of the system and ensure the accuracy of the calculation results. Within a certain error range, the optical computing device can tolerate certain data fluctuations and noise interference, which makes the optical computing device more robust and fault-tolerant in complex environments and practical applications.
[0069] In some embodiments, 0≤a≤2 n-1 , and 0≤b≤2 n-1 Thus, in optical computing devices, grayscale values are used to represent the intensity or size of data. When the precision of the grayscale value is n, it can represent values from 0 to 2. n-1 A series of integer values in the range of . Here a and b represent the operands in the first data matrix and the second data matrix respectively. 0≤a≤2 n-1 , and 0≤b≤2 n-1 The range of values for a and b is specified, and this range is determined based on the grayscale value representation capability. Specifically, the lower limit of 0 represents the minimum possible value of the data, corresponding to the lowest intensity or minimum value in the grayscale value representation. The upper limit is 2 n-1 The maximum possible value of the data, corresponding to the highest intensity or maximum value in the grayscale value representation, ensures that the values of a and b can be accurately represented by the grayscale value system without causing information loss or overflow. By limiting the range of a and b, it can be ensured that they will not exceed the representation capacity of the grayscale value system in any calculation process, which helps to maintain the integrity and accuracy of the data and avoid calculation errors or distortion of results. When the values of a and b are within the specified range, the calculation process can be carried out more efficiently, which reduces the additional calculation steps or resource consumption that may be generated by processing out-of-range values. By clarifying the range of a and b, the system design of the optical computing device can be simplified, which allows designers to focus more on optimizing calculation efficiency and accuracy rather than dealing with complex boundary conditions or outliers. Limiting the range of a and b helps reduce system instability caused by data overflow or anomalies, which enables the optical computing device to maintain stable performance when running for a long time or processing large amounts of data.
[0070] Due to device errors, grayscale values and operand values may not correspond one to one, and the two can be mapped according to a certain strategy. For example, grayscale values 0-7 correspond to value 0, grayscale values 8-16 correspond to value 1, and grayscale values 1016-1023 correspond to value 127. The transmission and receiving channels of a single spectral signal a can calculate two 7-bit data addition and subtraction operations at a time.
[0071] In the transmitting part 10 and the receiving part 20, each operand corresponds to an associated grayscale value, and the corresponding relationship can be determined according to specific needs or process conditions. For example, the grayscale values corresponding to the values 0, 1, 2, 3, ... in the transmitting part 10 and the receiving part 20 are all 0, 5, 10, 15, .... Because of the device error, the error of the transmitting part 10 is set to + / -1, and the value 0 is closed, which can be precisely controlled. Then, the grayscale value of the transmitting value 0 is 0, the grayscale value of the transmitting value 1 can be 4, 5, 6, the grayscale value of the value 2 can be 9, 10, 11, and the grayscale value of the value 3 can be 14, 15, 16, .... Then 1+2, the grayscale value in the receiving part 20 can be 13, 14, 15, 16, 17, that is, the center value corresponding to the value 2 is 15+ / -2, and the error is twice the error of the transmitting part 10. The error range of the receiving unit 20 is twice that of the transmitting unit 10, that is, the grayscale value of the receiving unit 20 is the corresponding grayscale value plus or minus twice the transmission error, and the difference between the grayscale values corresponding to adjacent values must be large enough to cover the errors introduced by multiple transmitters 11 in the same band. Assuming that the transmission error of each transmitter 11 is h, and the number of transmitters 11 in the same band is i, then the error of the receiving unit 20 is h*i, and the difference between the center values of the grayscale corresponding to adjacent values must be greater than 2*h*i.
[0072] It should be noted that the above-mentioned grayscale center value refers to the sum of the grayscale values of adjacent numerical values when there is no error. For example, when there is no error, the sum of the grayscale values of 1+2 is 15. When there is an error of + / -1, then it is 1+2. The grayscale value in the receiving unit 20 can be 13, 14, 15, 16, 17, where 15 is the center value of the grayscale corresponding to the adjacent numerical values.
[0073] The following table shows the calculation in the presence of transmission errors:
[0074]
[0075]
[0076] There will be errors in the correspondence between the grayscale value and the value of the operand. Depending on the process, the error range of the control accuracy is x, then the grayscale value center value P corresponding to the operand value is plus or minus x, that is, [Px, P+x]. For example, if the process accuracy error is 2, the center values P corresponding to the values 0, 1, 2, 3, ... are 4, 9, 14, 19, ... respectively, then the corresponding emission accuracy values can be mapped according to a certain strategy. For example, grayscale values 0-7 correspond to the value 0, grayscale values 8-16 correspond to the value 1, and grayscale values 1016-1023 correspond to the value 127. The emission and receiving channels of a single spectral signal a can calculate the addition and subtraction operations of two 7-bit data at a time.
[0077] The transmitting unit 10 and the receiving unit 20 transmit and receive at the same time through a synchronization mechanism, and start and end a data calculation at the same time. The grayscale values 0, 1, 2, ..., m*n+n obtained by each calculation can be freely combined into multiple result data according to the calculation needs. Assuming that the current operands a and b have a bit width of 8, the grayscale value obtained by each receiving unit is 9 bits. If two 32-bit wide operands are to be calculated, the spectrum 0, 1, 2, and 3 channels are taken respectively, and the [7:0], [15:8], [23:16], and [31:24] bits of the operands a and b are calculated respectively. Then, four 9-bit grayscale values can be obtained at the same time when receiving the spectrum 0, 1, 2, and 3. After calibration such as exposure, a complete 32-bit result can be obtained.
[0078] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, i.e., they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Those of ordinary skill in the art may understand and implement it without creative effort.
[0079] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods of each embodiment or some parts of the embodiment.
[0080] It should be noted that there are many types of equipment, for example, the equipment may include medical equipment, weapon devices, etc. Specifically, in the embodiments of the present application, the equipment includes a vehicle or a processing machine. In addition, the type of equipment can be further set as needed, and the present application does not limit this.
[0081] The embodiments of the present application are introduced in detail above. Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for technical personnel in this field, according to the idea of the present application, there will be changes in the specific implementation method and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.
Claims
1. An optical computing chip, characterized in that: include: A plurality of transmitting units, each of which comprises a plurality of transmitters, and the plurality of transmitters of each transmitting unit are adapted to transmit spectral signals having the same wavelength; A plurality of receiving parts are provided corresponding to the plurality of transmitting parts, and each of the receiving parts is used to receive a plurality of the spectral signals with the same wavelength and is suitable for superimposing the grayscale values of the spectral signals with the same wavelength to obtain a calculation result.
2. The optical computing chip according to claim 1, characterized in that: A plurality of transmitting parts are arranged in an array.
3. The optical computing chip according to claim 1, characterized in that: The wavelengths of the spectral signals emitted by the transmitters of different transmitting parts are set differently.
4. The optical computing chip according to claim 1, characterized in that: A plurality of receiving parts are arranged in an array.
5. The optical computing chip according to claim 1, characterized in that: The receiving unit includes a spectral chip, which is used to receive a plurality of spectral signals with the same wavelength and is suitable for superimposing the grayscale values corresponding to the plurality of spectral signals with the same wavelength to obtain a calculation result.
6. The optical computing chip according to any one of claims 1 to 5, characterized in that: There is a distance H between each of the transmitting parts and the corresponding receiving part, wherein 1nm≤H≤1kkm.
7. The optical computing chip according to any one of claims 1 to 5, characterized in that: The optical computing chip also includes a power control unit, which is electrically connected to the multiple transmitters and is used to control the power of the multiple transmitters according to multiple operands of the data matrix to be calculated.
8. The optical computing chip according to claim 7, characterized in that: The optical computing chip also includes a decoding control unit, which is electrically connected to the power control unit. The decoding control unit is used to receive operation instructions and multiple data matrices to be calculated, and is suitable for decoding the operation instructions and adjusting the multiple data matrices to be calculated according to the decoding results so that the multiple data matrices are suitable for logical addition operations.
9. The optical computing chip according to any one of claims 1 to 5, characterized in that: The optical computing chip further includes a result correction unit, which is used to perform carry correction processing on the calculation results of the multiple receiving units when overflow occurs.
10. An optical computing device, characterized in that: The optical computing device comprises: The optical computing chip according to any one of claims 1 to 9; A control module is used to obtain multiple data matrices and operation instructions, send multiple data matrices and operation instructions to the optical computing chip, and receive calculation results of multiple receiving units.
11. A control method based on the optical computing device according to claim 10, characterized in that: The following steps are involved: Obtain multiple data matrices and operation instructions; Controlling at least part of the multiple emitters of the emitting unit to emit multiple spectral signals according to the operation instruction and multiple data matrices to be calculated; The receiving unit is controlled to receive the plurality of spectral signals, and the receiving unit is controlled to superimpose the grayscale values corresponding to the plurality of spectral signals with the same wavelength to obtain a calculation result.
12. The control method of the optical computing device according to claim 11, characterized in that: The precision of the grayscale value is n, where n is a positive integer. The plurality of data matrices to be calculated include a first data matrix and a second data matrix. The operand of the first data matrix includes a, and the operand of the second data matrix includes b, wherein 0≤a+b≤2 n .
13. The control method of the optical computing device according to claim 12, characterized in that: 0≤a≤2 n-1 , and 0≤b≤2 n-1 .