This application is based upon and claims the benefit of priority from Japanese Patent Application No. 2022-149292, filed Sep. 20, 2022, the entire contents of which are incorporated herein by reference.
Embodiments described herein relate generally to a quantum circuit learning system, a quantum circuit learning method, a quantum inference system, a quantum circuit, and a quantum-classical hybrid neural network.
In recent years, the development of gate-type quantum computers has progressed significantly, and quantum computing using quantum properties can be implemented by various methods although it is on a small scale. These quantum computers are called noisy intermediate-scale quantum (NISQ) devices, and are regarded as an important first step of a milestone for a quantum computer implementing future error correction. Research utilizing NISQ is currently actively conducted, and in particular, an algorithm called variational quantum eigensolver (VQE) (see Non-Patent Literature 1 (A. Peruzzo, J. McClean, P. Shadbolt, M.-H. Yung, X.-Q. Zhou, P. J. Love, A. Aspuru-Guzik, and J. L. O'Brien, “A variational eigenvalue solver on a photonic quantum processor,” Nature Communications, 5, article number: 4213, 2014.)) is expected to be applied to quantum chemistry computing as a method of hybridizing and utilizing a quantum computer and a classical computer. However, there are many problems in implementing the VQE for practical problems such as drug discovery and material development. Specifically, in order to obtain a highly accurate result with the VQE, it is necessary to alternately perform measurement sampling in an NISQ device and a classical computer a large number of times. Therefore, currently, various proposals have been made to reduce the calculation cost by reducing the number of measurements, improving error mitigation, and the like.
In a series of studies for reducing the calculation cost of the VQE, in 2020, Xia & Kais et al. proposed a quantum-classical hybrid neural network disclosed in Non-Patent Literature 2 (R. Xia and S. Kais, “Hybrid Quantum-Classical Neural Network for Calculating Ground State Energies of Molecules” Entropy 22, 828 (2020)) that enables estimation of a ground-state potential energy surface (PES) of a small molecule with high accuracy. Their method is a method of configuring a surrogate model of the VQE that substitutes a conventional VQE calculation procedure with a neural network using a quantum circuit. According to the proposed method, variational optimization for each molecular structure, which has been conventionally required in the calculation of the PES using the VQE, is unnecessary. Therefore, the calculation cost can be reduced, and a highly accurate PES estimation value can be obtained on the NISQ device. However, in the method disclosed in Non-Patent Literature 2, since a parameterized quantum circuit having too high expressive power is used to solve the task of quantum chemistry computing, it is reported that highly accurate inference is possible in the simple two-molecule system disclosed in Non-Patent Literature 2, but the inference accuracy decreases in a case where the number of molecules or the number of qubits increases. Although it is necessary to sufficiently lower the cost function in order to increase the accuracy of inferring the energy of an H3 molecule by the method of Non-Patent Literature 2, this requires many iterative calculations, and as a result, the calculation method is not efficient, and it is difficult to use the method for a practical molecule.
A quantum circuit learning system according to an embodiment includes a quantum computing unit and a learning control unit. The quantum computing unit applies input information to a quantum circuit that performs a quantum gate operation on a plurality of qubits to acquire output information corresponding to the input information. The learning control unit updates a learning parameter of the quantum circuit based on a difference between the output information and ground truth information. The quantum circuit includes a first block circuit and a second block circuit concatenated to the first block circuit. The first block circuit includes: a first gate operation layer including a first encoding gate that is a quantum gate parameterized with a first encoding parameter in which the input information is encoded and which is for constructing a first Hartree-Fock state, and a first transformation gate that is a quantum gate parameterized with the learning parameter for transforming the first Hartree-Fock state into a first quantum state; and a measurement layer that outputs a measured value of the first quantum state. The second block circuit includes: a second gate operation layer including a second encoding gate parameterized with a second encoding parameter in which the measured value is encoded and which is for constructing a second Hartree-Fock state, and a second transformation gate parameterized with the learning parameter for transforming the second Hartree-Fock state into a second quantum state; and an output layer that outputs the second quantum state as the output information.
Hereinafter, a quantum circuit learning system, a quantum circuit learning method, a quantum inference system, a quantum circuit, and a quantum-classical hybrid neural network according to the present embodiment will be described with reference to the drawings.
The classical computer 100 is a computer that processes binary classical bits. The classical computer 100 is a computer including a processing circuit 110, a storage device 120, an input device 130, a communication device 140, and a display device 150. Information communication is performed between the processing circuit 110, the storage device 120, the input device 130, the communication device 140, and the display device 150 via a bus. Note that the storage device 120, the input device 130, the communication device 140, and the display device 150 are not essential components, and can be omitted as appropriate.
The processing circuit 110 includes a processor such as a central processing unit (CPU) and a memory such as a random access memory (RAM). The processing circuit 110 includes a learning control unit 111 and a display control unit 112. The processing circuit 110 implements each function of each of the units 111 and 112 by executing a quantum circuit learning program. The quantum circuit learning program is stored in a non-transitory computer-readable recording medium such as the storage device 120. The quantum circuit learning program may be implemented as a single program that describes all the functions of the units 111 and 112 described above, or may be implemented as a plurality of modules divided into several functional units. Each of the units 111 and 112 may be implemented by an integrated circuit such as an application specific integrated circuit (ASIC)) or a field programmable gate array (FPGA). In this case, the units 111 to 114 may be mounted on a single integrated circuit, or may be individually mounted on a plurality of integrated circuits.
The learning control unit 111 controls quantum circuit learning for a quantum circuit 210 implemented in the quantum computer 200. Specifically, the learning control unit 111 acquires learning information. The learning information includes a plurality of learning samples. Each learning sample includes input information and ground truth information corresponding to the input information. The learning control unit 111 provides the input information to the quantum circuit 210. The input information is transformed into output information by the quantum circuit 210. The learning control unit 111 updates a circuit parameter of the quantum circuit 210 based on a difference between the output information and the ground truth information. The learning control unit 111 performs the update processing until a stop condition is satisfied. When the stop condition is satisfied, the learning control unit 111 determines the circuit parameter. Thus, the quantum circuit 210 is completed. Note that the circuit parameter is an example of a parameter for controlling a quantum gate included in the quantum circuit 210. In the present embodiment, the circuit parameter to be updated is referred to as a learning parameter.
The display control unit 112 causes the display device 150 to display various types of information. For example, the display control unit 112 displays the input information, the output information, the ground truth information, and the like.
The storage device 120 includes a read only memory (ROM), a hard disk drive (HDD), a solid state drive (SSD), an integrated circuit storage device, or the like. The storage device 120 stores the quantum circuit learning program and the like.
The input device 130 inputs various commands from an operator. As the input device 130, a keyboard, a mouse, various switches, a touch pad, a touch panel display, and the like can be used. An output signal from the input device 130 is supplied to the processing circuit 110. Various commands from the operator may be input not by the input device 130 included in the classical computer 100 but by an input device provided in another classical computer connected via the communication device 140.
The communication device 140 is an interface for performing information communication with an external device such as the quantum computer 200 connected to the classical computer 100 by wire or wirelessly.
The display device 150 displays various types of information under control by the display control unit 112. As the display device 150, a cathode-ray tube (CRT) display, a liquid crystal display, an organic electroluminescence (EL) display, a light-emitting diode (LED) display, a plasma display, or any other display known in the art can be appropriately used. Furthermore, the display device 150 may be a projector.
The quantum computer 200 is a computer that has the quantum circuit 210 implemented therein that performs a quantum gate operation on a plurality of qubits, and performs quantum computing using the quantum circuit 210. As a method of implementing a qubit and a quantum gate by the quantum circuit 210, any method such as a superconducting circuit method, an ion trap method, a quantum dot method, or an optical lattice method may be used. It is assumed that the quantum computer 200 has various types of hardware for implementing an environment according to the method of implementing a qubit and a quantum gate. Although not illustrated in
The quantum computer 200 receives the input information from the classical computer 100, and inputs the input information to the quantum circuit 210 that performs a quantum gate operation on a plurality of qubits. The quantum circuit 210 transforms the input information into the output information. The quantum computer 200 acquires the output information from the quantum circuit 210. The quantum computer 200 transmits the acquired output information to the classical computer 100.
As illustrated in
It can be said that the quantum circuit 210 is a quantum-classical hybrid neural network having a repetitive structure of block circuits each including a quantum circuit in which quantum information is subjected to processing items related to a Hartree-Fock state, a parameterized quantum circuit, and a measurement layer in this order. Specifically, as illustrated in
The second block circuit 230 includes a second gate operation layer 231 and an output layer 232. The second gate operation layer 231 has a sequence of second encoding gates 233 and a sequence of second transformation gates 234. Each of the second encoding gates 233 is a quantum gate parameterized with a second encoding parameter 235 in which the measured value 260 output by the measurement layer 222 is encoded and which is for constructing a second Hartree-Fock state. The second encoding parameter 235 is a circuit parameter, but is not a parameter to be updated by quantum circuit learning. The second encoding parameter 235 is set to a value corresponding to the measured value 260. Each of the second transformation gates 234 is a quantum gate parameterized with a second learning parameter 236 for transforming the second Hartree-Fock state into a second quantum state. The output layer 232 outputs the second quantum state as the output information 250. As the output information 250, a trial wave function represented by the second quantum state is output. Note that the first gate operation layer 221 and the second gate operation layer 231 may have the same quantum gate configuration or different quantum gate configurations.
As described above, the first block circuit 220 and the second block circuit 230 are connected to each other via the measured value 260 obtained by the measurement layer 222. With the above configuration, the second encoding gates 233 can encode the quantum state (Hartree-Fock state) represented by the measured value 260 into the qubits. Each of the first gate operation layer 221 and the second gate operation layer 231 is implemented by a particle preserving circuit called an A gate. The particle preserving circuit is an ansatz that preserves the number of particles between the input quantum state and the output quantum state. That is, each of the first gate operation layer 221 and the second gate operation layer 231 performs the quantum gate operation with the transformation gates controlled by the learning parameter while preserving the number of particles for the input Hartree-Fock state.
By adopting this configuration, the quantum circuit 210 can have a circuit configuration specialized for quantum chemistry computing with the Hartree-Fock state as an initial input, as compared with Non-Patent Literature 2 having high versatility. As a result, it is possible to improve convergence in a system having a large number of atoms, to apply the system to an actual practical system, to reduce the number of circuit parameters, and to reduce the calculation cost of quantum circuit learning associated therewith.
Next, the quantum circuit 210 will be described in detail.
The first block circuit 220 includes the parameterized quantum circuit (SYMP) 221 and the measurement layer 222. The SYMP 221 includes the sequence of quantum gates that construct the first Hartree-Fock state and the sequence of transformation gates that transform the first Hartree-Fock state into the first quantum state. The encoding gates and the transformation gates are implemented by rotation gates that perform a quantum gate operation of rotating a quantum state around a predetermined axis by an angle θ. Each of the rotation gates is controlled by a rotation angle parameter θ which is an example of a circuit parameter.
In the example of
The second block circuit 230 is provided at a subsequent stage of the first block circuit 220 with an initialization layer 270 interposed therebetween. The initialization layer 270 includes a quantum gate that initializes all the qubits qrk to a quantum state |0>. In the example illustrated in
The second block circuit 230 includes the parameterized quantum circuit (SYMP) 231 and the output layer. The SYMP 231 includes the sequence of quantum gates that construct the second Hartree-Fock state and the sequence of transformation gates that transform the second Hartree-Fock state into the second quantum state. The encoding gates and the transformation gates are controlled by the rotation angle parameters θ. In the example illustrated in
Hereinafter, in a case where the SYMP 221 and the SYMP 231 are not particularly distinguished, each of the SYMP 221 and the SYMP 232 are simply referred to as an SYMP.
More generally, when n qubits are prepared, the number of parameters included in each SYMP block is (n−1)m. In general, the SYMP formed by preparing n qubits and repeating the particle preserving circuit 281, 282, and 283 illustrated in
SYMP=A(θ0)A(θ1)A(θ2) . . . A(θ(n−1)m−1) (1)
At least one encoding parameter included in the SYMP is a part of rotation angle parameters θ0 to θn-1 in Equation (1). As an example, the encoding parameter can be θ0 of A(θ0) in the above Equation (1). The remaining rotation angle parameters such as θ1 and θ2 are set as learning parameters. Any rotation angle parameter among the n rotation angle parameters θ0 to θn-1 may be selected as the encoding parameter, and the number of encoding parameters can also be changed according to the degree of freedom of the calculation target. The number No of remaining total rotation angle parameters included in the SYMP is (n−1)m−Ne, where Ne is the number of encoding parameters. That is, the number of learning parameters for constructing a quantum state from a Hartree-Fock state included in the SYMP is No.
As illustrated in
In each of the first block circuit 220 and the second block circuit 230, the rotation angle parameters included in the SYMP (gate operation layer) are divided into an encoding parameter and a learning parameter according to the above rule. Values of the rotation angle parameters are determined by quantum circuit learning. The encoding parameter of the first block circuit 220 is set to the molecular structure parameter itself that is the input information or to a value based on the molecular structure parameter. The encoding parameter of the second block circuit 230 is set to the measured value itself measured by the measurement layer 222 or to a value based on the measured value.
In the measurement layer 222, Ne encoding parameters are measured. The measurement layer 222 uses a quantum state transformed from a Hartree-Fock state to perform processing of outputting, as a measured value, an expected value of an observable configured by an arbitrary tensor product of Pauli operations I, X, Y, and Z in the n qubits for the quantum state. As an example, when Ne=1 in
The quantum circuit 210 calculates ground-state energy for an arbitrary system of the calculation target based on learning information of some systems of the calculation target. The precondition will be described below.
The quantum computer performs quantum computing based on a quantum circuit U(θ) including a unitary operator. The parameter θ is a generally N-dimensional vector representing the quantum circuit. In the case of n qubits, the quantum circuit U(θ) and the quantum state ψ(θ) are associated with each other by the following
If the Hamiltonian H of the calculation target is given, the expected value E(θ) can be calculated according to the following Equation (3) using the quantum state |ψ(θ)>.
E(θ)=<ψ(θ)|H|ψ(θ)> (3)
The VQE described in Non-Patent Literature 1 is an algorithm that minimizes an expected value E(θ) obtained using a quantum computer with respect to θ.
The quantum-classical hybrid neural network is a surrogate model of the VQE, prepares a calculation target and a part of its Hamiltonian as D={Xi, Hi} (the subscript i represents a number of a learning sample), and executes an algorithm for minimizing a cost function f expressed by the following Equation (4) using D as a learning sample.
The Hamiltonian H is given in a second quantization display in which the state “0” of the qubit is regarded as an unoccupied orbit, the state “1” of the qubit is regarded as an occupied orbit, and the quantum state is expressed by the occupied state of the spin orbit. However, it is not possible to calculate the Hamiltonian by the second quantization on the quantum circuit, and the Hamiltonian is transformed into a qubit Hamiltonian in which creation and annihilation operators are rewritten with a linear combination of the Pauli operators. As a representative transformation method, there is a Jordan-Wigner transformation [Jordan and Wigner (1928)], and some other transformation methods (Bravi and Kitaev (2005); Seeley and Love (2012)) are known. By using these transformation methods, the Hamiltonian is given by a tensor product of any weighted Pauli operators expressed by the following Equation (5).
In Equation (5), σlϵ{I, X, Y, Z}, and I, X, Y, and Z are an identity operator and Pauli operators of X, Y, and Z components, respectively. At the time of learning of the quantum-classical hybrid neural network, the input value Xi of the learning sample D={Xi, Hi} is classical data, and needs to be encoded into a quantum state that can be processed by the quantum circuit, similarly to the Hamiltonian expressed by Equation (5).
In general, in the case of n qubits, the encoding of the input value Xi which is classical data can be expressed by a gate operation of the following Equation (6). Here, i is a number of a qubit, fi is an arbitrary classical function acting on the i-th qubit, and gi is an arbitrary single qubit gate having a result output from fi as a parameter.
G=⊗
i=0
n-1
g
i(fi(Xi)) (6)
The initial quantum state function |ψencoded> expressed using the following Equation (7) can be configured by preparing the initial state and performing encoding expressed in Equation (4).
s′
x
new
=αs
x+(1−α)s′xold (7)
The quantum state is obtained as |ψ(θ)>=U(θ)|ψencoded> by causing the quantum circuit U(θ) to act on the initial quantum state function |ψencoded>.
The cost function f expressed by Equation (4) can be calculated from the learning sample D={Xi, Hi} by the procedure using Equations (5) and (6) described above.
In a quantum-classical hybrid neural network applied to a two-atom molecular system represented by a hydrogen molecule, fi=I and gi=RyH are used, and a bond distance between two atoms is used as Xi. In such a quantum-classical hybrid neural network, a real-amplitude 2-local type including a Ry gate and a CNOT gate is used for the quantum circuit U(θ), and a quantum circuit including a measurement layer interposed is configured in order to give nonlinearity to the quantum circuit including the unitary operator.
In the quantum-classical hybrid neural network described above, the expected value of the Pauli operator of the Z component obtained using the quantum state ψ(θ) is measured, a new initial quantum state |ψ′encoded>=G′|ψ$(θ)> obtained from G′ obtained by substituting the measured value into Xi of Equation (6) and the quantum state ψ(θ) is configured, a quantum state |ψ′(θ′)>=U(θ′)|ψ′encoded> is newly configured from |ψ′encoded> and U(θ′), and the cost function f expressed by Equation (4) is calculated using |ψ′(θ′)>, thereby configuring the quantum circuit including the measurement layer interposed.
For example, in a quantum-classical hybrid neural network applied to a diatomic molecular system represented by a hydrogen molecule, the learning sample D={Xi, Hi} is prepared, U(θ) and U(θ′) and ψ(θ) and ψ(θ′) are configured by the above procedure, and learning for minimizing the cost function f expressed by Equation (4) is performed on θ and θ′, thereby estimating energy of a hydrogen molecule with an arbitrary interatomic distance and calculating a potential energy surface of the hydrogen molecule.
Next, quantum circuit learning processing by the quantum circuit learning system 1 will be described.
After step S601 is performed, the quantum computer 200 applies the input information provided in step S601 to the quantum circuit 210 and outputs output information (step S602). The first encoding parameter for controlling the first encoding gates of the first block circuit included in the quantum circuit 210 is set to a value based on the input information provided in step S601. The first and second learning parameters for controlling the first conversion gates and the second conversion gates of the first block circuit and the second block circuit included in the quantum circuit 210 are set to arbitrary initial values. The first gate operation layer performs a quantum gate operation on the qubits by using the first encoding gates parameterized with the first encoding parameter, thereby encoding the input information into the qubits, and constructing the first Hartree-Fock state. The first gate operation layer constructs the first quantum state by performing a quantum gate operation on the first Hartree-Fock state by using the first transformation gates parameterized with the first learning parameter. The measurement layer outputs an expected value of an observable for the first quantum state as a measured value. As the expected value of the observable, for example, an expected value of the Hamiltonian is measured.
The quantum computer 200 sets the measured value output from the measurement layer to the value of the second encoding parameter for controlling the second encoding gates of the second block circuit. The second gate operation layer performs a quantum gate operation on the qubits initialized by the initialization layer by using the second encoding gates parameterized with the second encoding parameter, thereby encoding the measured value into the qubits and constructing the second Hartree-Fock state. The second gate operation layer constructs the second quantum state by performing a quantum gate operation on the second Hartree-Fock state by using the second transformation gates parameterized with the second learning parameter. The output layer outputs the second quantum state as a trial wave function. The trial wave function is output as the output information.
After step S602 is performed, the classical computer 100 updates the learning parameter of the quantum circuit 210 based on a difference between the output information output in step S602 and ground truth information corresponding to the input information provided in step S601 (step S603). Specifically, in step S603, the learning control unit 111 updates the learning parameter using a cost function that evaluates the difference between the output information and the ground truth information. Specifically, the learning control unit 111 calculates the cost function based on the output information and the ground truth information. The cost function is defined by a sum of expected values of the Hamiltonian for the second quantum state for the number of samples of the input information. The learning control unit 111 updates the learning parameter according to a predetermined optimization method so as to reduce the cost function. As a result, the first learning parameter 226 and the second learning parameter 236 are updated so that the quantum circuit 210 constructs the accurate output information (trial wave function) 250 from the input information (molecular structure parameter) 240.
As the optimization method, the Nelder-Mead method, the Powell method, the CG method, the Newton method, the BFGS method, the L-BFGS-B method, the TNC method, the COBYLA method, and/or the SLSQP method, or any other optimization method can be used. The ground truth information is high-accuracy output information calculated based on the corresponding input information. As the ground truth information, for example, it is preferable to use an exact solution calculated by the classical computer based on the input information according to an arbitrary high-accuracy algorithm such as a full configuration interaction method (FCI) method or a complete active space CI (CASCI) method. Alternatively, an experimental result for the input information may be used as the ground truth information.
After step S603 is performed, the classical computer 100 determines whether or not to end the learning parameter update processing (step S604). Specifically, the learning control unit 111 of the classical computer 100 determines whether or not a stop condition for stopping the update processing is satisfied. The stop condition can be set to any condition such as a condition that the number of iterations of steps S601 to S604 has reached a predetermined number of times or that the function value of the cost function has reached a threshold. When the learning control unit 111 determines that the stop condition is not satisfied, that is, when the learning control unit 111 determines that the update processing is not to be ended (step S604: NO), steps S601 to S604 are repeated for another sample.
When the learning control unit 111 determines that the stop condition is satisfied, that is, when the learning control unit 111 determines to end the learning parameter update processing (step S604: YES), the classical computer 100 determines the learning parameter (step S605). The quantum circuit 210 in which the determined learning parameter is set is implemented as a learned quantum circuit in the quantum inference system to be described later.
As a result, the quantum circuit learning processing by the quantum circuit learning system 1 ends.
The quantum circuit learning system 1 is an example, and a change, addition, and/or removal can be appropriately made in the quantum circuit learning system 1 without departing from the gist of the invention. As an example, as illustrated in
As another example, in
The classical computer 300 is a computer that processes binary classical bits. The classical computer 300 is a computer including a processing circuit 310, a storage device 320, an input device 330, a communication device 340, and a display device 350. Information communication is performed between the processing circuit 310, the storage device 320, the input device 330, the communication device 340, and the display device 350 via a bus.
The processing circuit 310 includes a processor such as a CPU and a memory such as a RAM. The processing circuit 310 includes an inference unit 311 and a display control unit 312. The processing circuit 310 executes a quantum inference program to implement each function of the units 311 and 312 described above. The quantum inference program is stored in a non-transitory computer-readable recording medium such as the storage device 320. The quantum circuit learning program may be implemented as a single program that describes all the functions of the units 311 and 312 described above, or may be implemented as a plurality of modules divided into several functional units. Each of the units 311 and 312 may be implemented by an integrated circuit such as an ASIC or an FPGA. In this case, the units 111 to 114 may be mounted on a single integrated circuit, or may be individually mounted on a plurality of integrated circuits.
The inference unit 311 controls quantum inference processing using a learned quantum circuit 410 implemented in the quantum computer 400. Specifically, the inference unit 311 acquires input information to be processed. The inference unit 311 provides the input information to be processed to the learned quantum circuit 410. The input information is transformed into inference result information by the learned quantum circuit 410. The inference result information is output information constructed by the learned quantum circuit 410.
The display control unit 312 displays various types of information on the display device 350. For example, the display control unit 312 displays the input information, the inference result information, and the like.
The storage device 320 includes a ROM, an HDD, an SSD, an integrated circuit storage device, or the like. The storage device 320 stores the quantum inference program and the like.
The input device 330 inputs various commands from an operator. As the input device 330, a keyboard, a mouse, various switches, a touch pad, a touch panel display, and the like can be used. An output signal from the input device 330 is supplied to the processing circuit 310. Various commands from the operator may be input not by the input device 330 included in the classical computer 300 but by an input device provided in another classical computer connected via the communication device 340.
The communication device 340 is an interface for performing information communication with an external device such as the quantum computer 400 connected to the classical computer 300 by wire or wirelessly.
The display device 350 displays various types of information under control by the display control unit 312. As the display device 350, a CRT display, a liquid crystal display, an organic EL display, an LED display, a plasma display, or any other display known in the art can be appropriately used. Furthermore, the display device 350 may be a projector.
The quantum computer 400 is a computer that has the learned quantum circuit 410 implemented therein that performs a quantum gate operation on a plurality of qubits and performs quantum computing using the learned quantum circuit 410. The learned quantum circuit 410 is the quantum circuit 210 trained by the quantum circuit learning system 1. That is, the learning parameter determined in step S605 in
The quantum computer 400 receives the input information to be processed from the classical computer 300, and inputs the input information to the learned quantum circuit 410 that performs a quantum gate operation on a plurality of qubits. The learned quantum circuit 410 transforms the input information into inference result information. The quantum computer 400 acquires the inference result information from the learned quantum circuit 410. The quantum computer 400 transmits the acquired inference result information to the classical computer 300. A hardware configuration of the quantum computer 400 is similar to that of the quantum computer 200 of the quantum circuit learning system 1.
After step S801 is performed, the quantum computer 400 applies the input information provided in step S801 to the learned quantum circuit 410 and outputs inference result information (step S802). The first encoding parameter for controlling the first encoding gates of the first block circuit included in the learned quantum circuit 410 is set to a value based on the input information provided in step S801. The first and second learning parameters for controlling the first transformation gates and the second transformation gates of the first block circuit and the second block circuit included in the learned quantum circuit 410 are set to the first learning parameter (hereinafter, a first determined parameter) and the second learning parameter (hereinafter, a second determined parameter) determined in step S605, respectively. The first gate operation layer performs a quantum gate operation on the qubits by using the first encoding gates parameterized with the first encoding parameter, thereby encoding the qubits into the input information and constructing the first Hartree-Fock state. The first gate operation layer constructs the first quantum state by performing a quantum gate operation on the first Hartree-Fock state by using the first transformation gates parameterized with the first determined parameter. The measurement layer outputs an expected value of an observable for the first quantum state as a measured value.
The quantum computer 400 sets the measured value output from the measurement layer to the value of the second encoding parameter that controls the second encoding gates of the second block circuit. The second gate operation layer performs a quantum gate operation on the qubits initialized by the initialization layer by using the second encoding gates parameterized with the second encoding parameter, thereby encoding the measured value into the qubits and constructing the second Hartree-Fock state. The second gate operation layer constructs the second quantum state by performing a quantum gate operation on the second Hartree-Fock state by using the second transform gates parameterized with the second determined parameter. The output layer outputs the second quantum state as a trial wave function. The trial wave function is output as the inference result information.
After step S802 is performed, the classical computer 300 displays the inference result information (step S803). Furthermore, the classical computer 300 may calculate secondary information such as potential energy and a Hellmann Feynman force based on the inference result information. The inference result information and the secondary information are displayed in a predetermined layout on the display device 350.
As a result, the quantum inference processing by the quantum inference system 7 ends.
The quantum inference system 7 is an example, and a change, addition, and/or removal can be appropriately made in the quantum inference system 7 without departing from the gist of the invention. As an example, as illustrated in
Hereinafter, examples of the quantum chemistry computing according to the present embodiment will be described.
A processing target molecule according to Example 1 is an H2 molecule. Numerical simulation was performed using the electron Hamiltonian of the H2 molecule. In Example 1, the Hamiltonian was calculated using existing open source libraries PySCF (see Reference 1 (Q. Sun, T. C. Berkelbach, N. S. Blunt, G. H. Booth, S. Guo, Z. Li, J. Liu, J. D. McClain, E. R. Sayfutyarova, S. Sharma, S. Wouters, and G. K. Chan, Wiley Interdisciplinary Reviews: Computational Molecular Science 8, e1340 (2017))) and OpenFermion (see Reference 2 (J. R. McClean, K. J. Sung, I. D. Kivlichan, Y. Cao, C. Dai, E. S. Fried, C. Gidney, B. Gimby, P. Gokhale, T. Hner, T. Hardikar, V. Havlek, O. Higgott, C. Huang, J. Izaac, Z. Jiang, X. Liu, S. McArdle, M. Neeley, T. O'Brien, B. O'Gorman, I. Ozdan, M. D. Radin, J. Romero, N. Rubin, N. P. D. Sawaya, K. Setia, S. Sim, D. S. Steiger, M. Steudtner, Q. Sun, W. Sun, D. Wang, F. Zhang, and R. Babbush, (2017), arXiv: 1710.07629.). The simulation of the quantum circuit was performed using Qiskit (Reference 3 (see G. Aleksandrowicz, T. Alexander, P. Barkoutsos, L. Bello, Y. Ben-Haim, D. Bucher, F. Jose Cabrera-Hernandez, J. Carballo-Franquis, A. Chen, C. Chen, J. Chow, A. Corcoles-Gonzales, A. Cross, A. Cross, A. Cross, J. Cruz-Benito, C. Culver, S. Gonzalez, E. Torre, D, Ding, E. Dumitrescu, I. Duran, P. Eendebak, M. Everitt, I. Sertage, A. Frisch, A. Fuhrer, J. Gambetta, B Gago, J. Gomez-Mosquera, D. Greenberg, I. Hamamura, V. Havlicek, J. Hellmers, L. Herok, H. Horii, S. Hu, T. Imamichi, T. Itoko, A. Javadi-Abhari, N. Kanazawa, A. Karazeev, K. Krsulich, P. Liu, Y. Luh, Y. Maeng, M. Marques, F. Martin-Fernandez, D. McClure, D. McKay, S. Meesala, A. Mezzacapo, N. Moll, D. Rodriguez, G. Nannicini, P. Nation, P. Ollitrault, L. O'Riordan, H. Paik, J. Perez, A. Phan, M. Pistoia, V. Prutyanov, M. Reuter, J. Rice, A. Davila, R. Rudy, M. Ryu, N. Sathaye, C. Schnabel, E. Schoute, K. Setia, Y. Shi, A. Silva, Y. Siraichi, S. Sivarajah, J. Smolin, M. Soeken, H. Takahashi, I. Tavernelli, C. Taylor, P. Taylour, K. Trabing, M. Treinish, W. Turner, D. Vogt-Lee, C. Vuillot, J. Wildstrom, J. Wilson, E. Winston, C. Wood, S. Wood, S. Worner, I. Akhalwaya, C. Zoufalhttps. https://doi.org/10.5281/zenodo.2562111, (2019) An Open-source Framework for Quantum Computing)).
HF (Hartree-Fock), MP2 (Moller-Plesset 2), and FCI in
As described above, by using the quantum circuit QC1 according to the present embodiment, the energy and the force acting on the atoms can be inferred with high accuracy. Therefore, the quantum circuit QC1 can be applied to a simulation technique for performing molecular dynamics calculation represented by molecular dynamics.
Processing target molecules according to Example 2 are an H2O molecule and an NH3 molecule. In Example 2, 4-qubit calculation using a model of a complete active space cas(2e, 2o) was performed. In Example 2, numerical simulation was performed using the same open source libraries as in Example 1.
CASCI in
A processing target molecule according to Example 3 is an H3 molecule. In Example 3, a quantum circuit (hereinafter, referred to as a quantum circuit QC3) that performs a quantum gate operation on 6 qubits was used. The quantum circuit QC3 was obtained by increasing the number of qubits of the quantum circuit QC1 illustrated in
HQCNN in
Thus, according to the present embodiment, it is possible to provide a quantum circuit learning system, a quantum circuit learning method, a quantum circuit learning program, a quantum inference system, a quantum circuit, and a quantum-classical hybrid neural network that achieve high inference accuracy at low calculation cost.
While certain embodiments have been described, these embodiments have been presented by way of example only, and are not intended to limit the scope of the inventions. Indeed, the novel embodiments described herein may be embodied in a variety of other forms; furthermore, various omissions, substitutions and changes in the form of the embodiments described herein may be made without departing from the spirit of the inventions. The accompanying claims and their equivalents are intended to cover such forms or modifications as would fall within the scope and spirit of the inventions.
Hereinafter, the invention disclosed in the specification and claims at the time of filing of the present application will be appended.
(1) A quantum circuit learning system includes:
The quantum circuit includes a first block circuit and a second block circuit concatenated to the first block circuit. The first block circuit includes: a first gate operation layer including a first encoding gate that is a quantum gate parameterized with a first encoding parameter in which the input information is encoded and which is for constructing a first Hartree-Fock state, and a first transformation gate that is a quantum gate parameterized with the learning parameter for transforming the first Hartree-Fock state into a first quantum state; and a measurement layer that outputs a measured value of the first quantum state.
The second block circuit includes: a second gate operation layer including a second encoding gate parameterized with a second encoding parameter in which the measured value is encoded and which is for constructing a second Hartree-Fock state, and a second transformation gate parameterized with the learning parameter for transforming the second Hartree-Fock state into a second quantum state; and an output layer that outputs the second quantum state as the output information.
(2) The quantum circuit learning system according to (1), in which
(3) The quantum circuit learning system according to (2), in which the output layer outputs the second quantum state as a trial wave function.
(4) The quantum circuit learning system according to (2) or (3), in which the first block circuit and/or the second block circuit preserves the number of particles represented by the plurality of qubits.
(5) The quantum circuit learning system according to any one of (1) to (4), in which the classical computer updates the learning parameter using a cost function for evaluating the difference.
(6) The quantum circuit learning system according to (5), in which the cost function is defined by a sum of expected values of a Hamiltonian for the second quantum state for the number of samples of the input information.
(7) The quantum circuit learning system according to any one of (1) to (6), in which the classical computer updates the learning parameter according to a Nelder-Mead method, a Powell method, a CG method, a Newton method, a BFGS method, an L-BFGS-B method, a TNC method, a COBYLA method, or an SLSQP method.
(8) The quantum circuit learning system according to any one of (1) to (7), in which the learning parameter is a rotation angle parameter representing a rotation angle of a rotation gate out of the first transformation gate and the second transformation gate.
(9) The quantum circuit learning system according to any one of (1) to (8), in which the first gate operation layer and the second gate operation layer have different quantum gate configurations.
(10) The quantum circuit learning system according to any one of (1) to (9), in which
(11) A quantum circuit learning method includes:
The quantum circuit includes a first block circuit and a second block circuit concatenated to the first block circuit.
The first block circuit includes: a first gate operation layer including a first encoding gate that is a quantum gate parameterized with a first encoding parameter in which the input information is encoded and which is for constructing a first Hartree-Fock state, and a first transformation gate that is a quantum gate parameterized with the learning parameter for transforming the first Hartree-Fock state into a first quantum state; and a measurement layer that outputs a measured value of the first quantum state.
The second block circuit includes: a second gate operation layer including a second encoding gate parameterized with a second encoding parameter in which the measured value is encoded and which is for constructing a second Hartree-Fock state, and a second transformation gate parameterized with the learning parameter for transforming the second Hartree-Fock state into a second quantum state; and an output layer that outputs the second quantum state as the output information.
The inventions of (2) to (10) described above can be applied to the quantum circuit learning method.
(12) A quantum inference system includes a quantum computer that applies input information to a quantum circuit that performs a quantum gate operation on a plurality of qubits to acquire output information corresponding to the input information.
The quantum circuit includes a first block circuit and a second block circuit concatenated to the first block circuit.
The first block circuit includes: a first gate operation layer including a first encoding gate that is a quantum gate parameterized with a first encoding parameter in which the input information is encoded and which is for constructing a first Hartree-Fock state, and a first transformation gate that is a quantum gate parameterized with a learning parameter for transforming the first Hartree-Fock state into a first quantum state; and a measurement layer that outputs a measured value of the first quantum state.
The second block circuit includes: a second gate operation layer including a second encoding gate parameterized with a second encoding parameter in which the measured value is encoded and which is for constructing a second Hartree-Fock state, and a second transformation gate parameterized with the learning parameter for transforming the second Hartree-Fock state into a second quantum state; and an output layer that outputs the second quantum state as the output information.
The inventions of (2) to (10) described above can be applied to the quantum inference system.
(13) A quantum circuit includes
The first block circuit includes: a first gate operation layer including a first encoding gate that is a quantum gate parameterized with a first encoding parameter in which input information is encoded and which is for constructing a first Hartree-Fock state, and a first transformation gate that is a quantum gate parameterized with a learning parameter for transforming the first Hartree-Fock state into a first quantum state; and a measurement layer that outputs a measured value of the first quantum state.
The second block circuit includes: a second gate operation layer including a second encoding gate parameterized with a second encoding parameter in which the measured value is encoded and which is for constructing a second Hartree-Fock state, and a second transformation gate parameterized with the learning parameter for transforming the second Hartree-Fock state into a second quantum state; and an output layer that outputs the second quantum state as output information.
The inventions of (2) to (10) described above can be applied to the quantum circuit.
(14) A quantum-classical hybrid neural network includes a repetitive structure of block circuits each including a quantum circuit in which quantum information undergoes processing in an order of a Hartree-Fock state construction, a parameterized quantum circuit processing, and a measurement layer processing.
The inventions of (2) to (10) described above can be applied to the quantum-classical hybrid neural network.
Number | Date | Country | Kind |
---|---|---|---|
2022-149292 | Sep 2022 | JP | national |