Optoelectronic integrated circuit for message compression in message hash algorithm

文档序号:1830684 发布日期:2021-11-12 浏览:32次 中文

阅读说明:本技术 用于消息散列算法中消息压缩的光电集成电路 (Optoelectronic integrated circuit for message compression in message hash algorithm ) 是由 戴琼海 邓辰辰 郑纪元 吴嘉敏 于 2021-10-12 设计创作,主要内容包括:本申请涉及电数字数据处理技术领域,特别涉及一种用于消息散列算法中消息压缩的光电集成电路,光电集成电路上集成设置有第一至第N级光学神经网络和光电探测器阵列,其中,第一至第N级光学神经网络,用于对通过波导并行输入的多路初始光信号按照从第一至第N级逐级进行消息散列算法中的消息压缩运算,其中,通过每级光学神经网络对加载至多路初始光信号的消息进行消息压缩运算,并逐级压缩至满足压缩条件的最终光信号;光电探测器阵列,用于将最终光信号转换成用于携带消息压缩结果的电信号。由此,解决了相关技术中基于硬件电路实现消息散列算法的每轮运算时动态翻转功耗较大,导致消息压缩时功耗大,降低运算性能等问题。(The application relates to the technical field of electric digital data processing, in particular to a photoelectric integrated circuit for message compression in a message hash algorithm, wherein the photoelectric integrated circuit is integrated with first to Nth-level optical neural networks and a photoelectric detector array, the first to Nth-level optical neural networks are used for carrying out message compression operation in the message hash algorithm on a plurality of paths of initial optical signals input in parallel through waveguides from the first to Nth levels step by step, and the information loaded to the plurality of paths of initial optical signals is subjected to message compression operation through each level of optical neural network and is compressed step by step to a final optical signal meeting compression conditions; and the photoelectric detector array is used for converting the final optical signal into an electric signal for carrying a message compression result. Therefore, the problems that in the related art, when each round of operation of a message hash algorithm is realized based on a hardware circuit, the dynamic overturning power consumption is large, the power consumption is large when the message is compressed, the operation performance is reduced and the like are solved.)

1. An optoelectronic integrated circuit for message compression in a message hashing algorithm is characterized in that a first-Nth-level optical neural network and a photodetector array are integrated on the optoelectronic integrated circuit, wherein,

the first to nth stages of optical neural networks are used for performing message compression operation in a message hash algorithm on a plurality of initial optical signals input in parallel through the waveguide from the first to nth stages step by step, wherein the message loaded to the plurality of initial optical signals is subjected to message compression operation through each stage of optical neural network and is compressed step by step to a final optical signal meeting compression conditions;

the photodetector array is used for converting the final optical signal into an electrical signal for carrying a message compression result.

2. The optoelectronic integrated circuit of claim 1, wherein each of the first to nth stages of optical neural networks includes first to tenth inputs and first to eighth outputs, the outputs and the inputs of the first to eighth of all adjacent stages of optical neural networks are correspondingly connected by optical fibers, the first to eighth inputs of the first stage of optical neural network are configured to receive the first to eighth original optical signals input in parallel by the waveguide, the ninth input of each stage of optical neural network is configured to receive the ninth original optical signal input in parallel by the waveguide, and the tenth input of each stage of optical neural network is configured to receive the tenth original optical signal input in parallel by the waveguide.

3. The optoelectronic integrated circuit of claim 2, wherein each stage of the optical neural network further comprises first to sixth micro-nano optical diffraction line arrays, the first to fourth micro-nano optical diffraction line arrays comprise first to third input ends and output ends, the fifth to sixth micro-nano optical diffraction line arrays comprise first to second input ends and output ends, and wherein, in each stage of the optical neural network:

the first input end and the fifth input end of the first micro-nano optical diffraction line array are connected through an optical fiber, the second input end and the eighth input end are connected through an optical fiber, the third input end and the ninth input end are connected through an optical fiber, the output end of the first micro-nano optical diffraction line array is connected with the second input end of the fourth micro-nano optical diffraction line array through an optical fiber, and the first micro-nano optical diffraction line array is used for performing first diffraction operation on a fifth input optical signal, an eighth input optical signal and a ninth input optical signal through a first preset diffraction pattern of the first micro-nano optical diffraction line array and inputting a first diffraction optical signal obtained through diffraction operation to the fourth micro-nano optical diffraction line array;

the first input end and the fifth input end of the second micro-nano optical diffraction line array are connected through an optical fiber, the second input end and the sixth input end are connected through an optical fiber, the third input end and the seventh input end are connected through an optical fiber, the output end of the second micro-nano optical diffraction line array is connected with the first input end of the fourth micro-nano optical diffraction line array through an optical fiber, and the second micro-nano optical diffraction line array is used for performing second diffraction operation on a fifth input optical signal, a sixth input optical signal and a seventh input optical signal through a second preset diffraction pattern of the second micro-nano optical diffraction line array and inputting a second diffraction optical signal obtained by diffraction operation into the fourth micro-nano optical diffraction line array;

the first input end of a third micro-nano optical diffraction line array is connected with the first input end through an optical fiber, the second input end of the third micro-nano optical diffraction line array is connected with the second input end of the fifth micro-nano optical diffraction line array through an optical fiber, the output end of the third micro-nano optical diffraction line array is connected with the first input end of the fifth micro-nano optical diffraction line array through an optical fiber, and the third micro-nano optical diffraction line array is used for performing third diffraction operation on the first input optical signal, the second input optical signal and the third input optical signal through a third preset diffraction pattern of the third micro-nano optical diffraction line array and inputting the third diffraction optical signal obtained by diffraction operation into the fifth micro-nano optical diffraction line array;

the third input end of the fourth micro-nano optical diffraction line array is connected with the tenth input end through optical fibers, the output end of the third micro-nano optical diffraction line array is respectively connected with the second input end of the fifth micro-nano optical diffraction line array and the second input end of the sixth micro-nano optical diffraction line array through optical fibers, and the fourth micro-nano optical diffraction line array is used for performing fourth diffraction operation on the first diffraction light signal, the second diffraction light signal and the tenth input light signal through a fourth preset diffraction pattern of the fourth micro-nano optical diffraction line array and inputting the fourth diffraction light signal obtained by diffraction operation to the fifth micro-nano optical diffraction line array and the sixth micro-nano optical diffraction line array;

the output end of the fifth micro-nano optical diffraction line array is connected with the first path of output end, and is used for performing fifth diffraction operation on a third diffraction light signal and a fourth diffraction light signal through a fifth preset diffraction pattern of the fifth micro-nano optical diffraction line array, and inputting a fifth diffraction light signal obtained by the diffraction operation to the first path of output end;

the first input end of the sixth micro-nano optical diffraction line array is connected with the fourth input end, the output end of the sixth micro-nano optical diffraction line array is connected with the fifth output end, and the sixth micro-nano optical diffraction line array is used for performing sixth diffraction operation on a fourth diffraction light signal and a fourth input light signal through a sixth preset diffraction pattern of the sixth micro-nano optical diffraction line array, and inputting the sixth diffraction light signal obtained by the diffraction operation to the fifth output end.

