WO2024202575A1 - 情報処理プログラム、情報処理方法、および情報処理装置 - Google Patents
情報処理プログラム、情報処理方法、および情報処理装置 Download PDFInfo
- Publication number
- WO2024202575A1 WO2024202575A1 PCT/JP2024/004241 JP2024004241W WO2024202575A1 WO 2024202575 A1 WO2024202575 A1 WO 2024202575A1 JP 2024004241 W JP2024004241 W JP 2024004241W WO 2024202575 A1 WO2024202575 A1 WO 2024202575A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- quantum
- gates
- information processing
- quantum bits
- processing device
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Ceased
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N10/00—Quantum computing, i.e. information processing based on quantum-mechanical phenomena
- G06N10/20—Models of quantum computing, e.g. quantum circuits or universal quantum computers
Definitions
- the present invention relates to an information processing program, an information processing method, and an information processing device.
- Prior techniques include, for example, swapping a global qubit related to an operation with a local qubit.
- the present invention aims to make it easier to perform calculations efficiently.
- an information processing program, an information processing method, and an information processing device acquire a first quantum circuit that defines multiple gates in a chronological order, each gate representing an operation performed on one or more different quantum bits, for multiple quantum bits including one or more local quantum bits and one or more global quantum bits, generate an acyclic directed graph based on the acquired first quantum circuit, including nodes representing each of the multiple gates and directed edges representing the order of operation between the gates represented by the different nodes, identify, based on the generated acyclic directed graph, one or more quantum bits referenced by one or more first gates that generate inter-process communication and reference one or more quantum bits that are equal to or less than the upper limit of the local quantum bits and that can be executed without relying on other gates, and generate a second quantum circuit that is logically equivalent to the first quantum circuit, including one or more swap gates immediately before the one or more first gates that swap the local quantum bits with the global quantum bits so that the identified one or more quantum bits become local.
- FIG. 1 is a diagram illustrating an example of an information processing method according to an embodiment.
- FIG. 2 is an explanatory diagram illustrating an example of an information processing system 200.
- FIG. 3 is a block diagram showing an example of the hardware configuration of the information processing device 100.
- FIG. 4 is a block diagram showing an example of the functional configuration of the information processing device 100.
- FIG. 5 is an explanatory diagram (part 1) showing the flow of operations of the information processing device 100.
- FIG. 6 is a diagram (part 2) illustrating the flow of operations of the information processing device 100.
- FIG. 7 is a diagram (part 3) illustrating the flow of operations of the information processing device 100.
- FIG. 8 is an explanatory diagram (part 4) showing the flow of operations of the information processing device 100.
- FIG. 1 is a diagram illustrating an example of an information processing method according to an embodiment.
- FIG. 2 is an explanatory diagram illustrating an example of an information processing system 200.
- FIG. 3 is a block diagram showing an example of
- FIG. 9 is an explanatory diagram (part 5) showing the flow of operations of the information processing device 100.
- FIG. 10 is an explanatory diagram (part 1) showing an example of the operation of the information processing device 100.
- FIG. 11 is an explanatory diagram (part 2) showing an example of the operation of the information processing device 100.
- FIG. 12 is an explanatory diagram (part 3) showing an example of the operation of the information processing device 100.
- FIG. 13 is an explanatory diagram (part 4) showing an example of the operation of the information processing device 100.
- FIG. 14 is an explanatory diagram (part 5) showing an example of the operation of the information processing device 100.
- FIG. 15 is an explanatory diagram (part 1) showing a specific example of the operation of the information processing device 100.
- FIG. 16 is an explanatory diagram (part 2) showing a specific example of the operation of the information processing device 100.
- FIG. 17 is an explanatory diagram (part 3) showing a specific example of the operation of the information processing device 100.
- FIG. 18 is an explanatory diagram (part 4) showing a specific example of the operation of the information processing device 100.
- FIG. 19 is an explanatory diagram showing a first application example of the information processing device 100.
- FIG. 20 is an explanatory diagram (part 1) showing a second application example of the information processing device 100.
- FIG. 21 is an explanatory diagram (part 2) showing a second application example of the information processing device 100.
- FIG. 22 is an explanatory diagram (part 1) showing a third application example of the information processing device 100.
- FIG. 23 is an explanatory diagram (part 2) showing a third application example of the information processing device 100.
- FIG. 24 is a flowchart illustrating an example of an overall processing procedure.
- the information processing device 100 is a computer for efficiently and easily performing a series of operations on one or more different quantum bits represented by a quantum circuit.
- the information processing device 100 is, for example, a server or a PC (Personal Computer).
- a series of operations on one or more different quantum bits represented by the quantum circuit may be performed, for example, on a quantum simulator that simulates a quantum computer.
- the operations are represented, for example, by gates in the quantum circuit.
- a combination of quantum states represented by each of the multiple quantum bits may be expressed in vector form.
- a vector that represents a combination of quantum states is also called, for example, a state vector.
- the handling of each component of a vector may be shared among multiple processes.
- two or more processes may exist on different computers, for example.
- two or more processes may exist on the same computer, for example.
- inter-process communication may occur between the multiple processes responsible for different components. If two or more processes in which inter-process communication occurs exist on different computers, network communication may also occur.
- quantum bits a and b a vector is stored whose components are the probability that the combination of quantum states represented by quantum bits a and b is "00", “01”, “10", and “11".
- the value on the left corresponds to the quantum state represented by quantum bit a
- the value on the right corresponds to the quantum state represented by quantum bit b.
- process ⁇ may be responsible for the probability that the combination of quantum states represented by quantum bits a and b is "00" and "01”.
- process ⁇ may be responsible for the probability that the combination of quantum states represented by quantum bits a and b is "10" and "11".
- quantum bit a when performing an X-gate operation on quantum bit a, it is desired that the combination of quantum states represented by quantum bits a and b be swapped between the probability of "00” and the probability of "10", and between the probability of "01” and the probability of "11".
- different processes are responsible for the probability of "00” and the probability of "10”
- different processes are responsible for the probability of "01” and the probability of "11”, resulting in inter-process communication.
- quantum bit that causes inter-process communication to occur may be referred to as a "global quantum bit.”
- quantum bit a is specifically a global quantum bit.
- a quantum bit that does not cause inter-process communication to occur may be referred to as a "local quantum bit.”
- quantum bit b is specifically a local quantum bit.
- a worker may manually update a quantum circuit by adding an operation that swaps a local quantum bit with a global quantum bit immediately before an operation in a series of operations that generates inter-process communication.
- the workload on the worker increases, and it may be difficult to reduce the processing load and processing time required to perform a series of operations.
- n quantum bits are set as local quantum bits. For example, when n quantum bits are arranged in order, the lowest m quantum bits are set as local quantum bits.
- p quantum bits are set as global quantum bits. For example, when n quantum bits are arranged in order, the highest p quantum bits are set as global quantum bits.
- n m + p.
- each of the 2 ⁇ n components There are 2 ⁇ n components that represent the probability of combinations of quantum states represented by each of the n quantum bits.
- the 2 ⁇ n components are shared among 2 ⁇ p processes.
- Each of the 2 ⁇ p processes is responsible for 2 ⁇ m components.
- each of the 2 ⁇ p processes is assigned one of the combinations of quantum states represented by each of the top p quantum bits, without overlapping.
- each of the 2 ⁇ p processes is responsible for 2 ⁇ m components that represent the probability of combinations including the combination assigned to the process, among the combinations of quantum states represented by each of the n quantum bits.
- quantum bits 0 to 3 there are quantum bits 0 to 3.
- n 4.
- m 2.
- p 2.
- quantum bits 0 and 1 are set as local quantum bits.
- quantum bits 2 and 3 are set as global quantum bits.
- the four processes specifically include process 1 which is responsible for the four components that represent the probability that the quantum state combination of quantum bits 0 to 3 is "00**". * indicates a part that can have the value of either 0 or 1.
- the four processes specifically include process 2 which is responsible for the four components that represent the probability that the quantum state combination of quantum bits 0 to 3 is "01**”.
- the four processes specifically include process 3 which is responsible for the four components that represent the probability that the quantum state combination of quantum bits 0 to 3 is "10**”.
- the four processes specifically include process 4 which is responsible for the four components that represent the probability that the quantum state combination of quantum bits 0 to 3 is "11**".
- the information processing device 100 acquires a first quantum circuit 110 related to n quantum bits.
- n 4.
- the first quantum circuit 110 is information that specifies a number of gates 121-123 in chronological order for four quantum bits.
- Each of the gates 121-123 is information that indicates the execution of an operation on one or more quantum bits.
- the information processing device 100 generates a directed acyclic graph (DAG) 130 based on the acquired first quantum circuit 110.
- the directed acyclic graph 130 includes nodes 141 to 143 representing the gates 121 to 123, respectively, and directed edges representing the order of operations between the gates 121 to 123. For example, the directed edge starts at a node corresponding to the operation to be performed first of two consecutive operations, and ends at a node corresponding to the operation to be performed later.
- the information processing device 100 identifies one or more gates in which inter-process communication occurs, each of which references quantum bits that can be executed independently of other gates and that are equal to or less than the upper limit of local quantum bits as a whole.
- the information processing device 100 identifies one or more quantum bits that are referenced as a whole by the identified one or more gates.
- the upper limit is the maximum number of quantum bits that can be set locally. In the example of Figure 1, the upper limit is specifically 2.
- Executable without depending on other gates means, for example, that one or more gates can be executed as a whole without depending on other gates. Executable without depending on other gates specifically means that a directed edge starting from another gate that is not included in one or more gates is not connected to any of the one or more gates.
- the information processing device 100 specifically identifies gate 121 as one or more gates at which inter-process communication occurs, which references two quantum bits up to an upper limit and which can be executed without depending on other gates, based on the acyclic directed graph 130.
- the information processing device 100 identifies quantum bits 0 and 2 referenced by gate 121.
- the information processing device 100 generates a second quantum circuit 150 that is logically equivalent to the first quantum circuit 110.
- the second quantum circuit 150 includes at least one swap gate immediately before the one or more identified gates that swaps a local quantum bit with a global quantum bit so that the one or more identified quantum bits become local.
- the one or more swap gates include, for example, a single swap gate that swaps two quantum bits, or a fused swap gate that swaps four or more quantum bits.
- the information processing device 100 specifically prepares an empty template circuit.
- the information processing device 100 specifically adds a swap gate 160 to the template circuit, and adds the identified gate 121 next to the swap gate 160.
- the swap gate 160 for example, swaps local quantum bit 1 with global quantum bit 2.
- the information processing device 100 adds gates 122 and 123 to the template circuit.
- the information processing device 100 adopts the template circuit as the second quantum circuit 150.
- the information processing device 100 can generate a second quantum circuit 150 that is logically equivalent to the first quantum circuit 110, but that has a smaller number of inter-process communications or a smaller amount of communication than the first quantum circuit 110. This makes it easier for the information processing device 100 to efficiently perform a series of operations on one or more different quantum bits.
- the information processing device 100 can, for example, reduce the processing load and processing time required when performing a series of operations.
- the information processing device 100 controls multiple processes according to the generated second quantum circuit 150, and performs a simulation that simulates changes in the combination of quantum states due to a series of operations defined in the second quantum circuit 150.
- the processes may be possessed by, for example, the information processing device 100.
- the information processing device 100 outputs the results of the simulation so that the user can refer to them. In this way, the information processing device 100 can make the results of the simulation available to the user.
- the information processing device 100 identifies one or more gates that can be executed independently of other gates and that each generate inter-process communication, but this is not limited to the case.
- the information processing device 100 may identify one or more gates that can be executed independently of other gates and that each do not generate inter-process communication.
- the information processing device 100 may specifically add one or more identified gates that each do not generate inter-process communication to an empty template circuit, and then identify one or more gates that can be executed independently of other gates and that each generate inter-process communication. An example of this case will be described later with reference to Figures 5 to 18.
- the information processing device 100 may generate a second quantum circuit 150 that includes one or more swap gates only immediately before gate 121, but this is not limiting.
- the information processing device 100 may generate a second quantum circuit 150 that includes one or more swap gates immediately before gate 122 in addition to immediately before gate 121.
- An example of this case will be described later in detail using Figures 5 to 18.
- the information processing device 100 may cooperate with other computers.
- the information processing device 100 may transmit the second quantum circuit 150 to another computer having multiple processes.
- the multiple processes may be possessed by different computers.
- multiple computers may cooperate to realize the functions of the information processing device 100.
- the functions of the information processing device 100 may be realized on the cloud.
- FIG. 2 is an explanatory diagram showing an example of an information processing system 200.
- the information processing system 200 includes an information processing device 100, one or more arithmetic processing devices 201, and one or more client devices 202.
- the information processing device 100 and the arithmetic processing device 201 are connected via a wired or wireless network 210.
- the network 210 is, for example, a LAN (Local Area Network), a WAN (Wide Area Network), the Internet, etc.
- the information processing device 100 and the client device 202 are connected via the wired or wireless network 210.
- the information processing device 100 is a computer for generating a first quantum circuit.
- the information processing device 100 receives from the client device 202 a first quantum circuit that specifies gates representing each operation of a series of operations in a time series for n quantum bits.
- the information processing device 100 generates a second quantum circuit that is logically equivalent to the received first quantum circuit.
- the information processing device 100 sets m local quantum bits and p global quantum bits out of the n quantum bits.
- the information processing device 100 generates a second quantum circuit based on the first quantum circuit, the m local quantum bits, and the p global quantum bits. Specifically, the information processing device 100 generates the second quantum circuit as described later in Figures 5 to 18.
- the information processing device 100 controls the multiple arithmetic processing devices 201 to share the simulation of the change in the combination of quantum states due to a series of operations according to the generated second quantum circuit.
- the information processing device 100 for example, distributes and assigns each component of a vector expressing the combination of quantum states to the multiple arithmetic processing devices 201.
- the information processing device 100 controls the multiple arithmetic processing devices 201 to update one or more components assigned to the arithmetic processing devices 201 by, for example, transmitting the second quantum circuit to the multiple arithmetic processing devices 201.
- the information processing device 100 receives each component of a vector representing a combination of quantum states from a plurality of calculation processing devices 201. Based on each component of the vector representing the received combination of quantum states, the information processing device 100 generates the results of a simulation that simulates changes in the combination of quantum states due to a series of calculations. The information processing device 100 transmits the results of the simulation to the client device 202.
- the information processing device 100 is, for example, a server or a PC.
- the arithmetic processing device 201 is a computer for sharing a simulation that simulates changes in the combination of quantum states due to a series of calculations.
- the arithmetic processing device 201 has a process that manages one or more components of a vector that represents a combination of quantum states.
- the arithmetic processing device 201 receives a second quantum circuit from the information processing device 100.
- the arithmetic processing device 201 communicates with other arithmetic processing devices 201 based on the second quantum circuit, and updates one or more components that it manages.
- the arithmetic processing device 201 transmits one or more components of the vector to the information processing device 100.
- the arithmetic processing device 201 is, for example, a server or a PC.
- the client device 202 is a computer used by a worker.
- the client device 202 accepts the designation of a first quantum circuit based on operational input from the worker.
- the client device 202 transmits the designated first quantum circuit to the information processing device 100.
- the client device 202 receives the results of the simulation from the information processing device 100.
- the client device 202 outputs the results of the simulation so that the worker can refer to them.
- the client device 202 is, for example, a PC, a tablet terminal, or a smartphone.
- the information processing device 100 is a device different from the arithmetic processing device 201 has been described, but this is not limited thereto.
- the information processing device 100 may have the functions of the arithmetic processing device 201 and also operate as the arithmetic processing device 201.
- the case where the information processing device 100 is a device different from the client device 202 has been described, but this is not limited thereto.
- the information processing device 100 may have the functions of the client device 202 and also operate as the client device 202.
- FIG. 3 is a block diagram showing an example of the hardware configuration of the information processing device 100.
- the information processing device 100 has a CPU (Central Processing Unit) 301, a memory 302, a network I/F (Interface) 303, a recording medium I/F 304, and a recording medium 305.
- each component is connected to each other by a bus 300.
- CPU 301 is responsible for the overall control of information processing device 100.
- Memory 302 includes, for example, ROM (Read Only Memory), RAM (Random Access Memory), and flash ROM. Specifically, for example, flash ROM and ROM store various programs, and RAM is used as a work area for CPU 301. Programs stored in memory 302 are loaded into CPU 301, causing CPU 301 to execute the coded processes.
- Network I/F 303 is connected to network 210 via a communication line, and is connected to other computers via network 210.
- Network I/F 303 manages the internal interface with network 210, and controls the input and output of data from other computers.
- Network I/F 303 is, for example, a modem or a LAN adapter.
- the information processing device 100 may also have, for example, a keyboard, a mouse, a display, a printer, a scanner, a microphone, and a speaker.
- the information processing device 100 may also have multiple recording medium I/Fs 304 and recording media 305.
- the information processing device 100 may not have a recording medium I/F 304 or a recording medium 305.
- a specific example of the hardware configuration of the arithmetic processing device 201 is similar to the example of the hardware configuration of the information processing device 100 shown in FIG. 3, and therefore a description thereof will be omitted.
- Example of Hardware Configuration of Client Device 202 Specifically, an example of the hardware configuration of the client device 202 is similar to the example of the hardware configuration of the information processing device 100 shown in FIG. 3, and therefore a description thereof will be omitted.
- FIG. 4 is a block diagram showing an example of the functional configuration of the information processing device 100.
- the information processing device 100 includes a storage unit 400, an acquisition unit 401, a first generation unit 402, a first identification unit 403, a second identification unit 404, a second generation unit 405, a simulation unit 406, and an output unit 407.
- the storage unit 400 is realized, for example, by a storage area such as the memory 302 or recording medium 305 shown in FIG. 3. Below, a case where the storage unit 400 is included in the information processing device 100 will be described, but this is not limited to this.
- the storage unit 400 may be included in a device different from the information processing device 100, and the stored contents of the storage unit 400 may be accessible from the information processing device 100.
- the acquisition unit 401 to the output unit 407 function as an example of a control unit. Specifically, the acquisition unit 401 to the output unit 407 realize their functions by, for example, having the CPU 301 execute a program stored in a storage area such as the memory 302 or recording medium 305 shown in FIG. 3, or by the network I/F 303. The processing results of each functional unit are stored in, for example, a storage area such as the memory 302 or recording medium 305 shown in FIG. 3.
- the storage unit 400 stores various information that is referenced or updated during processing by each functional unit.
- the storage unit 400 stores, for example, a first quantum circuit.
- the first quantum circuit is a quantum circuit related to multiple quantum bits.
- the multiple quantum bits include one or more local quantum bits and one or more global quantum bits.
- the first quantum circuit specifies multiple gates in a chronological order, each gate representing the execution of an operation on one or more different quantum bits.
- the first quantum circuit is acquired by, for example, the acquisition unit 401.
- the storage unit 400 stores, for example, identification information that identifies local and global quantum bits among a plurality of quantum bits.
- the local and global quantum bits can be swapped. For example, a certain quantum bit is changed from local to global, and another quantum bit is changed from global to local, thereby swapping the local and global quantum bits.
- the identification information is acquired, for example, by the acquisition unit 401.
- the storage unit 400 stores, for example, a second quantum circuit.
- the second quantum circuit is a quantum circuit related to multiple quantum bits.
- the second quantum circuit specifies multiple gates in a time series, each gate representing the execution of an operation on one or more different quantum bits.
- the second quantum circuit is a quantum circuit that is logically equivalent to the first quantum circuit.
- the second quantum circuit is generated, for example, by the second generation unit 405.
- the acquisition unit 401 acquires various information used for processing by each functional unit.
- the acquisition unit 401 stores the acquired various information in the storage unit 400 or outputs it to each functional unit.
- the acquisition unit 401 may also output the various information stored in the storage unit 400 to each functional unit.
- the acquisition unit 401 acquires various information based on, for example, a user's operational input.
- the acquisition unit 401 may receive various information from, for example, a device other than the information processing device 100.
- the acquisition unit 401 acquires a first quantum circuit. More specifically, the acquisition unit 401 acquires the first quantum circuit by accepting input of the first quantum circuit based on an operational input from a user. More specifically, the acquisition unit 401 acquires the first quantum circuit by receiving it from another computer. More specifically, the other computer is the client device 202, etc.
- the acquisition unit 401 acquires, for example, identification information that distinguishes between local quantum bits and global quantum bits. More specifically, the acquisition unit 401 acquires the identification information by accepting input of the identification information based on operational input by a user. More specifically, the acquisition unit 401 acquires the identification information by receiving it from another computer. More specifically, the other computer is the client device 202, etc.
- the acquisition unit 401 may receive a start trigger to start processing of any of the functional units.
- the start trigger may be, for example, a predetermined operational input by a user.
- the start trigger may be, for example, the receipt of predetermined information from another computer.
- the start trigger may be, for example, the output of predetermined information by any of the functional units.
- the acquisition unit 401 receives, for example, the acquisition of a first quantum circuit as a start trigger to start processing of the first generation unit 402, the first identification unit 403, the second identification unit 404, and the second generation unit 405.
- the first generation unit 402 generates an acyclic directed graph based on the acquired first quantum circuit, the graph including nodes representing each of the multiple gates and directed edges representing the order of execution of operations between the gates represented by different nodes. This enables the first generation unit 402 to identify dependencies between the gates, making it easier to analyze the contents of the first quantum circuit.
- the first identification unit 403 identifies, based on the generated acyclic directed graph, one or more first gates among the multiple gates that generate inter-process communication and that reference quantum bits that are executable without relying on other gates and that are equal to or smaller than the upper limit of local quantum bits.
- the first identification unit 403 identifies one or more quantum bits referenced by the one or more identified first gates.
- One or more first gates that are executable independently of other gates are, for example, in a state where one or more first gates as a whole are executable independently of other gates. Specifically, one or more first gates that are executable independently of other gates are in a state where a directed edge starting from another gate that is not included in the one or more first gates is not connected to any of the first gates of the one or more first gates.
- the one or more first gates that are executable without depending on other gates may be, for example, a state in which each of the one or more first gates is executable without depending on other gates.
- the one or more first gates that are executable without depending on other gates may be a state in which, for each of the one or more first gates, a directed edge starting from a gate other than the first gate is not connected to the first gate.
- the first identification unit 403 identifies one or more first gates each time the second identification unit 404 identifies one or more second gates. Specifically, the first identification unit 403 identifies one or more first gates each time the second identification unit 404 updates the acyclic directed graph. The first identification unit 403 may identify one or more first gates, for example, when the second identification unit 404 does not identify one or more second gates.
- the first identification unit 403 specifically determines that a gate that represents the performance of an operation expressed by a diagonal matrix is a gate in which inter-process communication does not occur.
- the first identification unit 403 specifically determines that a gate that is not related to a global quantum bit is a gate in which inter-process communication does not occur.
- the first identification unit 403 specifically determines that a gate that represents the performance of an operation not expressed by a diagonal matrix and that is related to a global quantum bit is a gate in which inter-process communication occurs.
- the first identification unit 403 specifically identifies one or more first gates based on the acyclic directed graph and the result of determining whether or not a gate is one at which inter-process communication occurs. More specifically, the first identification unit 403 starts from a gate at which inter-process communication that can be executed without depending on other gates occurs, and identifies one or more first gates at which inter-process communication that can be executed independently of other gates occurs as a whole.
- the first identification unit 403 may sequentially select gates at which inter-process communication occurs and which can be executed without depending on other gates, based on the acyclic directed graph. Specifically, each time the first identification unit 403 selects a gate, it repeatedly performs the process of adding the quantum bit related to that gate to a group, within a range in which the number of quantum bits included in the group does not exceed the upper limit of local quantum bits. The first identification unit 403 identifies the selected gates as one or more first gates. The first identification unit 403 ultimately identifies one or more quantum bits to be included in the group.
- the first identification unit 403 may identify multiple combinations of gates in which inter-process communication occurs, based on the acyclic directed graph, that reference one or more quantum bits that are executable without relying on other gates and that are equal to or less than the upper limit of local quantum bits.
- the first identification unit 403 identifies, among the multiple combinations, one or more gates in which inter-process communication occurs, which is the combination that includes the largest number of gates, as one or more first gates.
- the first identification unit 403 identifies one or more quantum bits referenced by the identified one or more first gates. This allows the first identification unit 403 to obtain a guideline for generating a second quantum circuit.
- the second identification unit 404 identifies, from among the multiple gates, one or more second gates that can be executed independently of other gates and that do not generate inter-process communication, based on the acyclic directed graph.
- One or more second gates that are executable independently of other gates are, for example, in a state where one or more second gates as a whole are executable independently of other gates. Specifically, one or more second gates that are executable independently of other gates are in a state where a directed edge starting from another gate that is not included in the one or more second gates is not connected to any of the one or more second gates.
- the one or more second gates that are executable without depending on other gates may be, for example, a state in which each of the one or more second gates is executable without depending on other gates.
- the one or more second gates that are executable without depending on other gates may be a state in which, for each of the one or more second gates, a directed edge starting from a gate other than the second gate is not connected to the second gate.
- the second identification unit 404 identifies one or more second gates once before the first identification unit 403 initially identifies one or more quantum bits.
- the second identification unit 404 for example, identifies one or more second gates each time the first identification unit 403 identifies one or more quantum bits.
- the second identification unit 404 identifies one or more second gates in response to the first identification unit 403 identifying one or more quantum bits and the second generation unit 405 adding one or more swap gates to the template circuit.
- the swap gate is a single swap gate that swaps two quantum bits, or a fused swap gate that swaps four or more quantum bits.
- the second identification unit 404 may identify one or more second gates, for example, when the first identification unit 403 does not identify one or more quantum bits.
- the second identification unit 404 specifically determines that a gate that represents the performance of an operation expressed by a diagonal matrix is a gate in which inter-process communication does not occur.
- the second identification unit 404 specifically determines that a gate that is not related to a global quantum bit is a gate in which inter-process communication does not occur.
- the second identification unit 404 specifically determines that a gate that represents the performance of an operation not expressed by a diagonal matrix and that is related to a global quantum bit is a gate in which inter-process communication occurs.
- the second identification unit 404 specifically identifies one or more second gates based on the acyclic directed graph and the result of determining whether or not a gate is one at which inter-process communication occurs. More specifically, the second identification unit 404 starts from a gate at which inter-process communication that can be executed independently of other gates does not occur, and identifies one or more second gates at which inter-process communication that can be executed independently of other gates as a whole does not occur.
- the second identification unit 404 updates the acyclic directed graph each time the second identification unit 404 identifies one or more second gates, so as to remove from the acyclic directed graph nodes representing the second gates of each of the one or more second gates currently identified by the second identification unit 404. This allows the second identification unit 404 to update the acyclic directed graph so that the identified gates can be distinguished and so as to be suitable for the purpose of generating a second quantum circuit.
- the second generation unit 405 generates a second quantum circuit that is logically equivalent to the first quantum circuit.
- the second quantum circuit includes, for example, one or more swap gates immediately before the one or more first gates identified by the first identification unit 403, which swap a local quantum bit with a global quantum bit so that the one or more quantum bits identified by the first identification unit 403 become local.
- the second generation unit 405 for example, prepares an empty template circuit. For example, each time the second identification unit 404 identifies one or more second gates, the second generation unit 405 adds the one or more second gates identified by the second identification unit 404 to the template circuit. This allows the second generation unit 405 to generate the second quantum circuit in stages.
- the second generation unit 405 adds one or more swap gates to the template circuit so that the one or more quantum bits identified by the first identification unit 403 become local. Specifically, if the number of quantum bits to be swapped is four or more, the second generation unit 405 adds one or more swap gates, including a fused swap gate, to the template circuit. This allows the second generation unit 405 to generate the second quantum circuit in stages.
- the second generation unit 405 determines whether the acyclic directed graph is empty. If it is empty, the second generation unit 405 generates a second quantum circuit by adding one or more swap gates to the end of the template circuit so that one or more quantum bits that are local in the initial state return to being local. This allows the second generation unit 405 to complete the second quantum circuit.
- the simulation unit 406 controls multiple processes that share each component of a vector that represents a combination of quantum states, and performs a simulation that simulates a change in the combination of quantum states due to a series of operations defined in the second quantum circuit generated by the second generation unit 405.
- the process may be possessed by the information processing device 100.
- the process may be possessed by another computer.
- the other computer is, for example, the calculation processing device 201. This allows the simulation unit 406 to efficiently perform a simulation that simulates a change in the combination of quantum states due to a series of operations.
- the output unit 407 outputs the processing results of at least one of the functional units.
- the output format is, for example, display on a display, printout on a printer, transmission to an external device via the network I/F 303, or storage in a storage area such as the memory 302 or recording medium 305. In this way, the output unit 407 can notify the user of the processing results of at least one of the functional units, thereby improving the convenience of the information processing device 100.
- the output unit 407 outputs, for example, the second quantum circuit generated by the second generation unit 405. Specifically, the output unit 407 outputs the second quantum circuit generated by the second generation unit 405 so that it can be referenced by a user. Specifically, the output unit 407 may transmit the second quantum circuit generated by the second generation unit 405 to another computer. In this way, the output unit 407 can make the second quantum circuit available externally.
- the output unit 407 outputs, for example, the results of the simulation performed by the simulation unit 406. Specifically, the output unit 407 outputs the results of the simulation performed by the simulation unit 406 so that the user can refer to them. Specifically, the output unit 407 may transmit the results of the simulation performed by the simulation unit 406 to another computer. In this way, the output unit 407 can make the results of the simulation performed by the simulation unit 406 available externally.
- FIGS. 5 to 9 are explanatory diagrams showing the flow of operation of the information processing device 100.
- FIG. 5 shows an example of a state vector 500 that expresses a combination of quantum states.
- n quantum bits.
- the information processing device 100 sets a state vector 500 having components that represent the probability of each combination of the quantum states of quantum bits 0 to 3.
- State vector 500 has components that represent the probability that the quantum state combination of quantum bits 0 to 3 is each of "0000" to "1111", for example.
- the component that represents the probability that the quantum state combination of quantum bits 0 to 3 is "****" may be represented as "c **** ". * indicates a portion that takes on a value of either 0 or 1.
- each component of the state vector is updated according to that gate, thereby performing a simulation that simulates the change in the combination of quantum states of quantum bits 0 to 3 due to a series of operations defined in quantum circuit 510.
- the first is on the left side.
- information processing device 100 performs the simulation by assigning multiple components of the state vector to multiple processes and controlling the multiple processes.
- FIG. 6 shows an example of allocating multiple components of a state vector to multiple processes.
- the information processing device 100 accepts inputs of p and m.
- the information processing device 100 sets the upper p quantum bits of a quantum bit string 600 in which n quantum bits are arranged as global quantum bits, and sets the lower m quantum bits of the quantum bit string 600 as local quantum bits.
- n 36. Therefore, there are 2 ⁇ n components of the state vector.
- the information processing device 100 allocates the 2 ⁇ n components of the state vector equally to the 2 ⁇ p processes. Specifically, the information processing device 100 divides the 2 ⁇ n components of the state vector into units of 2 ⁇ m components from the beginning. Specifically, the information processing device 100 allocates each of the divided 2 ⁇ m components to a different process for each 2 ⁇ m component. For this reason, when performing an operation represented by a gate that is not related to a global quantum bit, no inter-process communication occurs. On the other hand, when performing an operation represented by a gate that is related to a global quantum bit, inter-process communication may occur. Next, we move on to the explanation of FIG. 7.
- Figure 7 shows an example where inter-process communication occurs. For example, when performing an operation related to a global quantum bit and not expressed by a diagonal matrix, inter-process communication has the tendency to occur.
- Figure 7 shows an operation of an X gate that is not expressed by a diagonal matrix.
- n 3 and there are quantum bits 0 to 2.
- the most significant quantum bit 2 is a global quantum bit, and the least significant two quantum bits 0 and 1 are local quantum bits.
- the operation of the X gate related to local quantum bit 0 swaps components that are handled by the same process and that differ only in the value of quantum bit 0.
- s indicates the value of the component.
- index indicates an identifier that identifies the component.
- a(***) is an identifier that identifies the component that represents the probability that the quantum state combination is "***".
- s indicates the value of the component.
- index indicates an identifier that identifies the component.
- the operation of the X gate related to global quantum bit 2 swaps components that are handled by different processes and only differ in the value of quantum bit 2.
- s indicates the value of the component.
- index indicates an identifier that identifies the component.
- a(***) is an identifier that identifies the component that represents the probability that the quantum state combination is "***".
- s indicates the value of the component.
- index indicates an identifier that identifies the component.
- Table 800 in Figure 8 shows an example of gate types.
- the gate name field in table 800 is set to a name that identifies the gate.
- the element count field in table 800 is set to the number of elements related to the operation represented by the gate with the above name.
- N 2 ⁇ n.
- the number of operations/element field in table 800 is set to the number of complex operations to be performed when updating one element in the operation represented by the gate with the above name.
- Complex operations include, for example, addition, subtraction, multiplication, and multiplication and accumulation.
- the inter-rank transfer volume field in table 800 is set to the number of elements transferred by inter-process communication when the operation represented by the gate with the above name is related to a global quantum bit.
- M 2 ⁇ (the number of local quantum bits).
- the inter-rank transfer volume corresponds to, for example, the communication volume.
- inter-process communication will lead to an increase in the processing time and processing burden required when performing a series of operations defined in a quantum circuit. Therefore, when the information processing device 100 receives an input for a quantum circuit, it will generate a new quantum circuit that is logically equivalent to the quantum circuit, but which reduces the number of inter-process communications that occur or the amount of communication compared to the quantum circuit.
- the amount of communication related to swap gates tends to be smaller than the amount of communication related to general-purpose gates, X gates, or Y gates. For this reason, the information processing device 100 specifically uses swap gates to generate a new quantum circuit that moves quantum bits referenced in the operations represented by various gates locally in advance.
- FIG. 9 we move on to the explanation of FIG. 9.
- the information processing device 100 has received an input to the quantum circuit 900.
- (9-1) The information processing device 100 leaves the first gate 910 of the quantum circuit 900 as it is in the quantum circuit 900 because it is a gate related to the local quantum bit 0 and can be executed without depending on other gates.
- the information processing device 100 determines that quantum bits 0 and 2 are to be set as local quantum bits because gate 911 of quantum circuit 900 is associated with two or fewer quantum bits 0 and 2, including global quantum bit 2, and can be executed without relying on other gates.
- the information processing device 100 adds a swap gate 930 immediately before gate 912. This allows the information processing device 100 to update the quantum circuit 900 and generate quantum circuit 920. By adding the swap gate 930, the information processing device 100 can prevent inter-process communication from occurring at gates 911 and 913.
- the information processing device 100 moves gate 913 of quantum circuit 920 to just after gate 912 because it is a gate associated with the currently local quantum bit 2 and can be executed without depending on other gates.
- the information processing device 100 determines to set quantum bits 1 and 3 as the next local quantum bits because gate 912 of quantum circuit 920 is associated with two or fewer quantum bits 1 and 3, including the currently global quantum bits 1 and 3, and can be executed without depending on other gates.
- the information processing device 100 adds a swap gate 950 immediately before the gate 912 in order to set quantum bits 1 and 3 as local quantum bits. This causes the information processing device 100 to update the quantum circuit 920 and generate the quantum circuit 940. By adding the swap gate 950, the information processing device 100 can prevent inter-process communication from occurring at the gate 912.
- the information processing device 100 can obtain a quantum circuit 940 that is logically equivalent to the quantum circuit 900, but in which the number of times inter-process communications occur or the amount of communication is reduced compared to the quantum circuit 900.
- the information processing device 100 can efficiently perform a series of operations defined in the quantum circuit 940 while reducing the number of times inter-process communications occur or the amount of communication.
- the information processing device 100 can essentially perform a series of operations defined in the quantum circuit 900 that has received input.
- FIGS. 10 to 14 are explanatory diagrams showing an example of the operation of the information processing device 100.
- the information processing device 100 accepts an input of a quantum circuit 1000.
- the quantum circuit 1000 includes gates 1010 to 1013. Quantum bits 0 and 1 are local quantum bits in the initial state. Quantum bits 2 and 3 are global quantum bits in the initial state.
- the information processing device 100 generates a DAG 1020 corresponding to the quantum circuit 1000.
- the DAG 1020 includes nodes 1030 to 1033 that represent the gates 1010 to 1013, respectively.
- the information processing device 100 may perform a topological sort on the DAG 1020.
- the information processing device 100 sets the generated DAG 1020 in the graph G.
- the information processing device 100 prepares an empty output circuit C.
- the information processing device 100 stores a qubit order ⁇ that enables the current global qubit to be distinguished from the current local qubit.
- the qubit order ⁇ is information that represents, for example, an identifier that identifies each quantum bit, arranged in ascending order from the highest order in a quantum bit string in which n quantum bits are arranged.
- the qubit order ⁇ is [0, 1, 2, 3], etc., in the initial state. This allows the information processing device 100 to make it easier to analyze the contents of the quantum circuit 1000.
- FIG. 11 we move on to the explanation of FIG. 11.
- the information processing device 100 repeatedly performs the processes (11-1) to (11-3) described below until the graph G becomes empty.
- the qubit order ⁇ is [0, 1, 2, 3, 4, 5] in the initial state.
- the three qubits on the left are local, and the three qubits on the right are global.
- the information processing device 100 removes the gate g from graph G.
- the information processing device 100 may refer to table 800 to determine whether the gate g represented by each node of graph G is a gate for which inter-process communication occurs for the current qubit order ⁇ .
- the information processing device 100 updates the removed gate g so that it conforms to the current qubit order ⁇ , and then adds it, in order, to the end of the current output circuit C. Specifically, the information processing device 100 rewrites the contents of the removed gate g so that the quantum bit number referenced by the gate g conforms to the current qubit order ⁇ , and then adds it to the end of the current output circuit C. This makes it easier for the information processing device 100 to avoid a gate in which inter-process communication does not currently occur becoming a gate in which inter-process communication occurs after swapping the global quantum bit and the local quantum bit.
- the information processing device 100 identifies one or more quantum bits to be made local next. For example, the information processing device 100 determines a set Qlocal' representing one or more quantum bits to be made local next based on the current graph G and the current qubit order ⁇ .
- the information processing device 100 may repeatedly search for gates in graph G that are executable without depending on other gates, for example, as long as
- the information processing device 100 may repeatedly search for gates in graph G that are executable without depending on other gates other than the gates already searched, for example, as long as
- the information processing device 100 may add, for example, the quantum bit referenced by the searched gate to Qlocal'.
- is the number of quantum bits of *. This allows the information processing device 100 to identify one or more quantum bits to be made local next.
- the information processing device 100 adds a swap gate or a fused swap gate to the output circuit C so that the local quantum bit matches Qlocal'.
- the information processing device 100 adds a swap gate to the output circuit C that swaps local quantum bits so that the upper
- the information processing device 100 adds a swap gate to the output circuit C that swaps local quantum bits 0 and 1, as shown in table 1100.
- the information processing device 100 adds a swap gate to the output circuit C, for example, so that the Q_import quantum bit among the global quantum bits is continuous. Swap gates that swap global quantum bits tend to be implemented so that they can be implemented without inter-process communication. In the example of FIG. 11, the information processing device 100 adds a swap gate that swaps global quantum bits 4 and 5 to the output circuit C, as shown in table 1100.
- the information processing device 100 adds a swap gate or a fused swap gate to the output circuit C so as to swap the upper
- the information processing device 100 adds a fused swap gate to the output circuit C that swaps the local quantum bits 0 and 2 with the global quantum bits 3 and 5, as shown in table 1100. This allows the information processing device 100 to swap the upper
- the information processing device 100 may add a quantum bit that is discontinuous among the global quantum bits to Q_import. Then, the information processing device 100 may use a fused swap gate to swap the local quantum bit with the global quantum bit in one go.
- the information processing device 100 specifically adds quantum bit 4 to Q_import. Specifically, the information processing device 100 adds one fused swap gate to the output circuit C, which swaps local quantum bits 0 to 2 with global quantum bits 3 to 5, as shown in table 1210. This allows the information processing device 100 to use the fused swap gate to swap the quantum bit of Q_exportable with the quantum bit of Q_import.
- the information processing device 100 may consider swapping the local quantum bit with the global quantum bit multiple times.
- the information processing device 100 specifically adds one swap gate to the output circuit C that swaps local quantum bit 1 with global quantum bit 3, as shown in table 1200.
- the information processing device 100 specifically adds one swap gate to the output circuit C that swaps local quantum bit 2 with global quantum bit 5, as shown in table 1200.
- the information processing device 100 can utilize fused swap gates to reduce the processing load imposed when swapping the quantum bit of Q_exportable with the quantum bit of Q_import. Specifically, the information processing device 100 can reduce the number of gates added to the output circuit C. Specifically, the information processing device 100 can reduce the number of times that an operation to swap quantum bits is performed according to the output circuit C. Next, we move on to the explanation of FIG. 13.
- the information processing device 100 detects that the graph G has become empty.
- the information processing device 100 adds a swap gate or a fused swap gate to the output circuit C so as to return the qubit order ⁇ to the initial state.
- the information processing device 100 adds, for example, a swap gate or a fused swap gate to the output circuit C based on Qlocal', similar to FIG. 11.
- the information processing device 100 specifically adds a fused swap gate that swaps local quantum bits 5 and 4 with global quantum bits 0 and 2 to the output circuit C, as shown in table 1300.
- the information processing device 100 specifically adds a swap gate that swaps local quantum bits 0 and 1 to the output circuit C.
- the information processing device 100 specifically adds a swap gate that swaps global quantum bits 4 and 5 to the output circuit C.
- the information processing device 100 can generate an output circuit C that is logically equivalent to the quantum circuit that received the input and in which the number of times inter-process communication occurs or the amount of communication is suppressed.
- Figure 14 we move on to the explanation of Figure 14 and explain how the qubit order ⁇ is returned to its initial state when the swap gate that swaps global quantum bits is not implemented so as to be able to be implemented without inter-process communication.
- the information processing device 100 swaps quantum bits one at a time. Therefore, in this case, the information processing device 100 adds a maximum of one swap gate (the number of quantum bits minus one) to the output circuit C.
- the information processing device 100 If the number of local qubits is equal to or greater than twice the number of global qubits, the information processing device 100 returns the qubit order ⁇ to its initial state, as shown below.
- the global quantum bit may include quantum bits numbered (number of local quantum bits) through (number of quantum bits - 1).
- the information processing device 100 adds a swap gate to the output circuit C so that the upper (number of global quantum bits) quantum bits of the local quantum bits do not include quantum bits numbered (number of local quantum bits) through (number of quantum bits - 1).
- the information processing device 100 adds a swap gate that swaps local quantum bits 0 and 5 with each other to the output circuit C, as shown in table 1400.
- the information processing device 100 adds, for example, a fused swap gate that swaps the most significant (number of global quantum bits) quantum bits of the local quantum bits with the global quantum bit to the output circuit C.
- a fused swap gate that swaps the local quantum bits 0 and 3 with the global quantum bits 2 and 4 to the output circuit C, as shown in table 1400.
- the information processing device 100 adds, for example, a swap gate that rearranges the order of the (number of local quantum bits) to (number of quantum bits - 1) quantum bits above the local quantum bits to the output circuit C.
- the information processing device 100 specifically adds two swap gates that rearrange the order of the local quantum bits 2, 4, and 5 to the output circuit C, as shown in table 1400.
- the information processing device 100 adds, for example, a fused swap gate that swaps the most significant (number of global quantum bits) quantum bits of the local quantum bits with the global quantum bit to the output circuit C.
- a fused swap gate that swaps local quantum bits 4 and 5 with global quantum bits 0 and 3 to the output circuit C, as shown in table 1400.
- the information processing device 100 adds a swap gate that rearranges the local quantum bits in order to the output circuit C.
- the information processing device 100 specifically adds two swap gates that rearrange the local quantum bits 0, 1, and 2 in order to the output circuit C, as shown in table 1400. This allows the information processing device 100 to appropriately swap multiple quantum bits so as to return the qubit order ⁇ to the initial state.
- FIGS. 15 to 18 are explanatory diagrams showing a specific example of the operation of the information processing device 100.
- the information processing device 100 receives an input of a quantum circuit 1500.
- the quantum circuit 1500 includes gates 1510 to 1518.
- the information processing device 100 generates a DAG 1520 corresponding to the quantum circuit 1500.
- the DAG 1520 includes nodes 1530 to 1538 that respectively represent the gates 1510 to 1518.
- the information processing device 100 identifies nodes 1530-1532 that represent gates that are not related to global quantum bits and do not generate inter-process communication, based on the qubit order ⁇ . Based on the DAG 1520, the information processing device 100 identifies, among the identified nodes 1530-1532, nodes 1530-1532 that are not connected to directed edges starting from other nodes and represent gates that can be executed without depending on other gates. The information processing device 100 removes the identified nodes 1530-1532 from the DAG 1520. The information processing device 100 adds gates 1610-1612 represented by the identified nodes 1530-1532 to the output circuit 1600.
- Qlocal' ⁇ 2, 3, 4 ⁇
- the information processing device 100 identifies nodes 1533 to 1536 that represent gates that are not related to a global quantum bit and do not generate inter-process communication, based on the latest qubit order ⁇ . Based on the latest DAG 1520, the information processing device 100 identifies nodes 1533 and 1534 out of the identified nodes 1533 to 1536, which are not connected to a directed edge starting from another node and represent gates that can be executed without depending on other gates. The information processing device 100 removes the identified nodes 1533 and 1534 from the DAG 1520. The information processing device 100 adds gates 1700 and 1701 represented by the identified nodes 1533 and 1534 to the output circuit 1600.
- the information processing device 100 identifies nodes 1535, 1536 that represent gates that are not related to a global quantum bit and do not generate inter-process communication, based on the latest qubit order ⁇ . Based on the latest DAG 1520, the information processing device 100 identifies node 1535, 1536 that has no directed edges starting from other nodes connected thereto and represents a gate that can be executed without depending on other gates. The information processing device 100 removes the identified node 1535 from the DAG 1520. The information processing device 100 adds gate 1702 represented by the identified node 1535 to the output circuit 1600.
- the information processing device 100 identifies, based on the latest qubit order ⁇ , a node 1536 that represents a gate that is not related to a global quantum bit and does not generate inter-process communication. Based on the latest DAG 1520, the information processing device 100 identifies, from among the identified nodes 1536, a node 1536 that is not connected to a directed edge starting from another node and represents a gate that can be executed without depending on other gates. The information processing device 100 removes the identified node 1536 from the DAG 1520. The information processing device 100 adds a gate 1702 represented by the identified node 1536 to the output circuit 1600.
- Qlocal' ⁇ 0, 1, 2 ⁇
- the information processing device 100 identifies nodes 1537, 1538 that are not related to a global quantum bit and that do not generate inter-process communication, based on the latest qubit order ⁇ . Based on the latest DAG 1520, the information processing device 100 identifies node 1537, of the identified nodes 1537, 1538, which is not connected to a directed edge starting from another node and represents a gate that can be executed without depending on other gates. The information processing device 100 removes the identified node 1537 from the DAG 1520. The information processing device 100 adds gate 1801 represented by the identified node 1537 to the output circuit 1600.
- the information processing device 100 identifies, based on the latest qubit order ⁇ , a node 1538 that represents a gate that is not related to a global quantum bit and does not generate inter-process communication. Based on the latest DAG 1520, the information processing device 100 identifies, from among the identified nodes 1538, a node 1538 that is not connected to a directed edge starting from another node and represents a gate that can be executed without depending on other gates. The information processing device 100 removes the identified node 1538 from the DAG 1520. The information processing device 100 adds a gate 1802 represented by the identified node 1538 to the output circuit 1600.
- the information processing device 100 detects that the DAG 1520 has become empty. Because the DAG 1520 has become empty, the information processing device 100 adds a swap gate 1810 to the output circuit 1600 to return the qubit order ⁇ to its initial state. This allows the information processing device 100 to generate an output circuit 1600 that is logically equivalent to the quantum circuit 1500 that received the input, with a reduced number of inter-process communications occurring or a reduced amount of communication.
- FIG. 19 is an explanatory diagram showing a first application example of the information processing device 100.
- the quantum circuit 1900 includes gates 1910 to 1913.
- the gates 1910 to 1913 are general-purpose gates.
- the amount of inter-process communication that occurs in the quantum circuit 1900 is, for example, 7M.
- M is 2 ⁇ (the number of local quantum bits).
- Quantum circuit 1920 that is logically equivalent to quantum circuit 1900.
- Quantum circuit 1920 includes gates 1930-1933 that correspond to gates 1910-1913, respectively.
- Quantum circuit 1920 includes swap gate 1940, fused swap gate 1950, and swap gates 1960-1962. This allows the information processing device 100 to reduce the amount of inter-process communication in quantum circuit 1920 to 2.75M.
- 20 and 21 are explanatory diagrams showing a second application example of the information processing device 100.
- the information processing device 100 is applied to a quantum circuit of the Qulacs benchmark.
- the information processing device 100 performs optimization of the quantum circuit as described above under the measurement conditions shown in Table 2000, and measures the processing time required to perform a series of operations defined in the quantum circuit.
- the processing time measured by the information processing device 100 may be referred to as the "processing time of 'w/ our opt.'".
- the processing time of "w/o opt.” and the processing time of "w/ existing opt.” are adopted.
- the processing time for "w/o opt.” is the processing time when no optimization is performed on the quantum circuit.
- the processing time for "w/ existing opt.” is the processing time when conventional optimization is performed on the quantum circuit.
- Graph 2100 in FIG. 21 shows the processing time of "w/ our opt.”, the processing time of "w/o opt.”, and the processing time of "w/ existing opt.”.
- the information processing device 100 can achieve 1.84 times faster update time than "w/o opt.”.
- the information processing device 100 can achieve 1.16 times faster update time than "w/ existing opt.”.
- the information processing device 100 can achieve a speedup of 1.72 times the overall time compared to "w/o opt.”.
- the information processing device 100 can achieve a speedup of 1.35 times the overall time compared to "w/existing opt.”. In this way, the information processing device 100 can reduce the processing time required to perform a series of operations defined in a quantum circuit compared to conventional methods.
- FIG. 22 and 23 are explanatory diagrams showing a third application example of the information processing device 100.
- the information processing device 100 optimizes the quantum circuit as described above under the measurement conditions shown in Table 2200, and measures the processing time required to perform a series of operations defined in the quantum circuit.
- the processing time measured by the information processing device 100 may be referred to as the "processing time for 'w/ fused-swap'".
- the information processing device 100 uses gate fusion optimization to optimize the quantum circuit as described above under the measurement conditions shown in Table 2200, and measures the processing time required to perform a series of operations defined in the quantum circuit.
- the processing time measured by the information processing device 100 using gate fusion optimization may be referred to as "processing time with 'w/ fused-swap and gate fusion'".
- Gate fusion optimization is a technique that, when there are multiple gates that reference the same quantum bit, aims to reduce the number of times vector components are updated by replacing the multiple gates with a gate whose representation matrix is the product of the representation matrices of the multiple gates.
- the processing time for "w/o opt.” is the processing time when no optimization is performed on the quantum circuit.
- the processing time for "w/ gate fusion” is the processing time when conventional optimization using gate fusion is performed on the quantum circuit.
- Graph 2300 in FIG. 23 shows the processing time for "w/ fused-swap", the processing time for "w/ fused-swap and gate fusion", the processing time for "w/o opt.”, and the processing time for "w/ gate fusion”.
- the information processing device 100 can reduce the processing time to approximately 1/8 compared to "w/o opt.” and "w/ existing opt.”.
- Graph 2310 in FIG. 23 shows the communication time for "w/ our opt.”, the communication time for "w/ fused-swap and gate fusion", the communication time for "w/o opt.”, and the communication time for "w/ existing opt.”.
- the information processing device 100 can be applied, for example, to the field of drug discovery. Specifically, in the field of drug discovery, the information processing device 100 can be applied when simulating the movement of atoms forming a substance by using multiple quantum bits in order to analyze the properties of the substance.
- the overall processing is realized by, for example, the CPU 301, storage areas such as the memory 302 and the recording medium 305, and the network I/F 303 shown in Fig. 3.
- FIG. 24 is a flowchart showing an example of the overall processing procedure.
- the information processing device 100 acquires a quantum circuit I (step S2401).
- the information processing device 100 generates a directed acyclic graph G corresponding to the acquired quantum circuit I, and generates an empty output circuit C (step S2402).
- the information processing device 100 selects a gate g that has not yet been selected from among the gates g represented by each node n of the acyclic directed graph G (step S2403). Based on the qubit order ⁇ , the information processing device 100 determines whether the selected gate g satisfies a predetermined condition that it is executable and that no inter-process communication occurs (step S2404).
- step S2404: No If the specified condition is not met (step S2404: No), the information processing device 100 proceeds to step S2406. On the other hand, if the specified condition is met (step S2404: Yes), the information processing device 100 proceeds to step S2405.
- step S2405 the information processing device 100 removes the node n representing the selected gate g from the acyclic directed graph G, sets the selected gate g so that it conforms to the qubit order ⁇ , and adds it to the output circuit C (step S2405).
- the information processing device 100 proceeds to the process of step S2406.
- step S2406 the information processing device 100 determines whether or not all of the gates g represented by each node n in the acyclic directed graph G have been selected (step S2406). If there are any gates g that have not been selected (step S2406: No), the information processing device 100 returns to the processing of step S2403. On the other hand, if all of the gates g have been selected (step S2406: Yes), the information processing device 100 proceeds to the processing of step S2407.
- the information processing device 100 determines whether the acyclic directed graph G is empty (step S2410). If the acyclic directed graph G is not empty (step S2410: No), the information processing device 100 returns to the processing of step S2403. On the other hand, if the acyclic directed graph G is empty (step S2410: Yes), the information processing device 100 proceeds to the processing of step S2411.
- step S2411 the information processing device 100 sets the division information ⁇ between the global and local quantum bits to the initial state (step S2411).
- the information processing device 100 adds one or more swap gates s that swap the global and local quantum bits to the output circuit C so as to match the division information ⁇ between the global and local quantum bits (step S2412).
- the information processing device 100 ends the entire process.
- the information processing device 100 can obtain a first quantum circuit that specifies, in a time series, a plurality of gates that represent the execution of operations on one or more different quantum bits for a plurality of quantum bits.
- the information processing device 100 can generate an acyclic directed graph that includes nodes that represent each of the plurality of gates and directed edges that represent the execution order of operations between the gates represented by the different nodes, based on the obtained first quantum circuit.
- the information processing device 100 can identify, based on the generated acyclic directed graph, one or more quantum bits that are referenced by one or more first gates that generate inter-process communication and that can be executed independently of other gates among the plurality of gates.
- each time one or more quantum bits are identified one or more second gates that can be executed independently of other gates and do not generate inter-process communication among the multiple gates can be identified based on the acyclic directed graph.
- each time one or more second gates are identified a node representing each of the identified one or more second gates can be removed from the acyclic directed graph.
- each time one or more quantum bits are identified one or more swap gates that swap local quantum bits with global quantum bits can be added to the template circuit so that the identified one or more quantum bits become local.
- each time one or more second gates are identified the identified one or more second gates can be added to the template circuit. This allows the information processing device 100 to appropriately generate the second quantum circuit in stages.
- the information processing device 100 before initially identifying one or more quantum bits, it is possible to once identify, among a plurality of gates, one or more second gates that can be executed independently of other gates and that do not generate inter-process communication, based on the acyclic directed graph. This allows the information processing device 100 to appropriately generate a second quantum circuit that includes one or more second gates at the beginning.
- the information processing device 100 when one or more quantum bits are identified, it is possible to determine whether the number of quantum bits to be swapped is four or more based on the identified one or more quantum bits. According to the information processing device 100, if the number is four or more, one or more swap gates including a fused swap gate can be added to the template circuit so that the identified one or more quantum bits are local. This allows the information processing device 100 to reduce the number of times inter-process communication occurs or the amount of communication.
- the information processing device 100 it is possible to identify multiple combinations of gates in which inter-process communication occurs, based on the acyclic directed graph, that reference one or more quantum bits that are below the upper limit of local quantum bits and that can be executed without relying on other gates. According to the information processing device 100, it is possible to identify one or more quantum bits referenced by one or more first gates in which inter-process communication occurs, which is the combination that includes the largest number of gates among the multiple combinations. This allows the information processing device 100 to appropriately identify one or more quantum bits.
- the information processing method described in this embodiment can be realized by executing a prepared program on a computer such as a PC or a workstation.
- the information processing program described in this embodiment is recorded on a computer-readable recording medium and is executed by the computer reading it from the recording medium.
- Recording media include hard disks, flexible disks, CD (Compact Disc)-ROMs, MO (Magneto Optical discs), DVDs (Digital Versatile Discs), etc.
- the information processing program described in this embodiment may also be distributed via a network such as the Internet.
- a first quantum circuit is obtained that defines a plurality of gates in a time series, each gate representing an operation performed on one or more different quantum bits, for a plurality of quantum bits including one or more local quantum bits and one or more global quantum bits; Based on the acquired first quantum circuit, generate an acyclic directed graph including nodes representing each of the plurality of gates and directed edges representing an execution order of operations between the gates represented by different nodes; Identifying one or more quantum bits referenced by one or more first gates in which inter-process communication occurs, each of which references one or more quantum bits that are equal to or smaller than a local quantum bit upper limit and that can be executed independently of other gates, among the plurality of gates, based on the generated acyclic directed graph; generating a second quantum circuit that is logically equivalent to the first quantum circuit, the second quantum circuit including one or more swap gates immediately before the one or more first gates that swap local quantum bits with global quantum bits so that the one or more identified quantum bits become local;
- An information processing program that causes a computer to execute
- the process of generating the second quantum circuit includes: Each time the one or more quantum bits are identified, one or more swap gates are added to a template circuit to swap local quantum bits with global quantum bits so that the identified one or more quantum bits are local, and each time the one or more second gates are identified, the one or more identified second gates are added to the template circuit to generate the second quantum circuit.
- the process of identifying the one or more second gates includes: Before initially identifying the one or more quantum bits, one or more second gates among the plurality of gates are identified based on the acyclic directed graph, each of which can be executed independently of other gates and does not generate inter-process communication.
- the process of generating the second quantum circuit includes: When the acyclic directed graph is empty, the second quantum circuit is generated by adding one or more swap gates to the end of the template circuit to swap local quantum bits with global quantum bits so that one or more quantum bits that are local in the initial state return to local, and the process of generating the second quantum circuit is terminated.
- the process of generating the second quantum circuit includes: When the one or more quantum bits are identified, if the number of quantum bits to be swapped based on the identified one or more quantum bits is four or more, one or more swap gates including a fused swap gate are added to the template circuit to swap local quantum bits with global quantum bits so that the identified one or more quantum bits become local.
- the information processing program according to any one of appendices 2 to 4,
- the process of identifying one or more quantum bits includes: The information processing program according to any one of appendices 2 to 4, characterized in that, based on the acyclic directed graph, a gate that can be executed independently of other gates and that generates inter-process communication is selected from among the plurality of gates, and each time the gate is selected, the quantum bit related to the gate is added to a group. This process is repeated within a range in which the number of quantum bits included in the group does not exceed an upper limit for local quantum bits, and then one or more quantum bits included in the group are identified.
- the process of identifying one or more quantum bits includes: The information processing program according to any one of appendices 2 to 4, characterized in that, based on the acyclic directed graph, one or more quantum bits referenced by one or more first gates in which inter-process communication occurs are identified, which is a combination including the largest number of gates among a plurality of combinations of gates in which inter-process communication occurs, and which reference one or more quantum bits that are equal to or less than an upper limit of a local quantum bit and that can be executed without depending on other gates among the plurality of gates.
- a first quantum circuit is obtained that defines a plurality of gates in a time series, each of which represents an operation performed on one or more different quantum bits, for a plurality of quantum bits including one or more local quantum bits and one or more global quantum bits; Based on the acquired first quantum circuit, generate an acyclic directed graph including nodes representing each of the plurality of gates and directed edges representing an execution order of operations between the gates represented by different nodes; Identifying one or more quantum bits referenced by one or more first gates in which inter-process communication occurs, each of which references one or more quantum bits that are equal to or smaller than a local quantum bit upper limit and that can be executed independently of other gates, among the plurality of gates, based on the generated acyclic directed graph; generating a second quantum circuit that is logically equivalent to the first quantum circuit, the second quantum circuit including one or more swap gates immediately before the one or more first gates that swap local quantum bits with global quantum bits so that the one or more identified quantum bits become local;
- a first quantum circuit is obtained that defines a plurality of gates in a time series, each gate representing an operation performed on one or more different quantum bits, for a plurality of quantum bits including one or more local quantum bits and one or more global quantum bits; Based on the acquired first quantum circuit, generate an acyclic directed graph including nodes representing each of the plurality of gates and directed edges representing an execution order of operations between the gates represented by different nodes; Identifying one or more quantum bits referenced by one or more first gates in which inter-process communication occurs, each of which references one or more quantum bits that are equal to or smaller than a local quantum bit upper limit and that can be executed independently of other gates, among the plurality of gates, based on the generated acyclic directed graph; generating a second quantum circuit that is logically equivalent to the first quantum circuit, the second quantum circuit including one or more swap gates immediately before the one or more first gates that swap local quantum bits with global quantum bits so that the one or more identified quantum bits become local;
- An information processing device comprising a control unit
- Information processing device 110 First quantum circuit 121 to 123, 910 to 913, 1010 to 1013, 1510 to 1518, 1610 to 1612, 1700 to 1702, 1801, 1802, 1910 to 1913, 1930 to 1933 Gate 130, 1020, 1520 Acyclic directed graph 141 to 143, 1030 to 1033, 1530 to 1538 Node 150 Second quantum circuit 160, 930, 950, 1620, 1810, 1940, 1960 to 1962 Swap gate 200 Information processing system 201 Processing device 202 Client device 210 Network 300 Bus 301 CPU 302 Memory 303 Network I/F 304 Recording medium I/F 305 Recording medium 400 Storage unit 401 Acquisition unit 402 First generation unit 403 First identification unit 404 Second identification unit 405 Second generation unit 406 Simulation unit 407 Output unit 500 State vector 510, 900, 920, 940, 1000, 1500, 1900, 1920 Quantum circuit 600 Quantum bit string 710, 711, 720, 721, 800, 1100, 1200, 1210, 1300, 1400, 2000, 2200 Table
Landscapes
- Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- Mathematical Analysis (AREA)
- Data Mining & Analysis (AREA)
- Evolutionary Computation (AREA)
- Condensed Matter Physics & Semiconductors (AREA)
- Computational Mathematics (AREA)
- Mathematical Optimization (AREA)
- Pure & Applied Mathematics (AREA)
- Computing Systems (AREA)
- General Engineering & Computer Science (AREA)
- Mathematical Physics (AREA)
- Software Systems (AREA)
- Artificial Intelligence (AREA)
- Optical Modulation, Optical Deflection, Nonlinear Optics, Optical Demodulation, Optical Logic Elements (AREA)
Abstract
【課題】演算を効率よく実施し易くすること。 【解決手段】情報処理装置100は、n個の量子ビットに関する第1量子回路110を取得する。情報処理装置100は、取得した第1量子回路110に基づいて、非巡回有向グラフ(Directed Acyclic Graph)130を生成する。情報処理装置100は、他のゲートに依存せずに実行可能な、全体としてローカルな量子ビットの上限以下の量子ビットを参照する、それぞれプロセス間通信が発生する1以上のゲートを特定する。情報処理装置100は、第1量子回路110と論理的に等価な第2量子回路150を生成する。第2量子回路150は、少なくとも、特定した1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、特定した1以上のゲートの直前に含む。
Description
本発明は、情報処理プログラム、情報処理方法、および情報処理装置に関する。
従来、複数の量子ビットのそれぞれの量子ビットが表す量子状態の組み合わせを、ベクトル形式で表現する技術がある。例えば、量子ビットが2つ存在する場合、それぞれの量子ビットが表す量子状態の組み合わせが、「00」である確率と「01」である確率と「10」である確率と「11」である確率とを、それぞれ成分として有するベクトルを記憶することがある。また、ベクトルのそれぞれの成分を、複数のプロセスで分担して取り扱う場合がある。この場合、1以上の量子ビットに対して所定の演算を実施する際、異なる成分を担当する複数のプロセスにおいて、プロセス間通信が発生することがある。
先行技術としては、例えば、動作に関係するグローバルな量子ビットと、ローカルな量子ビットとを交換するものがある。
しかしながら、従来技術では、量子回路が表す、それぞれ異なる1以上の量子ビットに対する一連の演算を、効率よく実施することが難しい。例えば、プロセス間通信が発生すると、一連の演算を実施する際にかかる処理負担および処理時間の増大化を招く。
1つの側面では、本発明は、演算を効率よく実施し易くすることを目的とする。
1つの実施態様によれば、ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する情報処理プログラム、情報処理方法、および情報処理装置が提案される。
一態様によれば、演算を効率よく実施し易くすることが可能になる。
以下に、図面を参照して、本発明にかかる情報処理プログラム、情報処理方法、および情報処理装置の実施の形態を詳細に説明する。
(実施の形態にかかる情報処理方法の一実施例)
図1は、実施の形態にかかる情報処理方法の一実施例を示す説明図である。情報処理装置100は、量子回路が表す、それぞれ異なる1以上の量子ビットに対する一連の演算を、効率よく実施し易くするためのコンピュータである。情報処理装置100は、例えば、サーバ、または、PC(Personal Computer)などである。
図1は、実施の形態にかかる情報処理方法の一実施例を示す説明図である。情報処理装置100は、量子回路が表す、それぞれ異なる1以上の量子ビットに対する一連の演算を、効率よく実施し易くするためのコンピュータである。情報処理装置100は、例えば、サーバ、または、PC(Personal Computer)などである。
ここで、量子回路が表す、それぞれ異なる1以上の量子ビットに対する一連の演算を、例えば、量子コンピュータを模擬する量子シミュレータ上で実施することがある。演算は、例えば、量子回路内のゲートによって示される。この際、複数の量子ビットのそれぞれの量子ビットが表す量子状態の組み合わせを、ベクトル形式で表現することがある。量子状態の組み合わせを表現するベクトルは、例えば、ステートベクトルとも呼ばれる。そして、1以上の量子ビットに対する演算を実施する都度、ベクトルの少なくともいずれかの成分を参照および更新する。
ここで、量子ビットの数が増大するほど、ベクトルの成分の数が増大することになる。このため、ベクトルのそれぞれの成分を、複数のプロセスで分担して取り扱う場合がある。複数のプロセスのうち、2以上のプロセスは、例えば、それぞれ異なるコンピュータ上に存在する。複数のプロセスのうち、2以上のプロセスは、例えば、同一のコンピュータ上に存在してもよい。この場合、1以上の量子ビットに対して所定の演算を実施する際、異なる成分を担当する複数のプロセスにおいて、プロセス間通信が発生することがある。プロセス間通信が発生する2以上のプロセスが、それぞれ異なるコンピュータ上に存在する場合、さらに、ネットワーク通信が発生することがある。
例えば、量子ビットa,bが存在する場合、量子ビットa,bが表す量子状態の組み合わせが、「00」である確率と「01」である確率と「10」である確率と「11」である確率とを、それぞれ成分として有するベクトルを記憶することになる。上記「**」のうち、左側の値は、量子ビットaが表す量子状態に対応し、右側の値は、量子ビットbが表す量子状態に対応する。この場合、例えば、量子ビットa,bが表す量子状態の組み合わせが、「00」である確率と「01」である確率とを、プロセスαが担当することが考えられる。また、例えば、量子ビットa,bが表す量子状態の組み合わせが、「10」である確率と「11」である確率とを、プロセスβが担当することが考えられる。
ここで、例えば、量子ビットaに対するXゲートの演算を実施する際、量子ビットa,bが表す量子状態の組み合わせが、「00」である確率と「10」である確率とを入れ替え、かつ、「01」である確率と「11」である確率とを入れ替えることが望まれる。この際には、「00」である確率と「10」である確率とを、それぞれ異なるプロセスが担当し、かつ、「01」である確率と「11」である確率とを、それぞれ異なるプロセスが担当するため、プロセス間通信が発生することになる。
一方で、例えば、量子ビットbに対するXゲートの演算を実施する際、量子ビットa,bが表す量子状態の組み合わせが、「00」である確率と「01」である確率とを入れ替え、かつ、「10」である確率と「11」である確率とを入れ替えることが望まれる。この際には、「00」である確率と「01」である確率とを、同一のプロセスが担当し、かつ、「10」である確率と「11」である確率とを、同一のプロセスが担当するため、プロセス間通信が発生しないことになる。
以下の説明では、プロセス間通信が発生する要因となる量子ビットを「グローバルな量子ビット」と表記する場合がある。上述した一例では、具体的には、量子ビットaが、グローバルな量子ビットである。また、以下の説明では、プロセス間通信が発生する要因とならない量子ビットを「ローカルな量子ビット」と表記する場合がある。上述した一例では、具体的には、量子ビットbが、ローカルな量子ビットである。
従来では、上述したグローバルな量子ビットに起因して、量子回路が表す、それぞれ異なる1以上の量子ビットに対する一連の演算を、効率よく実施することが難しいという問題がある。例えば、いずれかの演算を実施する際に、プロセス間通信が発生すると、一連の演算を実施する際にかかる処理負担および処理時間の増大化を招く。具体的には、いずれかの演算を実施する際に、プロセス間通信に伴いネットワーク通信が発生すると、一連の演算を実施する際にかかる処理負担および処理時間の増大化を招く。
これに対し、例えば、一連の演算のうち、プロセス間通信が発生する演算の直前に、ローカルな量子ビットとグローバルな量子ビットとを入れ替える演算を追加するよう、量子回路を、作業者が人手で更新する場合が考えられる。この場合、作業者にかかる作業負担の増大化を招くという問題があり、一連の演算を実施する際にかかる処理負担および処理時間の低減化を図ることが難しいことがある。
また、従来では、2以上のローカルな量子ビットと2以上のグローバルな量子ビットとを入れ替える演算を追加するよう、量子回路を効率よく自動で更新する手法が提案されていない。このため、一連の演算を実施する際にかかる処理負担および処理時間の低減化を図ることが難しいことがある。
そこで、本実施の形態では、1以上の量子ビットに対する演算を効率よく実施し易くすることができる情報処理方法について説明する。
図1において、ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットが存在する。例えば、n個の量子ビットが存在する。
n個の量子ビットのうち、m個の量子ビットが、ローカルな量子ビットに設定される。例えば、n個の量子ビットを順に並べた場合の下位m個の量子ビットが、ローカルな量子ビットに設定される。n個の量子ビットのうち、p個の量子ビットは、グローバルな量子ビットに設定される。例えば、n個の量子ビットを順に並べた場合の上位p個の量子ビットが、グローバルな量子ビットに設定される。n=m+pである。
n個の量子ビットのそれぞれの量子ビットが表す量子状態の組み合わせの確率を表す成分は、2^n個存在する。2^n個の成分は、2^p個のプロセスで分担される。2^p個のプロセスは、それぞれ、2^m個の成分を担当する。2^p個のプロセスは、具体的には、それぞれ、上位p個の量子ビットのそれぞれの量子ビットが表す量子状態のいずれか1つの組み合わせが、重複なく割り当てられる。2^p個のプロセスは、具体的には、それぞれ、n個の量子ビットのそれぞれの量子ビットが表す量子状態の組み合わせのうち、自プロセスに割り当てられた組み合わせを含む組み合わせの確率を表す2^m個の成分を担当する。
図1の例では、具体的には、量子ビット0~3が存在するとする。ここで、n=4である。m=2である。p=2である。例えば、量子ビット0,1が、ローカルな量子ビットに設定される。例えば、量子ビット2,3が、グローバルな量子ビットに設定される。量子ビット0~3の量子状態の組み合わせの確率を表す成分は、16個存在する。16個の成分は、4個のプロセスで分担される。4個のプロセスは、それぞれ、4個の成分を担当する。
4個のプロセスは、具体的には、量子ビット0~3の量子状態の組み合わせが、「00**」である確率を表す4個の成分を担当するプロセス1を含む。*は、0と1とのいずれの値であってもよい部分を示す。4個のプロセスは、具体的には、量子ビット0~3の量子状態の組み合わせが、「01**」である確率を表す4個の成分を担当するプロセス2を含む。4個のプロセスは、具体的には、量子ビット0~3の量子状態の組み合わせが、「10**」である確率を表す4個の成分を担当するプロセス3を含む。4個のプロセスは、具体的には、量子ビット0~3の量子状態の組み合わせが、「11**」である確率を表す4個の成分を担当するプロセス4を含む。
(1-1)情報処理装置100は、n個の量子ビットに関する第1量子回路110を取得する。図1の例では、具体的には、n=4であるとする。図1の例では、具体的には、第1量子回路110は、4個の量子ビットに関して、複数のゲート121~123を、時系列に沿って規定した情報である。ゲート121~123は、それぞれ、1以上の量子ビットに対して演算を実施することを表す情報である。
(1-2)情報処理装置100は、取得した第1量子回路110に基づいて、非巡回有向グラフ(DAG:Directed Acyclic Graph)130を生成する。非巡回有向グラフ130は、ゲート121~123をそれぞれ表すノード141~143と、ゲート121~123についてゲート間の演算の実施順序を表す有向エッジとを含む。有向エッジは、例えば、連続する2つの演算のうち、先に実施する演算に対応するノードを始点とし、後に実施する演算に対応するノードを終点とする。
(1-3)情報処理装置100は、他のゲートに依存せずに実行可能な、全体としてローカルな量子ビットの上限以下の量子ビットを参照する、それぞれプロセス間通信が発生する1以上のゲートを特定する。情報処理装置100は、特定した1以上のゲートが全体として参照する1以上の量子ビットを特定する。
上限は、ローカルに設定可能な量子ビットの最大数である。図1の例では、上限は、具体的には、2である。他のゲートに依存せずに実行可能とは、例えば、1以上のゲートが、全体として他のゲートに依存せずに実行可能であることを示す。他のゲートに依存せずに実行可能とは、具体的には、1以上のゲートに含まれない他のゲートを始点とする有向エッジが、1以上のゲートのいずれのゲートにも接続されない状態を示す。
図1の例では、情報処理装置100は、具体的には、非巡回有向グラフ130に基づいて、他のゲートに依存せずに実行可能な、上限以下の2つの量子ビットを参照する、プロセス間通信が発生する1以上のゲートとして、ゲート121を特定する。情報処理装置100は、ゲート121が参照する量子ビット0,2を特定する。
(1-4)情報処理装置100は、第1量子回路110と論理的に等価な第2量子回路150を生成する。第2量子回路150は、少なくとも、特定した1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、特定した1以上のゲートの直前に含む。1以上のスワップゲートは、例えば、2つの量子ビットを入れ替える単一スワップゲート、または、4つ以上の量子ビットを入れ替えるフューズドスワップゲートを含む。
図1の例では、情報処理装置100は、具体的には、空の雛型回路を用意する。情報処理装置100は、具体的には、雛型回路に対して、スワップゲート160を追加し、スワップゲート160の次に、特定したゲート121を追加する。スワップゲート160は、例えば、ローカルな量子ビット1と、グローバルな量子ビット2とを入れ替える。情報処理装置100は、雛型回路に対して、ゲート122と、ゲート123とを追加する。情報処理装置100は、雛型回路を、第2量子回路150として採用する。
これにより、情報処理装置100は、第1量子回路110と論理的に等価な、第1量子回路110よりもプロセス間通信が発生する回数、または、通信量が少ない第2量子回路150を生成することができる。これにより、情報処理装置100は、それぞれ異なる1以上の量子ビットに対する一連の演算を、効率よく実施し易くすることができる。情報処理装置100は、例えば、一連の演算を実施する際にかかる処理負担および処理時間の低減化を図ることができる。
(1-5)情報処理装置100は、生成した第2量子回路150に従って、複数のプロセスを制御し、第2量子回路150に規定された一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを実施する。プロセスは、例えば、情報処理装置100が有していてもよい。情報処理装置100は、シミュレーションを実施した結果を、利用者が参照可能に出力する。これにより、情報処理装置100は、シミュレーションを実施した結果を、利用者が利用可能にすることができる。
ここでは、情報処理装置100が、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生する1以上のゲートを特定する場合について説明したが、これに限らない。例えば、情報処理装置100が、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上のゲートを特定する場合があってもよい。この場合、情報処理装置100は、具体的には、空の雛型回路に対して、特定したそれぞれプロセス間通信が発生しない1以上のゲートを追加した後に、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生する1以上のゲートを特定してもよい。この場合の一例については、具体的には、図5~図18を用いて後述する。
ここでは、情報処理装置100が、ゲート121の直前にのみ、1以上のスワップゲートを含む第2量子回路150を生成する場合について説明したが、これに限らない。例えば、情報処理装置100が、ゲート121の直前の他、ゲート122の直前にも、1以上のスワップゲートを含む第2量子回路150を生成する場合があってもよい。この場合の一例については、具体的には、図5~図18を用いて後述する。
ここでは、情報処理装置100が、単独で動作する場合について説明したが、これに限らない。例えば、情報処理装置100が、他のコンピュータと協働する場合があってもよい。具体的には、情報処理装置100が、複数のプロセスを有する他のコンピュータに、第2量子回路150を送信する場合があってもよい。複数のプロセスは、異なるコンピュータが有していてもよい。例えば、複数のコンピュータが、協働で情報処理装置100としての機能を実現する場合があってもよい。具体的には、クラウド上に、情報処理装置100としての機能が実現される場合があってもよい。
(情報処理システム200の一例)
次に、図2を用いて、図1に示した情報処理装置100を適用した、情報処理システム200の一例について説明する。
次に、図2を用いて、図1に示した情報処理装置100を適用した、情報処理システム200の一例について説明する。
図2は、情報処理システム200の一例を示す説明図である。図2において、情報処理システム200は、情報処理装置100と、1以上の演算処理装置201と、1以上のクライアント装置202とを含む。
情報処理システム200において、情報処理装置100と演算処理装置201とは、有線または無線のネットワーク210を介して接続される。ネットワーク210は、例えば、LAN(Local Area Network)、WAN(Wide Area Network)、インターネットなどである。また、情報処理システム200において、情報処理装置100とクライアント装置202とは、有線または無線のネットワーク210を介して接続される。
情報処理装置100は、第1量子回路を生成するためのコンピュータである。情報処理装置100は、n個の量子ビットに関し、一連の演算のそれぞれの演算を表すゲートを時系列に沿って規定した第1量子回路を、クライアント装置202から受信する。情報処理装置100は、受信した第1量子回路と論理的に等価な第2量子回路を生成する。
情報処理装置100は、例えば、n個の量子ビットのうち、ローカルなm個の量子ビットと、グローバルなp個の量子ビットとを設定する。情報処理装置100は、第1量子回路と、ローカルなm個の量子ビットと、グローバルなp個の量子ビットとに基づいて、第2量子回路を生成する。情報処理装置100は、具体的には、図5~図18に後述するように、第2量子回路を生成する。
情報処理装置100は、生成した第2量子回路に従って、一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを分担するよう、複数の演算処理装置201を制御する。情報処理装置100は、例えば、量子状態の組み合わせを表現するベクトルのそれぞれの成分を、複数の演算処理装置201に分散して割り当てる。情報処理装置100は、例えば、第2量子回路を、複数の演算処理装置201に送信することにより、当該演算処理装置201に割り当てられた1以上の成分を更新するよう、複数の演算処理装置201を制御する。
情報処理装置100は、量子状態の組み合わせを表現するベクトルのそれぞれの成分を、複数の演算処理装置201から受信する。情報処理装置100は、受信した量子状態の組み合わせを表現するベクトルのそれぞれの成分に基づいて、一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを実施した結果を生成する。情報処理装置100は、シミュレーションを実施した結果を、クライアント装置202に送信する。情報処理装置100は、例えば、サーバ、または、PCなどである。
演算処理装置201は、一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを分担するためのコンピュータである。演算処理装置201は、量子状態の組み合わせを表現するベクトルの1以上の成分を管理するプロセスを有する。演算処理装置201は、第2量子回路を、情報処理装置100から受信する。演算処理装置201は、第2量子回路に基づいて、他の演算処理装置201と通信し、自装置が管理する1以上の成分を更新する。演算処理装置201は、ベクトルの1以上の成分を、情報処理装置100に送信する。演算処理装置201は、例えば、サーバ、または、PCなどである。
クライアント装置202は、作業者によって用いられるコンピュータである。クライアント装置202は、作業者の操作入力に基づき、第1量子回路の指定を受け付ける。クライアント装置202は、指定の第1量子回路を、情報処理装置100に送信する。クライアント装置202は、シミュレーションを実施した結果を、情報処理装置100から受信する。クライアント装置202は、シミュレーションを実施した結果を、作業者が参照可能に出力する。クライアント装置202は、例えば、PC、タブレット端末、または、スマートフォンなどである。
ここでは、情報処理装置100が、演算処理装置201とは異なる装置である場合について説明したが、これに限らない。例えば、情報処理装置100が、演算処理装置201としての機能を有し、演算処理装置201としても動作する場合があってもよい。ここでは、情報処理装置100が、クライアント装置202とは異なる装置である場合について説明したが、これに限らない。例えば、情報処理装置100が、クライアント装置202としての機能を有し、クライアント装置202としても動作する場合があってもよい。
(情報処理装置100のハードウェア構成例)
次に、図3を用いて、情報処理装置100のハードウェア構成例について説明する。
次に、図3を用いて、情報処理装置100のハードウェア構成例について説明する。
図3は、情報処理装置100のハードウェア構成例を示すブロック図である。図3において、情報処理装置100は、CPU(Central Processing Unit)301と、メモリ302と、ネットワークI/F(Interface)303と、記録媒体I/F304と、記録媒体305とを有する。また、各構成部は、バス300によってそれぞれ接続される。
ここで、CPU301は、情報処理装置100の全体の制御を司る。メモリ302は、例えば、ROM(Read Only Memory)、RAM(Random Access Memory)およびフラッシュROMなどを有する。具体的には、例えば、フラッシュROMやROMが各種プログラムを記憶し、RAMがCPU301のワークエリアとして使用される。メモリ302に記憶されるプログラムは、CPU301にロードされることにより、コーディングされている処理をCPU301に実行させる。
ネットワークI/F303は、通信回線を通じてネットワーク210に接続され、ネットワーク210を介して他のコンピュータに接続される。そして、ネットワークI/F303は、ネットワーク210と内部のインターフェースを司り、他のコンピュータからのデータの入出力を制御する。ネットワークI/F303は、例えば、モデムやLANアダプタなどである。
記録媒体I/F304は、CPU301の制御に従って記録媒体305に対するデータのリード/ライトを制御する。記録媒体I/F304は、例えば、ディスクドライブ、SSD(Solid State Drive)、USB(Universal Serial Bus)ポートなどである。記録媒体305は、記録媒体I/F304の制御で書き込まれたデータを記憶する不揮発メモリである。記録媒体305は、例えば、ディスク、半導体メモリ、USBメモリなどである。記録媒体305は、情報処理装置100から着脱可能であってもよい。
情報処理装置100は、上述した構成部の他、例えば、キーボード、マウス、ディスプレイ、プリンタ、スキャナ、マイク、スピーカーなどを有してもよい。また、情報処理装置100は、記録媒体I/F304や記録媒体305を複数有していてもよい。また、情報処理装置100は、記録媒体I/F304や記録媒体305を有していなくてもよい。
(演算処理装置201のハードウェア構成例)
演算処理装置201のハードウェア構成例は、具体的には、図3に示した情報処理装置100のハードウェア構成例と同様であるため、説明を省略する。
演算処理装置201のハードウェア構成例は、具体的には、図3に示した情報処理装置100のハードウェア構成例と同様であるため、説明を省略する。
(クライアント装置202のハードウェア構成例)
クライアント装置202のハードウェア構成例は、具体的には、図3に示した情報処理装置100のハードウェア構成例と同様であるため、説明を省略する。
クライアント装置202のハードウェア構成例は、具体的には、図3に示した情報処理装置100のハードウェア構成例と同様であるため、説明を省略する。
(情報処理装置100の機能的構成例)
次に、図4を用いて、情報処理装置100の機能的構成例について説明する。
次に、図4を用いて、情報処理装置100の機能的構成例について説明する。
図4は、情報処理装置100の機能的構成例を示すブロック図である。情報処理装置100は、記憶部400と、取得部401と、第1生成部402と、第1特定部403と、第2特定部404と、第2生成部405と、模擬部406と、出力部407とを含む。
記憶部400は、例えば、図3に示したメモリ302や記録媒体305などの記憶領域によって実現される。以下では、記憶部400が、情報処理装置100に含まれる場合について説明するが、これに限らない。例えば、記憶部400が、情報処理装置100とは異なる装置に含まれ、記憶部400の記憶内容が情報処理装置100から参照可能である場合があってもよい。
取得部401~出力部407は、制御部の一例として機能する。取得部401~出力部407は、具体的には、例えば、図3に示したメモリ302や記録媒体305などの記憶領域に記憶されたプログラムをCPU301に実行させることにより、または、ネットワークI/F303により、その機能を実現する。各機能部の処理結果は、例えば、図3に示したメモリ302や記録媒体305などの記憶領域に記憶される。
記憶部400は、各機能部の処理において参照され、または更新される各種情報を記憶する。記憶部400は、例えば、第1量子回路を記憶する。第1量子回路は、複数の量子ビットに関する量子回路である。複数の量子ビットは、ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む。第1量子回路は、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定する。第1量子回路は、例えば、取得部401によって取得される。
記憶部400は、例えば、複数の量子ビットのうち、ローカルな量子ビットと、グローバルな量子ビットとを識別する識別情報を記憶する。ローカルな量子ビットと、グローバルな量子ビットとは、入れ替えることができる。例えば、ある量子ビットを、ローカルからグローバルに変更し、他の量子ビットを、グローバルからローカルに変更することにより、ローカルな量子ビットと、グローバルな量子ビットとを入れ替える。識別情報は、例えば、取得部401によって取得される。
記憶部400は、例えば、第2量子回路を記憶する。第2量子回路は、複数の量子ビットに関する量子回路である。第2量子回路は、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定する。第2量子回路は、第1量子回路と論理的に等価な量子回路である。第2量子回路は、例えば、第2生成部405によって生成される。
取得部401は、各機能部の処理に用いられる各種情報を取得する。取得部401は、取得した各種情報を、記憶部400に記憶し、または、各機能部に出力する。また、取得部401は、記憶部400に記憶しておいた各種情報を、各機能部に出力してもよい。取得部401は、例えば、利用者の操作入力に基づき、各種情報を取得する。取得部401は、例えば、情報処理装置100とは異なる装置から、各種情報を受信してもよい。
取得部401は、例えば、第1量子回路を取得する。取得部401は、具体的には、利用者の操作入力に基づき、第1量子回路の入力を受け付けることにより、第1量子回路を取得する。取得部401は、具体的には、第1量子回路を、他のコンピュータから受信することにより取得する。他のコンピュータは、具体的には、クライアント装置202などである。
取得部401は、例えば、ローカルな量子ビットと、グローバルな量子ビットとを識別する識別情報を取得する。取得部401は、具体的には、利用者の操作入力に基づき、識別情報の入力を受け付けることにより、識別情報を取得する。取得部401は、具体的には、識別情報を、他のコンピュータから受信することにより取得する。他のコンピュータは、具体的には、クライアント装置202などである。
取得部401は、いずれかの機能部の処理を開始する開始トリガーを受け付けてもよい。開始トリガーは、例えば、利用者による所定の操作入力があったことである。開始トリガーは、例えば、他のコンピュータから、所定の情報を受信したことであってもよい。開始トリガーは、例えば、いずれかの機能部が所定の情報を出力したことであってもよい。取得部401は、例えば、第1量子回路を取得したことを、第1生成部402と、第1特定部403と、第2特定部404と、第2生成部405との処理を開始する開始トリガーとして受け付ける。
第1生成部402は、取得した第1量子回路に基づいて、複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成する。これにより、第1生成部402は、ゲート間の依存関係を特定可能にすることができ、第1量子回路の中身を解析し易くすることができる。
第1特定部403は、生成した非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の量子ビットを参照するそれぞれプロセス間通信が発生する1以上の第1ゲートを特定する。第1特定部403は、特定した1以上の第1ゲートが参照する1以上の量子ビットを特定する。
他のゲートに依存せずに実行可能な、1以上の第1ゲートは、例えば、1以上の第1ゲートが、全体として他のゲートに依存せずに実行可能な状態である。他のゲートに依存せずに実行可能な、1以上の第1ゲートは、具体的には、1以上の第1ゲートに含まれない他のゲートを始点とする有向エッジが、1以上の第1ゲートのいずれの第1ゲートにも接続されない状態である。
他のゲートに依存せずに実行可能な、1以上の第1ゲートは、例えば、1以上の第1ゲートのそれぞれの第1ゲートが、他のゲートに依存せずに実行可能な状態であってもよい。他のゲートに依存せずに実行可能な、1以上の第1ゲートは、具体的には、1以上の第1ゲートのそれぞれの第1ゲートについて、当該第1ゲートとは異なる他のゲートを始点とする有向エッジが、当該第1ゲートに接続されない状態であってもよい。
第1特定部403は、例えば、第2特定部404で1以上の第2ゲートを特定する都度、1以上の第1ゲートを特定する。第1特定部403は、具体的には、第2特定部404で非巡回有向グラフを更新する都度、1以上の第1ゲートを特定する。第1特定部403は、例えば、第2特定部404で1以上の第2ゲートが特定されない場合、1以上の第1ゲートを特定してもよい。
第1特定部403は、具体的には、対角行列で表現される演算を実施することを表すゲートを、プロセス間通信が発生しないゲートであると判定する。第1特定部403は、具体的には、グローバルな量子ビットに関連しないゲートを、プロセス間通信が発生しないゲートであると判定する。第1特定部403は、具体的には、対角行列で表現されない演算を実施することを表し、グローバルな量子ビットに関連するゲートを、プロセス間通信が発生するゲートであると判定する。
第1特定部403は、具体的には、非巡回有向グラフと、プロセス間通信が発生するゲートであるか否かを判定した結果とに基づいて、1以上の第1ゲートを特定する。第1特定部403は、より具体的には、他のゲートに依存せずに実行可能なプロセス間通信が発生するゲートから始まり、全体として他のゲートに依存せずに実行可能なそれぞれプロセス間通信が発生する、1以上の第1ゲートを特定する。
第1特定部403は、具体的には、非巡回有向グラフに基づいて、他のゲートに依存せずに実行可能な、プロセス間通信が発生するゲートを順に選択してもよい。第1特定部403は、具体的には、ゲートを選択する都度、当該ゲートに関わる量子ビットを、グループに追加するという処理を、グループに含まれる量子ビットの数が、ローカルな量子ビットの上限を超えない範囲で繰り返し実施する。第1特定部403は、選択済みのゲートを、1以上の第1ゲートとして特定する。第1特定部403は、最終的にグループに含まれる1以上の量子ビットを特定する。
第1特定部403は、具体的には、非巡回有向グラフに基づいて、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、プロセス間通信が発生するゲートの複数の組み合わせを特定してもよい。第1特定部403は、複数の組み合わせのうち、最も多くのゲートを含む組み合わせとなる、それぞれプロセス間通信が発生する1以上のゲートを、1以上の第1ゲートとして特定する。第1特定部403は、特定した1以上の第1ゲートが参照する1以上の量子ビットを特定する。これにより、第1特定部403は、第2量子回路を生成する指針を得ることができる。
第2特定部404は、非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを特定する。
他のゲートに依存せずに実行可能な、1以上の第2ゲートは、例えば、1以上の第2ゲートが、全体として他のゲートに依存せずに実行可能な状態である。他のゲートに依存せずに実行可能な、1以上の第2ゲートは、具体的には、1以上の第2ゲートに含まれない他のゲートを始点とする有向エッジが、1以上の第2ゲートのいずれの第2ゲートにも接続されない状態である。
他のゲートに依存せずに実行可能な、1以上の第2ゲートは、例えば、1以上の第2ゲートのそれぞれの第2ゲートが、他のゲートに依存せずに実行可能な状態であってもよい。他のゲートに依存せずに実行可能な、1以上の第2ゲートは、具体的には、1以上の第2ゲートのそれぞれの第2ゲートについて、当該第2ゲートとは異なる他のゲートを始点とする有向エッジが、当該第2ゲートに接続されない状態であってもよい。
第2特定部404は、例えば、第1特定部403で1以上の量子ビットを最初に特定する前に1以上の第2ゲートを一度特定する。第2特定部404は、例えば、第1特定部403で1以上の量子ビットを特定する都度、1以上の第2ゲートを特定する。
第2特定部404は、具体的には、第1特定部403で1以上の量子ビットを特定し、第2生成部405で雛型回路に1以上のスワップゲートを追加したことに応じて、1以上の第2ゲートを特定する。スワップゲートは、2つの量子ビットを入れ替える単一スワップゲート、または、4つ以上の量子ビットを入れ替えるフューズドスワップゲートである。第2特定部404は、例えば、第1特定部403で1以上の量子ビットが特定されない場合に、1以上の第2ゲートを特定してもよい。
第2特定部404は、具体的には、対角行列で表現される演算を実施することを表すゲートを、プロセス間通信が発生しないゲートであると判定する。第2特定部404は、具体的には、グローバルな量子ビットに関連しないゲートを、プロセス間通信が発生しないゲートであると判定する。第2特定部404は、具体的には、対角行列で表現されない演算を実施することを表し、グローバルな量子ビットに関連するゲートを、プロセス間通信が発生するゲートであると判定する。
第2特定部404は、具体的には、非巡回有向グラフと、プロセス間通信が発生するゲートであるか否かを判定した結果とに基づいて、1以上の第2ゲートを特定する。第2特定部404は、より具体的には、他のゲートに依存せずに実行可能なプロセス間通信が発生しないゲートから始まり、全体として他のゲートに依存せずに実行可能なそれぞれプロセス間通信が発生しない1以上の第2ゲートを特定する。
第2特定部404は、第2特定部404で1以上の第2ゲートを特定する都度、非巡回有向グラフの中から、第2特定部404で今回特定した1以上の第2ゲートのそれぞれの第2ゲートを表すノードを除去するよう、非巡回有向グラフを更新する。これにより、第2特定部404は、特定済みのゲートを判別可能に、第2量子回路を生成する目的に適するよう、非巡回有向グラフを更新することができる。
第2生成部405は、第1量子回路と論理的に等価な第2量子回路を生成する。第2量子回路は、例えば、第1特定部403で特定した1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、第1特定部403で特定した1以上の第1ゲートの直前に含む。
第2生成部405は、例えば、空の雛型回路を用意する。第2生成部405は、例えば、第2特定部404で1以上の第2ゲートを特定する都度、雛型回路に対して、第2特定部404で特定した1以上の第2ゲートを追加する。これにより、第2生成部405は、第2量子回路を、段階的に生成していくことができる。
第2生成部405は、例えば、第1特定部403で1以上の量子ビットを特定する都度、雛型回路に対して、第1特定部403で特定した1以上の量子ビットがローカルになるよう、1以上のスワップゲートを追加する。第2生成部405は、具体的には、入れ替える量子ビットの数が4以上であれば、雛型回路に対して、フューズドスワップゲートを含む1以上のスワップゲートを追加する。これにより、第2生成部405は、第2量子回路を、段階的に生成していくことができる。
第2生成部405は、非巡回有向グラフが空であるか否かを判定する。第2生成部405は、空である場合、雛型回路の末尾に、初期状態でローカルな1以上の量子ビットがローカルに戻るよう、1以上のスワップゲートを追加することにより、第2量子回路を生成する。これにより、第2生成部405は、第2量子回路を完成することができる。
模擬部406は、量子状態の組み合わせを表現するベクトルのそれぞれの成分を分担する複数のプロセスを制御して、第2生成部405で生成した第2量子回路に規定された一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを実施する。プロセスは、情報処理装置100が有していてもよい。プロセスは、他のコンピュータが有していてもよい。他のコンピュータは、例えば、演算処理装置201である。これにより、模擬部406は、一連の演算による量子状態の組み合わせの変化を模擬するシミュレーションを効率よく実施することができる。
出力部407は、少なくともいずれかの機能部の処理結果を出力する。出力形式は、例えば、ディスプレイへの表示、プリンタへの印刷出力、ネットワークI/F303による外部装置への送信、または、メモリ302や記録媒体305などの記憶領域への記憶である。これにより、出力部407は、少なくともいずれかの機能部の処理結果を利用者に通知可能にし、情報処理装置100の利便性の向上を図ることができる。
出力部407は、例えば、第2生成部405で生成した第2量子回路を出力する。出力部407は、具体的には、第2生成部405で生成した第2量子回路を、利用者が参照可能に出力する。出力部407は、具体的には、第2生成部405で生成した第2量子回路を、他のコンピュータに送信してもよい。これにより、出力部407は、第2量子回路を、外部で利用可能にすることができる。
出力部407は、例えば、模擬部406でシミュレーションを実施した結果を出力する。出力部407は、具体的には、模擬部406でシミュレーションを実施した結果を、利用者が参照可能に出力する。出力部407は、具体的には、模擬部406でシミュレーションを実施した結果を、他のコンピュータに送信してもよい。これにより、出力部407は、模擬部406でシミュレーションを実施した結果を、外部で利用可能にすることができる。
(情報処理装置100の動作の流れ)
次に、図5~図9を用いて、情報処理装置100の動作の流れについて説明する。
次に、図5~図9を用いて、情報処理装置100の動作の流れについて説明する。
図5~図9は、情報処理装置100の動作の流れを示す説明図である。図5は、具体的には、量子状態の組み合わせを表現するステートベクトル500の一例を示す。図5において、n個の量子ビットが存在するとする。図5の例では、具体的には、n=4であるとし、量子ビット0~3が存在するとする。情報処理装置100は、量子ビット0~3の量子状態のそれぞれの組み合わせの確率を表す成分を有するステートベクトル500を設定する。
ステートベクトル500は、例えば、量子ビット0~3の量子状態の組み合わせが、「0000」~「1111」のそれぞれである確率を表す成分を有する。以下の説明では、量子ビット0~3の量子状態の組み合わせが、「****」である確率を表す成分を、「c****」と表記する場合がある。*は、0と1とのいずれかの値となる部分を示す。
量子回路510の先頭のゲートから順に、当該ゲートに応じてステートベクトルのそれぞれの成分を更新することにより、量子回路510に規定された一連の演算による量子ビット0~3の量子状態の組み合わせの変化を模擬するシミュレーションが実施される。先頭は、具体的には、左側である。情報処理装置100は、具体的には、ステートベクトルの複数の成分を、複数のプロセスに割り当てて、複数のプロセスを制御することにより、シミュレーションを実施する。次に、図6の説明に移行する。
図6は、ステートベクトルの複数の成分を複数のプロセスに割り当てる一例を示す。図6において、情報処理装置100は、pおよびmの入力を受け付ける。情報処理装置100は、n個の量子ビットを並べた量子ビット列600の上位p個の量子ビットを、グローバルな量子ビットに設定し、量子ビット列600の下位m個の量子ビットを、ローカルな量子ビットに設定する。図6の例では、n=36である。このため、ステートベクトルの成分は、2^n個存在する。
情報処理装置100は、ステートベクトルの2^n個の成分を、2^p個のプロセスに均等に割り当てる。情報処理装置100は、具体的には、ステートベクトルの2^n個の成分を、先頭から、2^m個の成分単位で区切る。情報処理装置100は、具体的には、区切った2^m個の成分を、2^m個の成分ごとに異なるプロセスに割り当てる。このため、グローバルな量子ビットに関連しないゲートが表す演算を実施する場合には、プロセス間通信が発生しないことになる。一方で、グローバルな量子ビットに関連するゲートが表す演算を実施する場合には、プロセス間通信が発生し得る。次に、図7の説明に移行する。
図7は、プロセス間通信が発生する一例を示す。例えば、グローバルな量子ビットに関連し、対角行列で表現されない演算を実施する場合には、プロセス間通信が発生するという性質がある。図7において、対角行列で表現されないXゲートの演算について示す。図7の例では、説明の簡略化のため、n=3であり、量子ビット0~2が存在するとする。また、上位1個の量子ビット2が、グローバルな量子ビットであり、下位2個の量子ビット0,1が、ローカルな量子ビットであるとする。
図7の表710に示す通り、ローカルな量子ビット0に関連するXゲートの演算では、同一のプロセスが担当する、量子ビット0の値のみが異なる成分同士を入れ替えることになる。図7の表710において、sは、成分の値を示す。indexは、成分を識別する識別子を示す。a(***)は、量子状態の組み合わせが「***」である確率を表す成分を識別する識別子である。
入れ替えた後のそれぞれの成分は、図7の表711に示される。図7の表711において、sは、成分の値を示す。indexは、成分を識別する識別子を示す。このように、ローカルな量子ビット0に関連するXゲートの演算では、同一のプロセスが担当する、量子ビット0の値のみが異なる成分同士を入れ替えればよいため、プロセス間通信が発生しないと考えられる。
一方で、図7の表720に示す通り、グローバルな量子ビット2に関連するXゲートの演算では、それぞれ異なるプロセスが担当する、量子ビット2の値のみが異なる成分同士を入れ替えることになる。図7の表720において、sは、成分の値を示す。indexは、成分を識別する識別子を示す。a(***)は、量子状態の組み合わせが「***」である確率を表す成分を識別する識別子である。
入れ替えた後のそれぞれの成分は、図7の表721に示される。図7の表721において、sは、成分の値を示す。indexは、成分を識別する識別子を示す。このように、グローバルな量子ビット2に関連するXゲートの演算では、それぞれ異なるプロセスが担当する、量子ビット2の値のみが異なる成分同士を入れ替えることになるため、プロセス間通信が発生すると考えられる。次に、図8の説明に移行する。
図8の表800は、ゲートの種類の一例を示す。表800のゲート名のフィールドには、ゲートを識別する名称が設定される。表800の要素数のフィールドには、上記名称のゲートが表す演算に関連する要素の数が設定される。ここで、N=2^nである。
表800の演算数/要素のフィールドには、上記名称のゲートが表す演算において、1つの要素を更新する際の複素数の演算の回数が設定される。複素数の演算は、例えば、加算、減算、積算、または、積和などである。
表800のランク間転送量のフィールドには、上記名称のゲートが表す演算が、グローバルな量子ビットに関連する場合に、プロセス間通信により転送する要素の数が設定される。ここで、M=2^(ローカルな量子ビットの数)である。ランク間転送量は、例えば、通信量に対応する。
このように、ゲートの種類によっては、グローバルな量子ビットに関連する演算を実施する際に、プロセス間通信が発生してしまう傾向がある。従って、プロセス間通信に起因し、量子回路に規定された一連の演算を実施する際にかかる処理時間および処理負担の増大化を招くことが考えられる。そこで、情報処理装置100は、量子回路の入力を受け付けた場合、当該量子回路と論理的に等価な、当該量子回路よりもプロセス間通信が発生する回数、または、通信量が抑制された新たな量子回路を生成することにする。
例えば、表800に示す通り、汎用ゲート、Xゲート、または、Yゲートなどに関する通信量よりも、スワップゲートに関する通信量の方が小さくなる傾向がある。このため、情報処理装置100は、具体的には、スワップゲートを利用して、各種ゲートが表す演算において参照する量子ビットを、予めローカルに移動するような、新たな量子回路を生成することにする。次に、図9の説明に移行する。
図9において、情報処理装置100は、量子回路900の入力を受け付けたとする。(9-1)情報処理装置100は、量子回路900の先頭のゲート910が、ローカルな量子ビット0に関連するゲートであり、他のゲートに依存せずに実行可能であるため、そのまま量子回路900に残す。
情報処理装置100は、量子回路900のゲート911が、グローバルな量子ビット2を含む2個以下の量子ビット0,2に関連し、他のゲートに依存せずに実行可能であるため、量子ビット0,2をローカルな量子ビットに設定すると決定する。
(9-2)情報処理装置100は、量子ビット0,2をローカルな量子ビットに設定するため、ゲート912の直前に、スワップゲート930を追加する。これにより、情報処理装置100は、量子回路900を更新し、量子回路920を生成する。情報処理装置100は、スワップゲート930を追加することにより、ゲート911,913でプロセス間通信が発生しないようにすることができる。
(9-3)情報処理装置100は、量子回路920のゲート913が、現在ローカルな量子ビット2に関連するゲートであり、他のゲートに依存せずに実行可能であるため、ゲート912の直後に移動する。情報処理装置100は、量子回路920のゲート912が、現在グローバルな量子ビット1,3を含む2個以下の量子ビット1,3に関連し、他のゲートに依存せずに実行可能であるため、量子ビット1,3を次のローカルな量子ビットに設定すると決定する。
(9-4)情報処理装置100は、量子ビット1,3をローカルな量子ビットに設定するため、ゲート912の直前に、スワップゲート950を追加する。これにより、情報処理装置100は、量子回路920を更新し、量子回路940を生成する。情報処理装置100は、スワップゲート950を追加することにより、ゲート912でプロセス間通信が発生しないようにすることができる。
このように、情報処理装置100は、量子回路900と論理的に等価な、量子回路900よりもプロセス間通信が発生する回数、または、通信量が抑制された量子回路940を得ることができる。情報処理装置100は、量子回路940に従って、複数のプロセスを制御することにより、プロセス間通信が発生する回数、または、通信量を抑制しつつ、量子回路940に規定された一連の演算を効率よく実施することができる。情報処理装置100は、実質的に、入力を受け付けた量子回路900に規定された一連の演算を実施することができる。
(情報処理装置100の動作の一例)
次に、図10~図14を用いて、情報処理装置100の動作の一例について説明する。
次に、図10~図14を用いて、情報処理装置100の動作の一例について説明する。
図10~図14は、情報処理装置100の動作の一例を示す説明図である。図10において、情報処理装置100は、量子回路1000の入力を受け付ける。量子回路1000は、n個の量子ビットに関する。図5の例では、n=4である。量子回路1000は、ゲート1010~1013を含む。量子ビット0,1は、初期状態で、ローカルな量子ビットである。量子ビット2,3は、初期状態で、グローバルな量子ビットである。
情報処理装置100は、量子回路1000に対応するDAG1020を生成する。DAG1020は、ゲート1010~1013のそれぞれを表すノード1030~1033を含む。情報処理装置100は、DAG1020に対してトポロジカルソートを実施しておいてもよい。
情報処理装置100は、グラフGに、生成したDAG1020を設定する。情報処理装置100は、空の出力回路Cを用意する。情報処理装置100は、現在のグローバルな量子ビットと、現在のローカルな量子ビットとを区別可能にするqubit順序σを記憶する。
qubit順序σは、例えば、n個の量子ビットを並べた量子ビット列の上位から順に、それぞれの量子ビットを識別する識別子を並べて表す情報である。qubit順序σは、具体的には、初期状態で、[0,1,2,3]などである。これにより、情報処理装置100は、量子回路1000の中身を解析し易くすることができる。ここでは、説明の簡略化のため、n=4である場合について説明したが、以下の説明では、n=6である場合について説明する。次に、図11の説明に移行する。
図11において、情報処理装置100は、グラフGが空になるまで、後述する(11-1)~(11-3)の処理を繰り返し実施する。qubit順序σは、具体的には、初期状態で、[0,1,2,3,4,5]である。qubit順序σのうち、左側3個の量子ビットが、ローカルであり、右側3個の量子ビットが、グローバルである。
(11-1)情報処理装置100は、グラフGのそれぞれのノードが表すゲートgが、他のゲートに依存せずに実行可能、かつ、現在のqubit順序σに対してプロセス間通信が発生しないゲートであれば、グラフGの中から当該ゲートgを除去する。情報処理装置100は、例えば、表800を参照して、グラフGのそれぞれのノードが表すゲートgが、現在のqubit順序σに対してプロセス間通信が発生するゲートであるか否かを判定してもよい。
情報処理装置100は、除去したゲートgを、現在のqubit順序σに適合するよう更新した後に、現在の出力回路Cの末尾に、順に追加する。情報処理装置100は、具体的には、除去したゲートgが参照する量子ビットの番号が、現在のqubit順序σに適合するよう、当該ゲートgの中身を書き換えた後に、現在の出力回路Cの末尾に追加する。これにより、情報処理装置100は、現在プロセス間通信が発生しないゲートが、グローバルな量子ビットとローカルな量子ビットとを入れ替えた後に、プロセス間通信が発生するゲートになってしまうことを回避し易くすることができる。
(11-2)情報処理装置100は、次にローカルにする1以上の量子ビットを特定する。情報処理装置100は、例えば、現在のグラフGと、現在のqubit順序σとに基づいて、次にローカルにする1以上の量子ビットを表す集合Qlocal’を決定する。
情報処理装置100は、例えば、|Qlocal’|≦(ローカルな量子ビットの数)である限り、グラフGのうち、他のゲートに依存せずに実行可能なゲートを順に検索することを繰り返す。情報処理装置100は、例えば、|Qlocal’|≦(ローカルな量子ビットの数)である限り、グラフGのうち、検索済みのゲート以外の他のゲートに依存せずに実行可能なゲートを順に検索することを繰り返してもよい。情報処理装置100は、例えば、検索したゲートが参照する量子ビットを、Qlocal’に追加する。|*|は、*の量子ビットの数である。これにより、情報処理装置100は、次にローカルにする1以上の量子ビットを特定することができる。
(11-3)情報処理装置100は、ローカルな量子ビットが、Qlocal’と一致するよう、スワップゲートまたはフューズドスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、次にローカルにする1以上の量子ビットの集合Q_importと、グローバルに移動可能な1以上の量子ビットの集合Q_exportableとを特定する。情報処理装置100は、具体的には、Q_import←Qlocal’-Qlocalを特定する。Qlocalは、現在のローカルな量子ビットである。情報処理装置100は、具体的には、Q_exportable←Qlocal-Qlocal’を特定する。図11の例では、Q_import={3,5}である。Q_exportable={0,2}である。qubit順序σ=[0,1,2,3,4,5]である。
情報処理装置100は、例えば、ローカルな量子ビットのうち、上位|Q_import|個の量子ビットが、Q_exportableに含まれる量子ビットになるよう、ローカルな量子ビット同士を入れ替えるスワップゲートを、出力回路Cに追加する。図11の例では、情報処理装置100は、表1100に示す通り、ローカルな量子ビット0,1同士を入れ替えるスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、グローバルな量子ビットのうち、Q_importの量子ビットが連続するよう、スワップゲートを、出力回路Cに追加する。グローバルな量子ビット同士を入れ替えるスワップゲートは、プロセス間通信なしに実施可能なように実装される傾向がある。図11の例では、情報処理装置100は、表1100に示す通り、グローバルな量子ビット4,5同士を入れ替えるスワップゲートを、出力回路Cに追加する。
情報処理装置100は、ローカルな量子ビットのうち、上位|Q_import|個の量子ビットと、グローバルな量子ビットのうち、Q_importの量子ビットとを入れ替えるよう、スワップゲートまたはフューズドスワップゲートを、出力回路Cに追加する。図11の例では、情報処理装置100は、表1100に示す通り、ローカルな量子ビット0,2と、グローバルな量子ビット3,5とを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。これにより、情報処理装置100は、上位|Q_import|個の量子ビットを入れ替え、不連続メモリアクセスによる性能低下を回避し易くすることができる。
次に、図12の説明に移行し、グローバルな量子ビット同士を入れ替えるスワップゲートが、プロセス間通信なしに実施可能なように実装されていない場合に、ローカルな量子ビットと、グローバルな量子ビットとをどのように入れ替えるのかについて説明する。図12の例では、Q_import={3,5}である。Q_exportable={0,1,2}である。qubit順序σ=[0,1,2,3,4,5]である。
図12において、情報処理装置100は、|Q_import|に対して|Q_exportable|に余分があれば、グローバルな量子ビットのうち、不連続になる量子ビットを、Q_importに追加してもよい。そして、情報処理装置100は、フューズドスワップゲートを活用し、ローカルな量子ビットと、グローバルな量子ビットとを一度で入れ替えるようにしてもよい。
図12の例では、情報処理装置100は、具体的には、量子ビット4を、Q_importに追加する。情報処理装置100は、具体的には、表1210に示す通り、ローカルな量子ビット0~2と、グローバルな量子ビット3~5とを入れ替える1つのフューズドスワップゲートを、出力回路Cに追加する。これにより、情報処理装置100は、フューズドスワップゲートを活用して、Q_exportableの量子ビットと、Q_importの量子ビットとを入れ替えることができる。
情報処理装置100は、|Q_import|に対して|Q_exportable|に余分がなければ、ローカルな量子ビットと、グローバルな量子ビットとを複数回に分けて入れ替えることが考えられる。図12の例では、情報処理装置100は、具体的には、表1200に示す通り、ローカルな量子ビット1と、グローバルな量子ビット3とを入れ替える1つのスワップゲートを、出力回路Cに追加する。情報処理装置100は、具体的には、表1200に示す通り、ローカルな量子ビット2と、グローバルな量子ビット5とを入れ替える1つのスワップゲートを、出力回路Cに追加する。
表1200,1210に示す通り、情報処理装置100は、フューズドスワップゲートを活用して、Q_exportableの量子ビットと、Q_importの量子ビットとを入れ替える際にかかる処理負担の低減化を図ることができる。情報処理装置100は、具体的には、出力回路Cに追加するゲートの数の低減化を図ることができる。情報処理装置100は、具体的には、出力回路Cに従って、量子ビットを入れ替える演算を実施する回数の低減化を図ることができる。次に、図13の説明に移行する。
図13において、情報処理装置100は、グラフGが空になったことを検出する。情報処理装置100は、グラフGが空になると、qubit順序σを初期状態に戻すよう、スワップゲートまたはフューズドスワップゲートを、出力回路Cに追加する。情報処理装置100は、例えば、Qlocal’={0,…,(ローカルな量子ビットの数-1)}に設定する。情報処理装置100は、例えば、図11と同様に、Qlocal’に基づいて、スワップゲートまたはフューズドスワップゲートを、出力回路Cに追加する。
図13の例では、情報処理装置100は、具体的には、表1300に示す通り、ローカルな量子ビット5,4と、グローバルな量子ビット0,2とを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。情報処理装置100は、具体的には、ローカルな量子ビット0,1同士を入れ替えるスワップゲートを、出力回路Cに追加する。情報処理装置100は、具体的には、グローバルな量子ビット4,5同士を入れ替えるスワップゲートを、出力回路Cに追加する。
これにより、情報処理装置100は、入力を受け付けた量子回路と論理的に等価になり、プロセス間通信が発生する回数、または、通信量が抑制された出力回路Cを生成することができる。次に、図14の説明に移行し、グローバルな量子ビット同士を入れ替えるスワップゲートが、プロセス間通信なしに実施可能なように実装されていない場合に、qubit順序σをどのように初期状態に戻すのかについて説明する。
図14において、情報処理装置100は、ローカルな量子ビットの数が、グローバルな量子ビットの数の2倍未満である場合、1つの量子ビットずつ、量子ビット同士を入れ替えることになる。従って、この場合、情報処理装置100は、最大で量子ビットの数-1個のスワップゲートを、出力回路Cに追加することになる。
情報処理装置100は、ローカルな量子ビットの数が、グローバルな量子ビットの数の2倍以上である場合、下記に示す通り、qubit順序σを初期状態に戻す。
例えば、グローバルな量子ビットに、(ローカルな量子ビットの数)~(量子ビットの数-1)番の量子ビットが含まれる場合がある。この場合、情報処理装置100は、例えば、ローカルな量子ビットの上位(グローバルな量子ビットの数)個の量子ビットに、(ローカルな量子ビットの数)~(量子ビットの数-1)番の量子ビットが含まれないよう、スワップゲートを、出力回路Cに追加する。図14の例では、情報処理装置100は、具体的には、表1400に示す通り、ローカルな量子ビット0,5同士を入れ替えるスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、ローカルな量子ビットの上位(グローバルな量子ビットの数)個の量子ビットと、グローバルな量子ビットとを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。図14の例では、情報処理装置100は、具体的には、表1400に示す通り、ローカルな量子ビット0,3と、グローバルな量子ビット2,4とを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、ローカルな量子ビットの上位(グローバルな量子ビットの数)個の量子ビットにおいて、(ローカルな量子ビットの数)~(量子ビットの数-1)番の量子ビットを順序通りに並べ替えるスワップゲートを、出力回路Cに追加する。図14の例では、情報処理装置100は、具体的には、表1400に示す通り、ローカルな量子ビット2,4,5を順序通りに並べ替える2つのスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、ローカルな量子ビットの上位(グローバルな量子ビットの数)個の量子ビットと、グローバルな量子ビットとを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。図14の例では、情報処理装置100は、具体的には、表1400に示す通り、ローカルな量子ビット4,5と、グローバルな量子ビット0,3とを入れ替えるフューズドスワップゲートを、出力回路Cに追加する。
情報処理装置100は、例えば、ローカルな量子ビットを順序通り並べ替えるスワップゲートを、出力回路Cに追加する。図14の例では、情報処理装置100は、具体的には、表1400に示す通り、ローカルな量子ビット0,1,2を順序通りに並べ替える2つのスワップゲートを、出力回路Cに追加する。これにより、情報処理装置100は、qubit順序σを初期状態に戻すよう、複数の量子ビットを適切に入れ替えることができる。
(情報処理装置100の動作の具体例)
次に、図15~図18を用いて、情報処理装置100の動作の具体例について説明する。
次に、図15~図18を用いて、情報処理装置100の動作の具体例について説明する。
図15~図18は、情報処理装置100の動作の具体例を示す説明図である。図15において、情報処理装置100は、量子回路1500の入力を受け付けたとする。量子回路1500は、ゲート1510~1518を含む。情報処理装置100は、量子回路1500に対応するDAG1520を生成する。DAG1520は、ゲート1510~1518のそれぞれを表すノード1530~1538を含む。次に、図16の説明に移行する。
図16において、(16-1)情報処理装置100は、qubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1530~1532を特定する。情報処理装置100は、DAG1520に基づいて、特定したノード1530~1532のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1530~1532を特定する。情報処理装置100は、特定したノード1530~1532を、DAG1520から除去する。情報処理装置100は、特定したノード1530~1532が表すゲート1610~1612を、出力回路1600に追加する。
(16-2)情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連し、プロセス間通信が発生する1以上のゲートを表すノード1533~1538を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1533~1538のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能な1以上のゲートを表す、ノード1533~1536を特定する。情報処理装置100は、特定したノード1533~1536に基づいて、次にローカルに設定する量子ビットの集合Qlocal’={2,3,4}を特定する。
(16-3)情報処理装置100は、Qlocal’={2,3,4}に基づいて、qubit順序σを更新し、スワップゲート1620と、フューズドスワップゲート1630とを、出力回路1600に追加する。次に、図17の説明に移行する。
図17において、(17-1)情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1533~1536を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1533~1536のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1533,1534を特定する。情報処理装置100は、特定したノード1533,1534を、DAG1520から除去する。情報処理装置100は、特定したノード1533,1534が表すゲート1700,1701を、出力回路1600に追加する。
情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1535,1536を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1535,1536のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1535を特定する。情報処理装置100は、特定したノード1535を、DAG1520から除去する。情報処理装置100は、特定したノード1535が表すゲート1702を、出力回路1600に追加する。
情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1536を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1536のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1536を特定する。情報処理装置100は、特定したノード1536を、DAG1520から除去する。情報処理装置100は、特定したノード1536が表すゲート1702を、出力回路1600に追加する。
(17-2)情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連し、プロセス間通信が発生する1以上のゲートを表すノード1537,1538を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1537,1538のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能な1以上のゲートを表す、ノード1537,1538を特定する。情報処理装置100は、特定したノード1537,1538に基づいて、次にローカルに設定する量子ビットの集合Qlocal’={0,1,2}を特定する。
(17-3)情報処理装置100は、Qlocal’={0,1,2}に基づいて、qubit順序σを更新し、フューズドスワップゲート1710を、出力回路1600に追加する。次に、図18の説明に移行する。
図18において、(18-1)情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1537,1538を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1537,1538のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1537を特定する。情報処理装置100は、特定したノード1537を、DAG1520から除去する。情報処理装置100は、特定したノード1537が表すゲート1801を、出力回路1600に追加する。
情報処理装置100は、最新のqubit順序σに基づいて、グローバルな量子ビットに関連せず、プロセス間通信が発生しないゲートを表すノード1538を特定する。情報処理装置100は、最新のDAG1520に基づいて、特定したノード1538のうち、他のノードを始点とする有向エッジが接続されず、他のゲートに依存せずに実行可能なゲートを表す、ノード1538を特定する。情報処理装置100は、特定したノード1538を、DAG1520から除去する。情報処理装置100は、特定したノード1538が表すゲート1802を、出力回路1600に追加する。
(18-2)情報処理装置100は、DAG1520が空になったことを検出する。情報処理装置100は、DAG1520が空になったため、qubit順序σを初期状態に戻すよう、スワップゲート1810を、出力回路1600に追加する。これにより、情報処理装置100は、入力を受け付けた量子回路1500と論理的に等価な、プロセス間通信が発生する回数、または、通信量が抑制された出力回路1600を生成することができる。
(情報処理装置100の第1適用例)
次に、図19を用いて、情報処理装置100の第1適用例について説明する。
次に、図19を用いて、情報処理装置100の第1適用例について説明する。
図19は、情報処理装置100の第1適用例を示す説明図である。図19において、情報処理装置100は、量子回路1900の入力を受け付けたとする。量子回路1900は、ゲート1910~1913を含む。ゲート1910~1913は、汎用ゲートである。量子回路1900において発生するプロセス間通信の通信量は、例えば、7Mである。Mは、2^(ローカルな量子ビットの数)である。
情報処理装置100は、量子回路1900と論理的に等価な量子回路1920を生成したとする。量子回路1920は、ゲート1910~1913のそれぞれに対応するゲート1930~1933を含む。量子回路1920は、スワップゲート1940と、フューズドスワップゲート1950と、スワップゲート1960~1962とを含む。これにより、情報処理装置100は、量子回路1920において、プロセス間通信の通信量を2.75Mに低減することができる。
(情報処理装置100の第2適用例)
次に、図20および図21を用いて、情報処理装置100の第2適用例について説明する。
次に、図20および図21を用いて、情報処理装置100の第2適用例について説明する。
図20および図21は、情報処理装置100の第2適用例を示す説明図である。図20において、情報処理装置100は、Qulacs benchmarkの量子回路に適用されたとする。情報処理装置100は、表2000に示す測定条件下で、上述した通り量子回路に対する最適化を行い、量子回路に規定された一連の演算を実施する際にかかる処理時間を測定したとする。
以下の説明では、情報処理装置100が測定した処理時間を「「w/ our opt.」の処理時間」と表記する場合がある。また、「w/ our opt.」の処理時間との比較例として、「w/o opt.」の処理時間と、「w/ existing opt.」の処理時間とを採用する。
「w/o opt.」の処理時間は、量子回路に対する最適化を行わない場合の処理時間である。「w/ existing opt.」の処理時間は、量子回路に対して従来の最適化を行う場合の処理時間である。次に、図21の説明に移行する。
図21のグラフ2100は、「w/ our opt.」の処理時間と、「w/o opt.」の処理時間と、「w/ existing opt.」の処理時間とを示す。グラフ2100に示す通り、情報処理装置100は、update時間について、「w/o opt.」に比べて1.84倍の高速化を図ることができる。情報処理装置100は、update時間について、「w/ existing opt.」に比べて1.16倍の高速化を図ることができる。
グラフ2100に示す通り、情報処理装置100は、全体時間について、「w/o opt.」に比べて1.72倍の高速化を図ることができる。情報処理装置100は、全体時間について、「w/ existing opt.」に比べて1.35倍の高速化を図ることができる。このように、情報処理装置100は、従来に比べて、量子回路に規定された一連の演算を実施する際にかかる処理時間を低減することができる。
(情報処理装置100の第3適用例)
次に、図22および図23を用いて、情報処理装置100の第3適用例について説明する。
次に、図22および図23を用いて、情報処理装置100の第3適用例について説明する。
図22および図23は、情報処理装置100の第3適用例を示す説明図である。図22において、情報処理装置100は、Quantum Volume Benchmark (depth=30)の量子回路に適用されたとする。
情報処理装置100は、表2200に示す測定条件下で、上述した通り量子回路に対する最適化を行い、量子回路に規定された一連の演算を実施する際にかかる処理時間を測定したとする。以下の説明では、情報処理装置100が測定した処理時間を「「w/ fused-swap」の処理時間」と表記する場合がある。
また、情報処理装置100は、表2200に示す測定条件下で、ゲートフュージョンの最適化を利用して、上述した通り量子回路に対する最適化を行い、量子回路に規定された一連の演算を実施する際にかかる処理時間を測定したとする。以下の説明では、ゲートフュージョンの最適化を利用して、情報処理装置100が測定した処理時間を「「w/ fused-swap and gate fusion」の処理時間」と表記する場合がある。
ゲートフュージョンの最適化は、同一の量子ビットを参照する複数のゲートが存在する場合、複数のゲートの表現行列を掛け合わせた表現行列を有するゲートで、複数のゲートを置き換えることにより、ベクトルの成分を更新する回数の低減化を図る手法である。
また、「w/ fused-swap」の処理時間と、「w/ fused-swap and gate fusion」の処理時間との比較例として、「w/o opt.」の処理時間と、「w/ gate fusion」の処理時間とを採用する。
「w/o opt.」の処理時間は、量子回路に対する最適化を行わない場合の処理時間である。「w/ gate fusion」の処理時間は、量子回路に対するゲートフュージョンを利用する従来の最適化を行う場合の処理時間である。次に、図23の説明に移行する。
図23のグラフ2300は、「w/ fused-swap」の処理時間と、「w/ fused-swap and gate fusion」の処理時間と、「w/o opt.」の処理時間と、「w/ gate fusion」の処理時間とを示す。グラフ2300に示す通り、情報処理装置100は、処理時間を、「w/o opt.」および「w/ existing opt.」に比べて、約1/8に短縮することができる。
図23のグラフ2310は、「w/ our opt.」の通信時間と、「w/ fused-swap and gate fusion」の通信時間と、「w/o opt.」の通信時間と、「w/ existing opt.」の通信時間とを示す。
図23のグラフ2320は、「w/ our opt.」の通信量と、「w/ fused-swap and gate fusion」の通信量と、「w/o opt.」の通信量と、「w/ existing opt.」の通信量とを示す。グラフ2310,2320に示す通り、情報処理装置100は、通信時間および通信量を、「w/o opt.」および「w/ existing opt.」に比べて、低減することができる。
(情報処理装置100の適用例)
情報処理装置100は、例えば、創薬分野に適用することができる。情報処理装置100は、具体的には、創薬分野において、物質の性質を解析するために、複数の量子ビットを利用して、物質を形成する原子の動きなどを模擬する際に適用することができる。
情報処理装置100は、例えば、創薬分野に適用することができる。情報処理装置100は、具体的には、創薬分野において、物質の性質を解析するために、複数の量子ビットを利用して、物質を形成する原子の動きなどを模擬する際に適用することができる。
(全体処理手順)
次に、図24を用いて、情報処理装置100が実行する、全体処理手順の一例について説明する。全体処理は、例えば、図3に示したCPU301と、メモリ302や記録媒体305などの記憶領域と、ネットワークI/F303とによって実現される。
次に、図24を用いて、情報処理装置100が実行する、全体処理手順の一例について説明する。全体処理は、例えば、図3に示したCPU301と、メモリ302や記録媒体305などの記憶領域と、ネットワークI/F303とによって実現される。
図24は、全体処理手順の一例を示すフローチャートである。図24において、情報処理装置100は、量子回路Iを取得する(ステップS2401)。情報処理装置100は、取得した量子回路Iに対応する非巡回有向グラフGを生成し、空の出力回路Cを生成する(ステップS2402)。
情報処理装置100は、非巡回有向グラフGのそれぞれのノードnが表すゲートgのうち、まだ選択していないゲートgを選択する(ステップS2403)。情報処理装置100は、qubit順序σに基づいて、選択したゲートgが、実行可能であってプロセス間通信が発生しないという所定の条件を満たすか否かを判定する(ステップS2404)。
ここで、所定の条件を満たさない場合(ステップS2404:No)、情報処理装置100は、ステップS2406の処理に移行する。一方で、所定の条件を満たす場合(ステップS2404:Yes)、情報処理装置100は、ステップS2405の処理に移行する。
ステップS2405では、情報処理装置100は、選択したゲートgを表すノードnを、非巡回有向グラフGから除去し、qubit順序σに適合するよう、選択したゲートgを設定し、出力回路Cに追加する(ステップS2405)。情報処理装置100は、ステップS2406の処理に移行する。
ステップS2406では、情報処理装置100は、非巡回有向グラフGのそれぞれのノードnが表すゲートgのうち、すべてのゲートgを選択したか否かを判定する(ステップS2406)。ここで、選択していないゲートgが残っている場合(ステップS2406:No)、情報処理装置100は、ステップS2403の処理に戻る。一方で、すべてのゲートgを選択している場合(ステップS2406:Yes)、情報処理装置100は、ステップS2407の処理に移行する。
ステップS2407では、情報処理装置100は、非巡回有向グラフGと、qubit順序σとに基づいて、次のローカルな量子ビットの集合Qlocalを特定する(ステップS2407)。情報処理装置100は、特定した次のローカルな量子ビットの集合Qlocalに基づいて、量子ビットのグローバルとローカルとの区分情報σを更新する(ステップS2408)。情報処理装置100は、更新した量子ビットのグローバルとローカルとの区分情報σに適合するよう、グローバルとローカルとを入れ替える1以上のスワップゲートsを、出力回路Cに追加する(ステップS2409)。
情報処理装置100は、非巡回有向グラフGが空であるか否かを判定する(ステップS2410)。ここで、非巡回有向グラフGが空ではない場合(ステップS2410:No)、情報処理装置100は、ステップS2403の処理に戻る。一方で、非巡回有向グラフGが空である場合(ステップS2410:Yes)、情報処理装置100は、ステップS2411の処理に移行する。
ステップS2411では、情報処理装置100は、量子ビットのグローバルとローカルとの区分情報σを、初期状態に設定する(ステップS2411)。情報処理装置100は、量子ビットのグローバルとローカルとの区分情報σに適合するよう、グローバルとローカルとを入れ替える1以上のスワップゲートsを、出力回路Cに追加する(ステップS2412)。情報処理装置100は、全体処理を終了する。
以上説明したように、情報処理装置100によれば、複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得することができる。情報処理装置100によれば、取得した第1量子回路に基づいて、複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成することができる。情報処理装置100によれば、生成した非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される1以上の量子ビットを特定することができる。情報処理装置100によれば、特定した1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、1以上の第1ゲートの直前に含む第2量子回路を生成することができる。これにより、情報処理装置100は、プロセス間通信が発生する回数、または、通信量が抑制された第2量子回路を生成することができ、複数の量子ビットに関する一連の演算を実施し易くすることができる。
情報処理装置100によれば、1以上の量子ビットを特定する都度、非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを特定することができる。情報処理装置100によれば、1以上の第2ゲートを特定する都度、非巡回有向グラフの中から、特定した1以上の第2ゲートのそれぞれの第2ゲートを表すノードを除去することができる。情報処理装置100によれば、1以上の量子ビットを特定する都度、雛型回路に対して、特定した1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加することができる。情報処理装置100によれば、1以上の第2ゲートを特定する都度、雛型回路に対して、特定した1以上の第2ゲートを追加することができる。これにより、情報処理装置100は、段階的に、第2量子回路を適切に生成していくことができる。
情報処理装置100によれば、1以上の量子ビットを最初に特定する前に、非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを一度特定することができる。これにより、情報処理装置100は、1以上の第2ゲートを先頭に含むよう、第2量子回路を適切に生成することができる。
情報処理装置100によれば、非巡回有向グラフが空である場合、雛型回路の末尾に、初期状態でローカルな1以上の量子ビットがローカルに戻るよう、1以上のスワップゲートを追加することができる。これにより、情報処理装置100は、第2量子回路を適切に生成することができる。
情報処理装置100によれば、1以上の量子ビットを特定した際、特定した1以上の量子ビットに基づいて、入れ替える量子ビットの数が4以上であるか否かを判定することができる。情報処理装置100によれば、4以上であれば、雛型回路に対して、特定した1以上の量子ビットがローカルになるよう、フューズドスワップゲートを含む1以上のスワップゲートを追加することができる。これにより、情報処理装置100は、プロセス間通信が発生する回数、または、通信量の低減化を図ることができる。
情報処理装置100によれば、非巡回有向グラフに基づいて、複数のゲートのうち、他のゲートに依存せずに実行可能な、プロセス間通信が発生するゲートを順に選択することができる。情報処理装置100によれば、ゲートを選択する都度、当該ゲートに関わる量子ビットを、グループに追加するという処理を、グループに含まれる量子ビットの数が、ローカルな量子ビットの上限を超えない範囲で繰り返し実施することができる。情報処理装置100によれば、グループに含まれる1以上の量子ビットを特定することができる。これにより、情報処理装置100は、1以上の量子ビットを適切に特定することができる。
情報処理装置100によれば、非巡回有向グラフに基づいて、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、プロセス間通信が発生するゲートの複数の組み合わせを特定することができる。情報処理装置100によれば、複数の組み合わせのうち、最も多くのゲートを含む組み合わせとなる、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される1以上の量子ビットを特定することができる。これにより、情報処理装置100は、1以上の量子ビットを適切に特定することができる。
なお、本実施の形態で説明した情報処理方法は、予め用意されたプログラムをPCやワークステーションなどのコンピュータで実行することにより実現することができる。本実施の形態で説明した情報処理プログラムは、コンピュータで読み取り可能な記録媒体に記録され、コンピュータによって記録媒体から読み出されることによって実行される。記録媒体は、ハードディスク、フレキシブルディスク、CD(Compact Disc)-ROM、MO(Magneto Optical disc)、DVD(Digital Versatile Disc)などである。また、本実施の形態で説明した情報処理プログラムは、インターネットなどのネットワークを介して配布してもよい。
上述した実施の形態に関し、さらに以下の付記を開示する。
(付記1)ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータに実行させることを特徴とする情報処理プログラム。
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータに実行させることを特徴とする情報処理プログラム。
(付記2)前記1以上の量子ビットを特定する都度、前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを特定し、
前記1以上の第2ゲートを特定する都度、前記非巡回有向グラフの中から、特定した前記1以上の第2ゲートのそれぞれの第2ゲートを表すノードを除去する、
処理を前記コンピュータに実行させ、
前記第2量子回路を生成する処理は、
前記1以上の量子ビットを特定する都度、雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加し、前記1以上の第2ゲートを特定する都度、前記雛型回路に対して、特定した前記1以上の第2ゲートを追加することにより、前記第2量子回路を生成する、ことを特徴とする付記1に記載の情報処理プログラム。
前記1以上の第2ゲートを特定する都度、前記非巡回有向グラフの中から、特定した前記1以上の第2ゲートのそれぞれの第2ゲートを表すノードを除去する、
処理を前記コンピュータに実行させ、
前記第2量子回路を生成する処理は、
前記1以上の量子ビットを特定する都度、雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加し、前記1以上の第2ゲートを特定する都度、前記雛型回路に対して、特定した前記1以上の第2ゲートを追加することにより、前記第2量子回路を生成する、ことを特徴とする付記1に記載の情報処理プログラム。
(付記3)前記1以上の第2ゲートを特定する処理は、
前記1以上の量子ビットを最初に特定する前に、前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを一度特定する、ことを特徴とする付記2に記載の情報処理プログラム。
前記1以上の量子ビットを最初に特定する前に、前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを一度特定する、ことを特徴とする付記2に記載の情報処理プログラム。
(付記4)前記第2量子回路を生成する処理は、
前記非巡回有向グラフが空である場合、前記雛型回路の末尾に、初期状態でローカルな1以上の量子ビットがローカルに戻るよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加することにより、前記第2量子回路を生成し、前記第2量子回路を生成する処理を終了する、ことを特徴とする付記3に記載の情報処理プログラム。
前記非巡回有向グラフが空である場合、前記雛型回路の末尾に、初期状態でローカルな1以上の量子ビットがローカルに戻るよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加することにより、前記第2量子回路を生成し、前記第2量子回路を生成する処理を終了する、ことを特徴とする付記3に記載の情報処理プログラム。
(付記5)前記第2量子回路を生成する処理は、
前記1以上の量子ビットを特定した際、特定した前記1以上の量子ビットに基づいて、入れ替える量子ビットの数が4以上であれば、前記雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える、フューズドスワップゲートを含む1以上のスワップゲートを追加する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
前記1以上の量子ビットを特定した際、特定した前記1以上の量子ビットに基づいて、入れ替える量子ビットの数が4以上であれば、前記雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える、フューズドスワップゲートを含む1以上のスワップゲートを追加する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
(付記6)前記1以上の量子ビットを特定する処理は、
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、プロセス間通信が発生するゲートを順に選択する都度、当該ゲートに関わる量子ビットを、グループに追加するという処理を、前記グループに含まれる量子ビットの数が、ローカルな量子ビットの上限を超えない範囲で繰り返し実施した後、前記グループに含まれる1以上の量子ビットを特定する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、プロセス間通信が発生するゲートを順に選択する都度、当該ゲートに関わる量子ビットを、グループに追加するという処理を、前記グループに含まれる量子ビットの数が、ローカルな量子ビットの上限を超えない範囲で繰り返し実施した後、前記グループに含まれる1以上の量子ビットを特定する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
(付記7)前記1以上の量子ビットを特定する処理は、
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、プロセス間通信が発生するゲートの複数の組み合わせのうち、最も多くのゲートを含む組み合わせとなる、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される1以上の量子ビットを特定する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、プロセス間通信が発生するゲートの複数の組み合わせのうち、最も多くのゲートを含む組み合わせとなる、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される1以上の量子ビットを特定する、ことを特徴とする付記2~4のいずれか一つに記載の情報処理プログラム。
(付記8)ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータが実行することを特徴とする情報処理方法。
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータが実行することを特徴とする情報処理方法。
(付記9)ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
制御部を有することを特徴とする情報処理装置。
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
制御部を有することを特徴とする情報処理装置。
100 情報処理装置
110 第1量子回路
121~123,910~913,1010~1013,1510~1518,1610~1612,1700~1702,1801,1802,1910~1913,1930~1933 ゲート
130,1020,1520 非巡回有向グラフ
141~143,1030~1033,1530~1538 ノード
150 第2量子回路
160,930,950,1620,1810,1940,1960~1962 スワップゲート
200 情報処理システム
201 演算処理装置
202 クライアント装置
210 ネットワーク
300 バス
301 CPU
302 メモリ
303 ネットワークI/F
304 記録媒体I/F
305 記録媒体
400 記憶部
401 取得部
402 第1生成部
403 第1特定部
404 第2特定部
405 第2生成部
406 模擬部
407 出力部
500 ステートベクトル
510,900,920,940,1000,1500,1900,1920 量子回路
600 量子ビット列
710,711,720,721,800,1100,1200,1210,1300,1400,2000,2200 表
1600 出力回路
1630,1710,1950 フューズドスワップゲート
2100,2300,2310,2320 グラフ
110 第1量子回路
121~123,910~913,1010~1013,1510~1518,1610~1612,1700~1702,1801,1802,1910~1913,1930~1933 ゲート
130,1020,1520 非巡回有向グラフ
141~143,1030~1033,1530~1538 ノード
150 第2量子回路
160,930,950,1620,1810,1940,1960~1962 スワップゲート
200 情報処理システム
201 演算処理装置
202 クライアント装置
210 ネットワーク
300 バス
301 CPU
302 メモリ
303 ネットワークI/F
304 記録媒体I/F
305 記録媒体
400 記憶部
401 取得部
402 第1生成部
403 第1特定部
404 第2特定部
405 第2生成部
406 模擬部
407 出力部
500 ステートベクトル
510,900,920,940,1000,1500,1900,1920 量子回路
600 量子ビット列
710,711,720,721,800,1100,1200,1210,1300,1400,2000,2200 表
1600 出力回路
1630,1710,1950 フューズドスワップゲート
2100,2300,2310,2320 グラフ
Claims (9)
- ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータに実行させることを特徴とする情報処理プログラム。 - 前記1以上の量子ビットを特定する都度、前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを特定し、
前記1以上の第2ゲートを特定する都度、前記非巡回有向グラフの中から、特定した前記1以上の第2ゲートのそれぞれの第2ゲートを表すノードを除去する、
処理を前記コンピュータに実行させ、
前記第2量子回路を生成する処理は、
前記1以上の量子ビットを特定する都度、雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加し、前記1以上の第2ゲートを特定する都度、前記雛型回路に対して、特定した前記1以上の第2ゲートを追加することにより、前記第2量子回路を生成する、ことを特徴とする請求項1に記載の情報処理プログラム。 - 前記1以上の第2ゲートを特定する処理は、
前記1以上の量子ビットを最初に特定する前に、前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、それぞれプロセス間通信が発生しない1以上の第2ゲートを一度特定する、ことを特徴とする請求項2に記載の情報処理プログラム。 - 前記第2量子回路を生成する処理は、
前記非巡回有向グラフが空である場合、前記雛型回路の末尾に、初期状態でローカルな1以上の量子ビットがローカルに戻るよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを追加することにより、前記第2量子回路を生成し、前記第2量子回路を生成する処理を終了する、ことを特徴とする請求項3に記載の情報処理プログラム。 - 前記第2量子回路を生成する処理は、
前記1以上の量子ビットを特定した際、特定した前記1以上の量子ビットに基づいて、入れ替える量子ビットの数が4以上であれば、前記雛型回路に対して、特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える、フューズドスワップゲートを含む1以上のスワップゲートを追加する、ことを特徴とする請求項2~4のいずれか一つに記載の情報処理プログラム。 - 前記1以上の量子ビットを特定する処理は、
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、プロセス間通信が発生するゲートを順に選択する都度、当該ゲートに関わる量子ビットを、グループに追加するという処理を、前記グループに含まれる量子ビットの数が、ローカルな量子ビットの上限を超えない範囲で繰り返し実施した後、前記グループに含まれる1以上の量子ビットを特定する、ことを特徴とする請求項2~4のいずれか一つに記載の情報処理プログラム。 - 前記1以上の量子ビットを特定する処理は、
前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、プロセス間通信が発生するゲートの複数の組み合わせのうち、最も多くのゲートを含む組み合わせとなる、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される1以上の量子ビットを特定する、ことを特徴とする請求項2~4のいずれか一つに記載の情報処理プログラム。 - ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
処理をコンピュータが実行することを特徴とする情報処理方法。 - ローカルな1以上の量子ビットと、グローバルな1以上の量子ビットとを含む複数の量子ビットに関して、それぞれ異なる1以上の量子ビットに対して演算を実施することを表す複数のゲートを、時系列に沿って規定した第1量子回路を取得し、
取得した前記第1量子回路に基づいて、前記複数のゲートのそれぞれのゲートを表すノードと、異なるノードが表すゲート間の演算の実施順序を表す有向エッジとを含む非巡回有向グラフを生成し、
生成した前記非巡回有向グラフに基づいて、前記複数のゲートのうち、他のゲートに依存せずに実行可能な、ローカルな量子ビットの上限以下の1以上の量子ビットを参照する、それぞれプロセス間通信が発生する1以上の第1ゲートによって参照される、前記1以上の量子ビットを特定し、
特定した前記1以上の量子ビットがローカルになるよう、ローカルな量子ビットとグローバルな量子ビットとを入れ替える1以上のスワップゲートを、前記1以上の第1ゲートの直前に含む、前記第1量子回路と論理的に等価な第2量子回路を生成する、
制御部を有することを特徴とする情報処理装置。
Applications Claiming Priority (2)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP2023054410A JP2024142277A (ja) | 2023-03-29 | 2023-03-29 | 情報処理プログラム、情報処理方法、および情報処理装置 |
| JP2023-054410 | 2023-03-29 |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| WO2024202575A1 true WO2024202575A1 (ja) | 2024-10-03 |
Family
ID=92904015
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| PCT/JP2024/004241 Ceased WO2024202575A1 (ja) | 2023-03-29 | 2024-02-08 | 情報処理プログラム、情報処理方法、および情報処理装置 |
Country Status (2)
| Country | Link |
|---|---|
| JP (1) | JP2024142277A (ja) |
| WO (1) | WO2024202575A1 (ja) |
-
2023
- 2023-03-29 JP JP2023054410A patent/JP2024142277A/ja active Pending
-
2024
- 2024-02-08 WO PCT/JP2024/004241 patent/WO2024202575A1/ja not_active Ceased
Non-Patent Citations (2)
| Title |
|---|
| BO FANG; M. YUSUF \"OZKAYA; ANG LI; \"UMIT V. \C{C}ATALY\"UREK; SRIRAM KRISHNAMOORTHY: "Efficient Hierarchical State Vector Simulation of Quantum Circuits via Acyclic Graph Partitioning", ARXIV.ORG, CORNELL UNIVERSITY LIBRARY, 201 OLIN LIBRARY CORNELL UNIVERSITY ITHACA, NY 14853, 14 May 2022 (2022-05-14), 201 Olin Library Cornell University Ithaca, NY 14853, XP091225919 * |
| IMAMURA SATOSHI, YAMAZAKI MASAFUMI, HONDA TAKUMI, KASAGI AKIHIKO, TABUCHI AKIHIRO, NAKAO HIROSHI, FUKUMOTO NAOTO, NAKASHIMA KOHTA: "mpiQulacs: A Distributed Quantum Computer Simulator for A64FX-based Cluster Systems", ARXIV:2203.16044V1, 30 March 2022 (2022-03-30), XP093213807, DOI: 10.48550/arXiv.2203.16044 * |
Also Published As
| Publication number | Publication date |
|---|---|
| JP2024142277A (ja) | 2024-10-10 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US11882054B2 (en) | Terminating data server nodes | |
| CN108564164B (zh) | 一种基于spark平台的并行化深度学习方法 | |
| KR102326586B1 (ko) | 큰 규모 분산 행렬 곱 처리 방법 및 그 장치 | |
| WO2021173490A1 (en) | Vectorized queues for shortest-path graph searches | |
| WO2022228224A1 (zh) | 量子计算任务执行方法、装置及量子计算机操作系统 | |
| CN110990356B (zh) | 一种用于逻辑镜像的实时自动扩容方法和系统 | |
| CN111915011B (zh) | 一种单振幅量子计算模拟方法 | |
| CN113360577A (zh) | 一种mpp数据库数据处理方法、装置、设备及存储介质 | |
| JP2001166977A (ja) | データ構造管理装置、データ構造管理システム、データ構造管理方法およびデータ構造管理プログラムを格納する記録媒体 | |
| CN114175640B (zh) | 向量化的散列表 | |
| JP2018147301A (ja) | 計算機システム及び処理の割当方法 | |
| CN112000334B (zh) | 页面开发方法、装置、服务器及存储介质 | |
| CN116167447A (zh) | 量子电路处理方法、装置及电子设备 | |
| CN118839035A (zh) | 张量持久化管理方法、装置、电子设备和存储介质 | |
| JP2023553220A (ja) | マルチインスタンスプロセスのためのプロセスマイニング | |
| WO2024202575A1 (ja) | 情報処理プログラム、情報処理方法、および情報処理装置 | |
| KR102392880B1 (ko) | 계층화 문서를 관리하는 방법 및 이를 이용한 장치 | |
| EP3336717A1 (en) | System, device and method for data update notification | |
| US20240338213A1 (en) | Quantum computing platform adaptation method and apparatus, and quantum computer operating system | |
| CN108376104B (zh) | 节点调度方法及装置、计算机可读存储介质 | |
| CN114675954B (zh) | 任务调度方法及装置 | |
| WO2019225420A1 (ja) | 変換装置、および、変換プログラム | |
| CN114548922A (zh) | 一种更新流程定义的方法及装置 | |
| CN112667637A (zh) | 数据管理方法、装置及计算机可读存储介质 | |
| CN113741787A (zh) | 一种数据存储方法、装置、设备、介质 |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| 121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 24778720 Country of ref document: EP Kind code of ref document: A1 |
|
| NENP | Non-entry into the national phase |
Ref country code: DE |
|
| 122 | Ep: pct application non-entry in european phase |
Ref document number: 24778720 Country of ref document: EP Kind code of ref document: A1 |