4. The optoelectronic integrated circuit of claim 3,

the first diffraction operation is: s2=h +K+∑1(e) Wherein e represents the fifth input optical signal,hrepresenting the eighth input optical signal and,Krepresents the ninth input optical signal, sigma1() Represents a message hashing algorithm first fixed displacement remapping function, S2 represents the first diffracted light signal;

the second diffraction operation is: s1=Ch(e,f,g) Wherein, in the step (A),frepresenting the sixth input optical signal,ga seventh input optical signal is shown,Ch() Representing a selection functionCh(x,y,z)=(x⋀y)⊕(¬x ⋀ z), wherein ⋀ represents a bitwise AND,¬indicating a bitwise negation, S1 indicates the second diffracted light signal;

the third diffraction operation is: t is2=∑0(a)+Maj(a,b,c) Wherein, in the step (A),awhich represents the first input optical signal and the second input optical signal,brepresenting the second path of the input optical signal,crepresents the third pathIncident light signal, Σ0() Representing a message hashing algorithm a second fixed displacement remapping function,Maj() Representing a majority functionMaj(a,b,c)=(x⋀y)⊕(x⋀z)⊕(y⋀z),T2Represents the third diffracted light signal;

the fourth diffraction operation is: t is1= S1+ S2+ W, wherein,Wrepresenting said tenth input optical signal, T1Represents the fourth diffracted light signal;

the fifth diffraction operation is: a = T1+T2ARepresents a fourth diffracted light signal;

the sixth diffraction operation is: e =d+T1Wherein, in the step (A),drepresenting the fourth input optical signal and,Erepresenting the sixth diffracted light signal.

5. The optoelectronic integrated circuit of claim 3, wherein, in each stage of the optical neural network: the first path of input end is connected with the second path of output end through an optical fiber, the second path of input end is connected with the third path of output end through an optical fiber, the third path of input end is connected with the fourth path of output end through an optical fiber, the fifth path of input end is connected with the sixth path of output end through an optical fiber, the sixth path of input end is connected with the seventh path of output end through an optical fiber, and the seventh path of input end is connected with the eighth path of output end through an optical fiber.

6. The optoelectronic integrated circuit according to claim 2, further comprising a first transmission component and a second transmission component, wherein the first transmission component and the second transmission component are disposed between adjacent stages of optical neural networks, the first transmission component is configured to perform signal attenuation on the optical signals output by the output ends to keep the intensities of the optical signals of the respective stages consistent, and the second transmission component is configured to perform signal delay on the optical signals output by the output ends to keep the timings of the optical signals of the respective stages synchronous, wherein the first transmission component comprises a plurality of optical attenuators, and the second transmission component comprises a plurality of optical retarders.

7. The optoelectronic integrated circuit according to claim 6, wherein a third transmission component is integrated on the optoelectronic integrated circuit, and the third transmission component is configured to perform amplitude modulation on the optical signal output by the output terminal of the relay-stage optical neural network, wherein the relay-stage optical neural network is any one of the second to N-1 th stage optical neural networks, and the third transmission component comprises a plurality of optical amplifiers.

8. The optoelectronic integrated circuit according to claim 6, wherein a computing component is further integrated on the optoelectronic integrated circuit, the computing component includes seventh to fourteenth micro-nano optical diffraction line arrays, each micro-nano optical diffraction line array in the computing component includes first to second input ends and an output end, the first to eighth output ends of the nth-order optical neural network and the second input ends of the seventh to fourteenth micro-nano optical diffraction line arrays are correspondingly connected through an optical fiber, the first input end of the seventh to fourteenth micro-nano optical diffraction line array is used for receiving first to eighth initial optical signals input in parallel through a waveguide, and the output optical signals of the first to eighth initial optical signals and the output optical signals of the first to eighth output ends of the nth-order optical neural network are subjected to a third micro-nano optical diffraction pattern through seventh to a fourteenth preset micro-nano optical diffraction line array Seven diffraction operations are carried out to obtain eight paths of final optical signals.

9. The optoelectronic integrated circuit of claim 8, wherein the seventh diffraction operation is: m = N + r, where M is a final optical signal, N is an output optical signal of any one of the first to eighth paths of output ends of the nth-level optical neural network, and r is an initial optical signal of the first to eighth initial optical signals corresponding to any one of the first to eighth paths of output ends of the nth-level optical neural network.

10. The optoelectronic integrated circuit of claim 8, wherein the first transmission component is further disposed between the output of the nth stage optical neural network and the computation component.

Technical Field

The application relates to the technical field of electric digital data processing, in particular to a photoelectric integrated circuit for message compression in a message hash algorithm.

Background

The message Hash Algorithm, also called SHA (Secure Hash Algorithm), can calculate a message digest with a fixed length corresponding to a digital message, and is often applied to digital signature and data integrity check.

Since the message hashing algorithm is usually implemented by software, which causes a risk that an intermediate value may be intercepted, plaintext may be deduced reversely, and the computing rate of the software is low, the message hashing algorithm is implemented by hardware circuits such as an ASIC (Application Specific Integrated Circuit) and a GPU (Graphics Processing Unit) in the related art.

The message hashing algorithm generally needs to perform multiple rounds of operations, each round of operation can be divided into two parts, namely message expansion and message compression, and the power consumption of each round of operation is mainly on the aspect of message compression. However, in the related art, the dynamic flipping power consumption is large when each round of operation of the message hash algorithm is implemented based on a simple circuit, so that the power consumption is large when the message is compressed, and the operation performance is also greatly reduced.

Disclosure of Invention

The application provides a photoelectric integrated circuit for message compression in a message hash algorithm, which aims to solve the problems that the dynamic overturning power consumption is large when each round of operation of the message hash algorithm is realized based on a simple circuit in the related art, the power consumption is large when the message is compressed, the operation performance is reduced and the like.

The embodiment of the application provides a photoelectric integrated circuit for message compression in a message hash algorithm, wherein the photoelectric integrated circuit is integrated with first to nth-stage optical neural networks and a photoelectric detector array, wherein the first to nth-stage optical neural networks are used for performing message compression operation in the message hash algorithm on multiple paths of initial optical signals input in parallel through waveguides in a step-by-step manner from the first to nth stages, and each stage of optical neural network performs message compression operation on messages loaded to the multiple paths of initial optical signals and compresses the messages step by step to final optical signals meeting compression conditions; the photodetector array is used for converting the final optical signal into an electrical signal for carrying a message compression result.

Further, each of the first to nth stages of optical neural networks includes first to tenth input ends and first to eighth output ends, the output ends and the input ends of the first to eighth paths of all adjacent stages of optical neural networks are correspondingly connected through optical fibers, the first to eighth input ends of the first stage of optical neural network are used for receiving first to eighth initial optical signals input in parallel through a waveguide, the ninth input end of each stage of optical neural network is used for receiving a ninth initial optical signal input in parallel through a waveguide, and the tenth input end of each stage of optical neural network is used for receiving a tenth initial optical signal input in parallel through a waveguide.

Further, each level of optical neural network further comprises first to sixth micro-nano optical diffraction line arrays, the first to fourth micro-nano optical diffraction line arrays comprise first to third input ends and output ends, the fifth to sixth micro-nano optical diffraction line arrays comprise first to second input ends and output ends, and in each level of optical neural network: the first input end and the fifth input end of the first micro-nano optical diffraction line array are connected through an optical fiber, the second input end and the eighth input end are connected through an optical fiber, the third input end and the ninth input end are connected through an optical fiber, the output end of the first micro-nano optical diffraction line array is connected with the second input end of the fourth micro-nano optical diffraction line array through an optical fiber, and the first micro-nano optical diffraction line array is used for performing first diffraction operation on a fifth input optical signal, an eighth input optical signal and a ninth input optical signal through a first preset diffraction pattern of the first micro-nano optical diffraction line array and inputting a first diffraction optical signal obtained through diffraction operation to the fourth micro-nano optical diffraction line array; the first input end and the fifth input end of the second micro-nano optical diffraction line array are connected through an optical fiber, the second input end and the sixth input end are connected through an optical fiber, the third input end and the seventh input end are connected through an optical fiber, the output end of the second micro-nano optical diffraction line array is connected with the first input end of the fourth micro-nano optical diffraction line array through an optical fiber, and the second micro-nano optical diffraction line array is used for performing second diffraction operation on a fifth input optical signal, a sixth input optical signal and a seventh input optical signal through a second preset diffraction pattern of the second micro-nano optical diffraction line array and inputting a second diffraction optical signal obtained by diffraction operation into the fourth micro-nano optical diffraction line array; the first input end of a third micro-nano optical diffraction line array is connected with the first input end through an optical fiber, the second input end of the third micro-nano optical diffraction line array is connected with the second input end of the fifth micro-nano optical diffraction line array through an optical fiber, the output end of the third micro-nano optical diffraction line array is connected with the first input end of the fifth micro-nano optical diffraction line array through an optical fiber, and the third micro-nano optical diffraction line array is used for performing third diffraction operation on the first input optical signal, the second input optical signal and the third input optical signal through a third preset diffraction pattern of the third micro-nano optical diffraction line array and inputting the third diffraction optical signal obtained by diffraction operation into the fifth micro-nano optical diffraction line array; the third input end of the fourth micro-nano optical diffraction line array is connected with the tenth input end through optical fibers, the output end of the third micro-nano optical diffraction line array is respectively connected with the second input end of the fifth micro-nano optical diffraction line array and the second input end of the sixth micro-nano optical diffraction line array through optical fibers, and the fourth micro-nano optical diffraction line array is used for performing fourth diffraction operation on the first diffraction light signal, the second diffraction light signal and the tenth input light signal through a fourth preset diffraction pattern of the fourth micro-nano optical diffraction line array and inputting the fourth diffraction light signal obtained by diffraction operation to the fifth micro-nano optical diffraction line array and the sixth micro-nano optical diffraction line array; the output end of the fifth micro-nano optical diffraction line array is connected with the first path of output end, and is used for performing fifth diffraction operation on a third diffraction light signal and a fourth diffraction light signal through a fifth preset diffraction pattern of the fifth micro-nano optical diffraction line array, and inputting a fifth diffraction light signal obtained by the diffraction operation to the first path of output end; the first input end of the sixth micro-nano optical diffraction line array is connected with the fourth input end, the output end of the sixth micro-nano optical diffraction line array is connected with the fifth output end, and the sixth micro-nano optical diffraction line array is used for performing sixth diffraction operation on a fourth diffraction light signal and a fourth input light signal through a sixth preset diffraction pattern of the sixth micro-nano optical diffraction line array, and inputting the sixth diffraction light signal obtained by the diffraction operation to the fifth output end.

Further, the first diffraction operation is: s2= h +K+∑1(e) Wherein e represents the fifth input optical signal,hrepresenting the eighth input optical signal and,Krepresents the ninth input optical signal, sigma1() Represents a message hashing algorithm first fixed displacement remapping function, S2 represents the first diffracted light signal; the second diffraction operation is: s1=Ch(e,f,g) Wherein, in the step (A),frepresenting the sixth input optical signal,ga seventh input optical signal is shown,Ch() Representing a selection functionCh(x,y,z)=(x⋀y)⊕(¬x ⋀ z), wherein ⋀ represents a bitwise AND,¬indicating a bitwise negation, S1 indicates the second diffracted light signal; the third diffraction operation is: t is2=∑0(a)+Maj(a,b,c) Wherein, in the step (A),awhich represents the first input optical signal and the second input optical signal,brepresenting the second path of the input optical signal,crepresents the third input optical signal, sigma0() Representing a message hashing algorithm a second fixed displacement remapping function,Maj() Representing a majority functionMaj(a,b,c)=(x⋀y)⊕(x⋀z)⊕(y⋀z),T2Represents the third diffracted light signal; the fourth diffraction operation is: t is1= S1+ S2+ W, wherein,Wrepresenting said tenth input optical signal, T1Represents the fourth diffracted light signal; the fifth diffraction operation is: a = T1+T2ARepresents a fourth diffracted light signal; the sixth diffraction operation is: e =d+T1Wherein, in the step (A),drepresenting the fourth input optical signal and,Erepresenting the sixth diffracted light signal.

Further, in each stage of the optical neural network: the first path of input end is connected with the second path of output end through an optical fiber, the second path of input end is connected with the third path of output end through an optical fiber, the third path of input end is connected with the fourth path of output end through an optical fiber, the fifth path of input end is connected with the sixth path of output end through an optical fiber, the sixth path of input end is connected with the seventh path of output end through an optical fiber, and the seventh path of input end is connected with the eighth path of output end through an optical fiber.

Optionally, a first transmission component and a second transmission component are further integrated on the optoelectronic integrated circuit, the first transmission component and the second transmission component are disposed between adjacent stages of optical neural networks, the first transmission component is configured to perform signal attenuation on the optical signal output by the output end to keep the intensities of the optical signals of the respective stages consistent, and the second transmission component is configured to perform signal delay on the optical signal output by the output end to keep the timings of the optical signals of the respective stages synchronous, where the first transmission component includes a plurality of optical attenuators, and the second transmission component includes a plurality of optical retarders.

Optionally, a third transmission component is integrated on the optoelectronic integrated circuit, and the third transmission component is configured to perform amplitude adjustment on an optical signal output by an output end of a relay-level optical neural network, where the relay-level optical neural network is any one of second to N-1 th optical neural networks, and the third transmission component includes a plurality of optical amplifiers.

Further, a computing assembly is further integrated on the photoelectric integrated circuit, the computing assembly comprises a seventh micro-nano optical diffraction line array to a fourteenth micro-nano optical diffraction line array, each micro-nano optical diffraction line array in the computing assembly comprises a first input end, a second input end and an output end, the first output end, the second input end, the second output end and the second input end of the seventh micro-nano optical diffraction line array to the fourteenth micro-nano optical diffraction line array are correspondingly connected through optical fibers, the first input end of the seventh micro-nano optical diffraction line array to the first input end, the second input end, the third output end and the fourth output end of the Nth optical diffraction line array are used for receiving first initial optical signals, the second initial optical signals, the eighth initial optical signals and output optical signals of the first output end, the second initial optical diffraction line and the eighth initial optical signals through the seventh preset diffraction pattern, and obtaining eight paths of final optical signals through diffraction operation.

Further, the seventh diffraction operation is: m = N + r, where M is a final optical signal, N is an output optical signal of any one of the first to eighth paths of output ends of the nth-level optical neural network, and r is an initial optical signal of the first to eighth initial optical signals corresponding to any one of the first to eighth paths of output ends of the nth-level optical neural network.

Optionally, the first transmission component is disposed between an output of the nth stage optical neural network and the computation component.

Therefore, the application has at least the following beneficial effects:

the message compression operation of the message hash algorithm is carried out on the message carried by the optical signal through the integrated multistage optical neural network, so that the power consumption during the compression operation can be effectively reduced, the energy efficiency is greatly improved, the operation performance is improved, and compared with a simple circuit, the multi-stage optical neural network has lower power consumption and higher performance. Therefore, the problems that dynamic overturning power consumption is large when each round of operation of a message hash algorithm is realized based on a simple circuit, power consumption is large when messages are compressed, operation performance is reduced and the like in the related technology are solved.

Additional aspects and advantages of the present application will be set forth in part in the description which follows and, in part, will be obvious from the description, or may be learned by practice of the present application.

Drawings

The foregoing and/or additional aspects and advantages of the present application will become apparent and readily appreciated from the following description of the embodiments, taken in conjunction with the accompanying drawings of which:

FIG. 1 is a schematic diagram of an optoelectronic integrated circuit for message compression in a message hashing algorithm according to an embodiment of the present application;

FIG. 2 is a schematic diagram of the optical neural network of FIG. 1, according to an embodiment of the present application;

FIG. 3 is an enlarged view of portion T of FIG. 1 provided in accordance with an embodiment of the present application;

FIG. 4 is a flowchart illustrating an operation of an optical neural network according to an embodiment of the present application;

fig. 5 is a simplified diagram of an optical neural network provided in accordance with one embodiment of the present application.

Detailed Description

Reference will now be made in detail to embodiments of the present application, examples of which are illustrated in the accompanying drawings, wherein like or similar reference numerals refer to the same or similar elements or elements having the same or similar function throughout. The embodiments described below with reference to the drawings are exemplary and intended to be used for explaining the present application and should not be construed as limiting the present application.

Traditional secure hash algorithms are mostly implemented by software, and have the risk that intermediate values may be intercepted, so that plaintext may be deduced reversely, and the calculation rate of the software is low. These disadvantages can be overcome by hardware circuits ASIC and GPU, but as moore's law slows down and even moves to termination, hardware circuits based on traditional integrated circuit processes face performance and energy efficiency bottlenecks. The photoelectric computing technology has the advantages of high performance, low power consumption and the like, and has the potential of solving the bottleneck of computing power and power consumption in the realization of the current secure hash algorithm.

SHA-224, SHA-256, SHA-384 and SHA-512 are called as SHA-2, wherein, the SHA-256 algorithm needs 64 rounds of operation, each round of operation can be divided into two parts of message expansion and message compression, and the power consumption realized by the SHA-256 algorithm is mainly consumed in the message compression and is also a key target needing optimization. However, the existing high throughput SHA-256 algorithm is usually implemented by a full-pipelined hardware circuit based on registers or latches, and the dynamic flipping power consumption is large, so the performance of the hardware circuit based on the conventional integrated circuit process is also limited by the strict requirement of power consumption.

Therefore, the embodiment of the application provides a photoelectric integrated circuit for message compression in a message hash algorithm, and the integrated multistage optical neural network is used for performing message compression operation of the message hash algorithm on a message carried by an optical signal, so that the circuit power consumption during the compression operation can be effectively reduced, the energy utilization efficiency is greatly improved, the operation performance is improved, and compared with a hardware circuit, the photoelectric integrated circuit has lower power consumption and higher performance. Therefore, the problems that in the related art, when each round of operation of a message hash algorithm is realized based on a hardware circuit, the dynamic overturning power consumption is large, the power consumption is large when the message is compressed, the operation performance is reduced and the like are solved.

An optoelectronic integrated circuit for message compression in a message hashing algorithm according to an embodiment of the present application is described below with reference to the drawings.

Specifically, fig. 1 is a schematic structural diagram of an optoelectronic integrated circuit for message compression in a message hashing algorithm according to an embodiment of the present application.

As shown in FIG. 1, the optoelectronic integrated circuit for message compression in the message hashing algorithm is provided with a first-level optical neural network 100-1 to an Nth-level optical neural network 100-N and a photodetector array 200 in an integrated manner.

The first-stage optical neural network 100-1 to the Nth-stage optical neural network 100-N are used for performing message compression operation in a message hash algorithm on a plurality of paths of initial optical signals input in parallel through waveguides from the first stage to the Nth stage step by step, wherein the messages loaded to the plurality of paths of initial optical signals are subjected to message compression operation through each stage of optical neural network and are compressed step by step to final optical signals meeting compression conditions; the photodetector array 200 is used to convert the resulting optical signal into an electrical signal for carrying the message compression results.

It can be understood that the optoelectronic integrated circuit of the embodiment of the present application is designed based on the algorithm characteristics of the message compression function of the neural network algorithm and the message hash algorithm, and the medium for message processing adopts coherent optical signals. The multi-stage optical neural network is used for operation according to the message transmission direction, a plurality of paths of optical signals are input in parallel through waveguides, the multi-stage optical neural network performs step-by-step operation on the input optical signals, each stage of operation realizes one round of operation of a message compression operation function, wherein the optical neural network can be obtained through pre-training during configuration, the output of each stage of optical neural network is input to the next stage of optical neural network, and after the operation of the last stage of optical neural network is completed, the photoelectric detector array 200 converts the output optical signals into electric signals to serve as the output of the photoelectric integrated circuit.

The compression condition may be determined according to the type of the message hash algorithm, and is not particularly limited. Different message hashing algorithms require pipelines with different stages, the message hashing algorithms can comprise SHA-224, SHA-256, SHA-384, SHA-512 and the like, the SHA-224 and the SHA-256 require 64 stages of pipelines, and the SHA-384 and the SHA-512 require 80 stages of pipelines, so that the compression conditions of the SHA-224 and the SHA-256 can be set to stop the compression operation when the number of rounds of the compression operation reaches 64; the compression conditions of SHA-384 and SHA-512 may be set to stop the compression operation when the number of rounds of the compression operation reaches 80.

The first stage of the optical neural network may be understood as a first stage pipeline, and thus the integration number of the optical neural network may be determined according to the type of the message hashing algorithm, for example, N may be 64 or 80, and the like, which is not particularly limited.

In this embodiment, each of the first to nth stages of optical neural networks 100-1 to 100-N includes first to tenth input ends and first to eighth output ends, the output ends and the input ends of the first to eighth paths of all adjacent stages of optical neural networks are correspondingly connected through optical fibers, the first to eighth input ends of the first stage of optical neural network 100-1 are configured to receive first to eighth initial optical signals input in parallel through a waveguide, the ninth input end of each stage of optical neural network is configured to receive a ninth initial optical signal input in parallel through a waveguide, and the tenth input end of each stage of optical neural network is configured to receive a tenth initial optical signal input in parallel through a waveguide.

As shown in fig. 1, the output ends a-H of the first to eighth paths of the adjacent optical neural networks are correspondingly connected to the input ends a-H, taking the first and second optical neural networks as an example, the first output end a of the first optical neural network 100-1 is connected to the first input end a of the second optical neural network, the second output end B of the first optical neural network 100-1 is connected to the second input end B of the second optical neural network, and so on, the eighth output end H of the first optical neural network 100-1 is connected to the eighth input end H of the second optical neural network.

It is understood that the first input end a to the eighth input end H of each stage of the optical neural network are used for receiving parallel input optical signals through the waveguide, wherein the first input end a to the eighth input end H of the first stage of the optical neural network 100-1 are used for receiving parallel input first to eighth initial optical signals through the waveguide, and the first input end a to the eighth input end H of the second to nth stages of the optical neural network 100-N are used for receiving optical signals output by the output ends a-H of the previous stage.

The first to ninth initial optical signals received by the first to ninth input terminals of all the optical neural networks may be constant optical signals or variable optical signals, which is not particularly limited; the tenth initial optical signal received by the tenth input W of all the optical neural networks is an optical signal from message spreading in the message hashing algorithm; taking the first-stage optical neural network 100-1 as an example, the optical signal input by the first-stage optical neural network 100-1 includes, but is not limited to, a constant optical signal generated by a laser and transmitted by a waveguide, a variable optical signal transmitted by other optoelectronic modules, and a variable optical signal generated by a laser and loaded with electrical and digital information by a modulator.

The ninth initial optical signal is taken as a constant optical signal as an example, although a constant value is input at the ninth input terminal of each stage of the neural network, the constant value input at the ninth input terminal of each stage of the neural network is different; the tenth input W of each stage of the neural network receives the variables calculated from the message spreading function, and the variables are different for each stage of the neural network.

The optical signal input by the first-stage optical neural network 100-1 may be a coherent optical signal, and each optical signal of all the optical neural networks can transmit 32-bit (SHA-224, SHA-256) or 64-bit (SHA-384, SHA-512) signals according to the requirements of different message hashing algorithms.

It should be noted that each stage of the optical neural network may input 10 signals and output 8 signals satisfying a certain calculation rule, and the optical neural network may have various implementation manners, and specific implementation types include, but are not limited to, an optical diffraction neural network, an optical interference neural network, and an optical scattering neural network, and may implement message compression of message hash algorithms such as SHA256, SHA224, SHA512, and the like.

In the following embodiments, taking an optical diffraction neural network as an example, the optical diffraction neural network may include at least one micro-nano diffraction line array, for example, the optical diffraction neural network may be implemented by one micro-nano diffraction line array, or may be implemented by connecting twenty micro-nano diffraction line arrays, which is not specifically limited; in the following embodiments, an optical diffraction neural network implemented by connecting six micro-nano diffraction line arrays shown in fig. 2 is taken as an example to describe, where the optical neural network shown in fig. 2 may be used for message compression of the SHA256 algorithm, and in the following embodiments, an example to implement SHA-256 message compression is taken to describe.

In the present embodiment, as shown in fig. 2, in each stage of the optical neural network: the first path of input end a is connected with the second path of output end B through an optical fiber, the second path of input end B is connected with the third path of output end C through an optical fiber, the third path of input end C is connected with the fourth path of output end D through an optical fiber, the fifth path of input end e is connected with the sixth path of output end F through an optical fiber, the sixth path of input end F is connected with the seventh path of output end G through an optical fiber, and the seventh path of input end G is connected with the eighth path of output end H through an optical fiber.

It is understood that the output B, C, D, F, G, H of each stage of pipeline is directly connected to the input optical fibers a, b, c, E, f, and g to obtain optical signals, the outputs a and E are obtained by obtaining corresponding mapping relationships through the trained optical neural network, and the process of obtaining optical signals by the outputs a and E will be described in detail in the following embodiments.

In this embodiment, each optical neural network further includes a first micro-nano optical diffraction line array to a sixth micro-nano optical diffraction line array, the first micro-nano optical diffraction line array to the fourth micro-nano optical diffraction line array include first to third input ends and output ends, and the fifth micro-nano optical diffraction line array to the sixth micro-nano optical diffraction line array include first to second input ends and output ends.

Specifically, the structures of all the optical neural networks in the first-order optical neural network 100-1 to the nth-order optical neural network 100-N shown in fig. 1 may be the same, the structure of any one optical neural network is shown in fig. 2, the optical neural network includes first to sixth micro-nano optical diffraction line arrays 110 to 160, the input ends of the first to fourth micro-nano optical diffraction line arrays 110 to 140 are first to third input ends in fig. 2 from top to bottom, and the input ends of the fifth to sixth micro-nano optical diffraction line arrays 150 to 160 are first and second input ends in fig. 2 from top to bottom.

The type of the first micro-nano optical diffraction line array can be T1S1, the type of the second micro-nano optical diffraction line array can be T1S2, the type of the third micro-nano optical diffraction line array can be T2, the type of the fourth micro-nano optical diffraction line array can be ADD3, and the types of the fifth micro-nano optical diffraction line array and the sixth micro-nano optical diffraction line array can be ADD2, wherein the depth of the boxes representing the micro-nano optical diffraction line arrays in fig. 2 represents the types of the micro-nano optical diffraction line arrays, and the boxes with the same depth represent the same types of the micro-nano optical diffraction line arrays.

In this embodiment, as shown in fig. 2, a first input end of the first micro-nano optical diffraction line array 110 is connected to a fifth input end e through an optical fiber, a second input end of the first micro-nano optical diffraction line array 110 is connected to an eighth input end h through an optical fiber, a third input end of the first micro-nano optical diffraction line array is connected to a ninth input end K through an optical fiber, an output end of the first micro-nano optical diffraction line array 110 is connected to a second input end of the fourth micro-nano optical diffraction line array 140 through an optical fiber, and the first micro-nano optical diffraction line array 110 is configured to perform a first diffraction operation on a fifth input optical signal, an eighth input optical signal, and a ninth input optical signal through a first preset diffraction pattern of the first micro-nano optical diffraction line array 110, and input a first diffraction optical signal obtained by the diffraction operation to the fourth micro-nano optical diffraction line array 140; the first input end of the second micro-nano optical diffraction line array 120 is connected with the fifth input end e through an optical fiber, the second input end is connected with the sixth input end f through an optical fiber, the third input end is connected with the seventh input end g through an optical fiber, the output end of the second micro-nano optical diffraction line array 120 is connected with the first input end of the fourth micro-nano optical diffraction line array 140 through an optical fiber, and the second micro-nano optical diffraction line array 120 is used for performing second diffraction operation on the fifth input optical signal, the sixth input optical signal and the seventh input optical signal through a second preset diffraction pattern of the second micro-nano optical diffraction line array 120 and inputting the second diffraction optical signal obtained by diffraction operation into the fourth micro-nano optical diffraction line array 140; the first input end of the third micro-nano optical diffraction line array 130 is connected with the first input end a through an optical fiber, the second input end of the third micro-nano optical diffraction line array 130 is connected with the second input end b through an optical fiber, the third input end of the third micro-nano optical diffraction line array 130 is connected with the third input end of the fifth micro-nano optical diffraction line array 150 through an optical fiber, the third micro-nano optical diffraction line array 130 is used for performing third diffraction operation on the first input optical signal, the second input optical signal and the third input optical signal through a third preset diffraction pattern of the third micro-nano optical diffraction line array 130, and the diffraction operation is performed to obtain a third diffraction optical signal which is input to the fifth micro-nano optical diffraction line array 150; a third input end of the fourth micro-nano optical diffraction line array 140 is connected with a tenth input end W through an optical fiber, an output end of the third micro-nano optical diffraction line array 130 is respectively connected with a second input end of the fifth micro-nano optical diffraction line array 150 and a second input end of the sixth micro-nano optical diffraction line array 160 through optical fibers, and the fourth micro-nano optical diffraction line array is used for performing fourth diffraction operation on the first diffraction light signal, the second diffraction light signal and the tenth input light signal through a fourth preset diffraction pattern of the fourth micro-nano optical diffraction line array 140 and inputting the fourth diffraction light signal obtained by the diffraction operation to the fifth micro-nano optical diffraction line array 150 and the sixth micro-nano optical diffraction line array 160; the output end of the fifth micro-nano optical diffraction line array 150 is connected with the first output end a, and is used for performing fifth diffraction operation on the third diffraction light signal and the fourth diffraction light signal through a fifth preset diffraction pattern of the fifth micro-nano optical diffraction line array 150, and inputting the fifth diffraction light signal obtained by the diffraction operation to the first output end a; the first input end of the sixth micro-nano optical diffraction line array 160 is connected with the fourth input end, the output end of the sixth micro-nano optical diffraction line array 160 is connected with the fifth output end E, and the sixth micro-nano optical diffraction line array is used for performing sixth diffraction operation on the fourth diffraction light signal and the fourth input light signal through the sixth preset diffraction pattern of the sixth micro-nano optical diffraction line array 160, and inputting the sixth diffraction light signal obtained by the diffraction operation to the fifth output end E.

It should be noted that, in the embodiment of the present application, a corresponding mapping relationship may be implemented through a pre-trained diffractive neural network, a specific diffraction pattern is engraved on a diffraction line of a micro-nano optical diffraction line array, and optical signals input to the first to sixth micro-nano optical diffraction line arrays may be calculated as corresponding specific bit optical signals. Therefore, the first to sixth preset diffraction patterns can be preset according to the mapping relation to be realized, so that the first to sixth micro-nano optical diffraction line arrays can realize respective mapping relations through different diffraction patterns.

Wherein the first diffraction operation is: s2= h +K+∑1(e) Wherein e represents a fifth input optical signal,hrepresenting an eighth path of the input optical signal,Krepresenting the ninth input optical signal, sigma1() Represents a message hashing algorithm first fixed displacement remapping function, S2 represents a first diffracted light signal; the second diffraction operation is: s1=Ch(e,f,g) Wherein, in the step (A),frepresenting a sixth input optical signal and,ga seventh input optical signal is shown,Ch() Representing a selection functionCh(x,y,z)=(x⋀y)⊕(¬x ⋀ z), wherein ⋀ represents a bitwise AND,¬indicating a bitwise negation, S1 indicates a second diffracted light signal; the third diffraction operation is: t is2=∑0(a)+Maj(a, b,c) Wherein, in the step (A),awhich represents the first input optical signal and the second input optical signal,brepresenting a second path of the input optical signal,crepresenting a third input optical signal, sigma0() Representing a message hashing algorithm a second fixed displacement remapping function,Maj() Representing a majority functionMaj(a,b, c)=(x⋀y)⊕(x⋀z)⊕(y⋀z),T2Represents a third diffracted light signal; the fourth diffraction operation is: t is1= S1+ S2+ W, wherein,Wrepresenting the tenth input optical signal, T1Represents a fourth diffracted light signal; the fifth diffraction operation is: a = T1+T2ARepresents a fourth diffracted light signal; the sixth diffraction operation is: e =d+T1Wherein, in the step (A),drepresenting a fourth path of the input optical signal,Erepresenting a sixth diffracted light signal.

Optionally, in this embodiment, a first transmission component and a second transmission component are disposed between adjacent optical neural networks, the first transmission component is configured to perform signal attenuation on the optical signals output by the output end to keep intensities of the optical signals of the respective paths consistent, and the second transmission component is configured to perform signal delay on the optical signals output by the output end to keep timing synchronization of the optical signals of the respective paths, where the first transmission component includes a plurality of optical attenuators and the second transmission component includes a plurality of optical retarders.

It can be understood that the embodiments of the present application may implement strong consistency of light of each optical signal by adding an optical attenuator between each stage of optical neural networks, and implement signal synchronization by adding an optical delayer between each stage of optical neural networks. Wherein, the optical attenuator includes but is not limited to metal, quantum dot, quantum well, direct band gap absorption material, etc.; optical retarders include, but are not limited to, waveguide delay lines, phase modulators, and the like.

It should be noted that, in order to maintain consistent light intensity and signal synchronization of each path, the first transmission component and the second transmission component may be disposed between any required two-stage optical neural networks in the embodiments of the present application, which is not particularly limited. The position of the first transmission component and the second transmission component between the two stages of optical neural networks is not particularly limited, for example, the optical signal output by the output end may pass through the first transmission component and then the second transmission component, or pass through the second transmission component and then the first transmission component. The number of the optical attenuators included in the first transmission component and the number of the optical retarders included in the second transmission component may be specifically set according to actual requirements, for example, as shown in fig. 1, each path is provided with an optical attenuator and an optical retarder; for another example, the optical delay unit and the optical amplifier may not be provided in each path, which is specifically set according to the requirements of keeping the light intensity of each path consistent and synchronizing signals, and this is not particularly limited.

Taking the P-th and P + 1-th optical neural networks shown in fig. 1 as an example (the P + 1-th optical neural network only illustrates an input end in the figure), a first transmission assembly 400 and a second transmission assembly 500 are disposed between the output end of the 100-P-th optical neural network and the input end of the second optical neural network, and the positions of the first transmission assembly 400 and the second transmission assembly 500 can be interchanged without specific limitation. Each path of the pipeline can be provided with an optical attenuator and an optical delayer, wherein the optical attenuator can balance the light field intensity of different paths of each stage of the pipeline, so that each path of output of each stage of the pipeline can keep consistent with the light intensity of other paths of output through the optical attenuator; the optical delayer can balance the time delay of different paths of each stage of assembly line, so that each path of output of each stage of assembly line keeps time sequence synchronization with other paths of output through the optical delayer.

Optionally, in this embodiment, a third transmission component may be further integrated on the optoelectronic integrated circuit, and the third transmission component is configured to perform amplitude adjustment on an optical signal output by an output end of the relay-level optical neural network, where the relay-level optical neural network is any one of the second to N-1 th-level optical neural networks, and the third transmission component may include a plurality of optical amplifiers.

It can be understood that in the embodiment of the present application, an optical amplifier may be further added between the optical neural networks to ensure that the light intensity meets the calculation requirement, and one relay-level optical neural network may be set every several stages of the common pipeline according to different noise margins to ensure the accuracy of the calculation, so that the number of the relay-level optical neural networks may be specifically set, and the third transmission component may be specifically set according to the number of the relay-level optical neural networks.

It should be noted that the relay-stage optical neural network may not only include the optical neural network, the optical attenuator, and the optical delay, but also include an optical amplifier, and the output end of the relay-stage optical neural network may perform amplitude adjustment through the optical amplifier, so as to implement a relay function and ensure the correctness of calculation. The number of the optical amplifiers included in the third transmission component may be specifically set according to actual requirements, for example, an optical amplifier may be disposed in each optical path at the output end of the relay-level optical neural network, or an optical amplifier may not be disposed in each optical path, which is not specifically limited. Optical amplifiers include, but are not limited to, semiconductor photoelectric amplifiers, Er-doped fiber amplifiers, and the like.

Taking the P-th and P + 1-th optical neural networks shown in fig. 1 as examples (the P + 1-th optical neural network only illustrates an input end in the figure), the 100-P-th optical neural network is the relay-level optical neural network, and a third transmission component 600 is disposed between an output end of the 100-P-th optical neural network and an input end of the second-level optical neural network, as shown in fig. 1, the third transmission component 600 may be disposed on an input end of the P + 1-th optical neural network, and a position where the third transmission component 600 is disposed may also be any position between an output end of the 100-P-th optical neural network and an input end of the second-level optical neural network, which is not particularly limited. An optical amplifier can be arranged on each path of optical path of the output end of the relay-level optical neural network, and the optical amplifier relays optical signals after the transmission of the P-level optical neural network (P is more than 0 and less than or equal to N), so that the accuracy of operation is ensured.

Therefore, the optical signal output by the output end of each stage of optical neural network can be directly transmitted through the waveguide or input to the next stage of optical neural network after amplitude and phase modulation is realized through the optical attenuator, the optical delayer and/or the optical amplifier.

Further, in this embodiment, as shown in fig. 1, a computing component 300 is further integrated on the optoelectronic integrated circuit, specifically, as shown in fig. 3, the computing component 300 includes seventh to fourteenth micro-nano optical diffraction line arrays 310 to 380, each micro-nano optical diffraction line array in the computing component 300 includes first to second input ends and an output end, the first to eighth output ends of the nth-order optical neural network 100-N and the second input ends of the seventh to fourteenth micro-nano optical diffraction line arrays are correspondingly connected through an optical fiber, the first input ends of the seventh to fourteenth micro-nano optical diffraction line arrays are configured to receive first to eighth initial optical signals input in parallel through a waveguide, and the first to eighth initial optical signals and the output ends of the first to eighth output ends of the nth-order optical neural network 100-N are respectively output through seventh to fourteenth preset diffraction patterns of the seventh to fourteenth micro-nano optical diffraction line arrays And performing seventh diffraction operation on the outgoing optical signals to obtain eight final optical signals through diffraction operation.

Wherein the seventh diffraction operation is: m = N + r, where M is a final optical signal, N is an output optical signal of any one of the first to eighth paths of the nth-level optical neural network 100-N, and r is an initial optical signal of the first to eighth initial optical signals corresponding to any one of the first to eighth paths of the nth-level optical neural network 100-N. The types of the seventh to fourteenth micro-nano optical diffraction line arrays are ADD2, wherein the depth of the boxes representing the micro-nano optical diffraction line arrays in FIG. 3 represents the types of the micro-nano optical diffraction line arrays, and the boxes with the same depth represent the same types of the micro-nano optical diffraction line arrays.

It can be understood that the nth-level optical neural network 100-N performs operations on optical signals as other levels of optical neural networks to implement message compression cycle operations, and 8 micro-nano optical diffraction line arrays are further connected to the output end to implement addition operations to complete superposition of the calculation results and the initial first to eighth initial optical signals.

Specifically, the method comprises the following steps: as shown in fig. 3, the output ends of the seventh to fourteenth micro-nano optical diffraction line arrays are sequentially connected to the H0 to H7 ends, the H0 to H7 ends are all connected to a photodetector, the input ends of the seventh micro-nano optical diffraction line array 310 to the fourteenth micro-nano optical diffraction line array 380 for receiving constant signals are first input ends, and the input end for receiving optical signals output by the nth-level optical neural network 100-N is a second input end.

A first input end of the seventh micro-nano optical diffraction line array 310 is configured to receive a first initial optical signal, a first input end of the eighth micro-nano optical diffraction line array 320 is configured to receive a second initial optical signal, a first input end of the ninth micro-nano optical diffraction line array 330 is configured to receive a third initial optical signal, a first input end of the tenth micro-nano optical diffraction line array 340 is configured to receive a fourth initial optical signal, a first input end of the eleventh micro-nano optical diffraction line array 350 is configured to receive a fifth initial optical signal, a first input end of the twelfth micro-nano optical diffraction line array 360 is configured to receive a sixth initial optical signal, a first input end of the thirteenth micro-nano optical diffraction line array 370 is configured to receive a seventh initial optical signal, and a first input end of the fourteenth micro-nano optical diffraction line array 380 is configured to receive an eighth initial optical signal. Second input ends of the seventh micro-nano optical diffraction line array 310 to the fourteenth micro-nano optical diffraction line array 380 are correspondingly connected with output ends A-H of the Nth-order optical neural network 100-N, namely a second input end of the seventh micro-nano optical diffraction line array 310 is connected with a first output end A of the Nth-order optical neural network 100-N, a second input end of the eighth micro-nano optical diffraction line array 320 is connected with a second output end B of the Nth-order optical neural network 100-N, and so on, a second input end of the fourteenth micro-nano optical diffraction line array 380 is connected with an eighth output end H of the Nth-order optical neural network 100-N.

Optionally, in this embodiment, a first transmission component may be further disposed between the output end of the nth stage optical neural network 100-N and the computing component 300.

It is understood that, in the embodiment of the present application, whether to set the first transmission component may be selected according to the intensity of the optical signal at the output end of the nth stage optical neural network 100-N, and if the intensity of the optical signal satisfies the setting condition, the first transmission component may be set to keep the light intensities of the respective paths consistent, otherwise, the setting may not be required. When the first transmission component is disposed between the output end of the nth stage optical neural network and the computing component 300, the number of optical attenuators included in the first transmission component may be specifically set according to actual requirements, for example, as shown in fig. 1, each path may be provided with an optical attenuator; for another example, the optical delay device may not be disposed in each path, and is not particularly limited thereto.

It should be noted that the optoelectronic integrated circuit 10 according to the embodiment of the present application can be applied to a general-purpose processor, an FPGA (Field Programmable Gate Array), a blockchain network, and an ASIC.

In summary, the optoelectronic integrated circuit of the embodiment of the present application, which is based on the optical neural network and based on the artificial intelligence algorithm to implement the message compression of the message hash algorithm with high speed and low power consumption, forms the optoelectronic computing architecture by using the integrated optical neural network, the waveguide, the optical amplifier, the optical attenuator, the optical delayer, etc., has lower unit computing energy consumption (FLOPs/J), and compared with a hardware circuit in the related art, the optoelectronic computing architecture can implement higher performance and lower energy consumption, can greatly improve the energy efficiency, and effectively solve the problems of large power consumption and limited performance of the message hash algorithm operation.

The following describes the message compression process of SHA-256 by using a specific embodiment, specifically as follows:

the embodiment of the application can calculate a series of diffraction line arrays with specific length, interval and thickness by optical diffraction propagation, each diffraction line is engraved with a specific diffraction pattern, and input can be calculated into a corresponding specific bit optical signal result. The input of the first to ninth input ends of the first-stage optical neural network is 9 paths of 32-bit constant optical signals generated by a laser and transmitted by a waveguide, and 1 path of 32-bit variable optical signals output from the message extension. The output B, C, D, F, G, H of each stage of optical neural network is obtained by directly connecting the input a, b, c, E, f and g optical fibers, and the outputs A and E are obtained by obtaining the corresponding mapping relation through the trained diffraction neural network. Wherein the content of the first and second substances,

S2=h+K t {256}+∑1 {256}(e),(1)

S1=Ch(e,f,g),(2)

T2=∑0 {256}(a)+Maj(a,b,c),(3)

T1=S1+S2+Wt,(4)

A=T1+T2,(5)

E=d+T1,(6)

wherein the content of the first and second substances,ewhich represents a fifth path of the input optical signal,hrepresenting an eighth path of the input optical signal,K t {256}represents the ninth input optical signal, sigma, of the SHA-256 algorithm in the t-th-stage optical neural network1 {256}() Representing the first fixed displacement remapping function sigma of the SHA-256 algorithm1 {256}(x)=ROTR 6(x)⊕ROTR 11(x)⊕ROTR 25(x) WhereinROTR n Indicating that the loop is shifted to the right by n bits, # is a bitwise xor calculation,trepresents the t-th round iterative function, namely the t-th level optical neural network,1≤t<64and S2 denotes a first diffracted light signal;frepresenting a sixth input optical signal and,ga seventh input optical signal is shown,Ch() Representing a selection functionCh(x,y,z)=(x⋀y)⊕ (¬x ⋀ z), wherein ⋀ represents a bitwise AND,¬indicating a bitwise negation, S1 indicates a second diffracted light signal;awhich represents the first input optical signal and the second input optical signal,brepresenting a second path of the input optical signal,crepresenting a third input optical signal, sigma0 {256}() Second fixed displacement remapping function sigma representing SHA-256 algorithm0 {256}() Second fixed displacement remapping function sigma representing SHA-256 algorithm0 {256}( )= ROTR 2(x)⊕ROTR 13(x)⊕ROTR 22(x),Maj() Representing a majority functionMaj(a,b,c)=(x⋀y)⊕(x⋀z)⊕(y⋀z),T2Represents a third diffracted light signal; wtRepresents the tenth input optical signal, T, of the SHA-256 algorithm in the T-th optical neural network1Represents a fourth diffracted light signal;Arepresents a fourth diffracted light signal;drepresenting a fourth path of the input optical signal,Erepresenting a sixth diffracted light signal.

In the embodiment of the present application, taking the first optical neural network as an example, the input of the micro-nano optical diffraction line array is limited to the highest 96 bits, and then the optical neural network for calculating a and E can be disassembled into a plurality of micro-nano optical diffraction line arrays as shown in fig. 4, which is one solution for implementing a mapping relationship, and after the disassembly, a simplified optical neural network schematic diagram as shown in fig. 5 can be obtained.

For example, in fig. 4 and 5, the first micro-nano optical diffraction line array 110 implements the mapping relationship of formula (1) through a pre-trained diffractive neural network, the second micro-nano optical diffraction line array 120 implements the mapping relationship of formula (2) through a pre-trained diffractive neural network, the third micro-nano optical diffraction line array 130 implements the mapping relationship of formula (3) through a pre-trained diffractive neural network, the fourth micro-nano optical diffraction line array 140 implements the mapping relationship of formula (4) through a pre-trained diffractive neural network, the fifth micro-nano optical diffraction line array 150 implements the mapping relationship of formula (5) through a pre-trained diffractive neural network, and the sixth micro-nano optical diffraction line array 160 implements the mapping relationship of formula (6) through a pre-trained diffractive neural network; the diffraction lines of the micro-nano optical diffraction line array are engraved with specific diffraction patterns, and input can be calculated into corresponding specific bit optical signal results. The mapping relation of the formula (3) is realized by obtaining 32-bit output through 96-bit input by the diffractive neural network of the third micro-nano optical diffraction line array 130, and the mapping relations of the diffractive neural networks of the first micro-nano optical diffraction line array 110, the second micro-nano optical diffraction line array 120, the fourth micro-nano optical diffraction line array 140, the fifth micro-nano optical diffraction line array 150 and the sixth micro-nano optical diffraction line array 160 are realized through different diffraction patterns. After the nth-level optical neural network 100-N completes message compression calculation, superposition of the calculation result and the initial first to eighth initial optical signals is achieved through 8 ADD 2-type micro-nano optical diffraction line arrays (namely seventh to fourteenth micro-nano optical diffraction line arrays). The photodetector array converts the output coherent optical signal into an electrical signal as the output of the optoelectronic integrated circuit.

According to the photoelectric integrated circuit for compressing the message in the message hash algorithm, the message compression operation of the message hash algorithm is carried out on the message carried by the optical signal through the integrated multi-stage optical neural network, so that the power consumption during the compression operation can be effectively reduced, the energy efficiency is greatly improved, the operation performance is improved, and compared with a simple circuit, the photoelectric integrated circuit has lower power consumption and higher performance.

In the description herein, reference to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., means that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the application. In this specification, the schematic representations of the terms used above are not necessarily intended to refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or N embodiments or examples. Furthermore, various embodiments or examples and features of different embodiments or examples described in this specification can be combined and combined by one skilled in the art without contradiction.

Furthermore, the terms "first", "second" and "first" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one such feature. In the description of the present application, "N" means at least two, e.g., two, three, etc., unless specifically limited otherwise.

Although embodiments of the present application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present application, and that variations, modifications, substitutions and alterations may be made to the above embodiments by those of ordinary skill in the art within the scope of the present application.

19页详细技术资料下载
上一篇:一种医用注射器针头装配设备
下一篇:一种电流输出型函数信号发生器

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!