# US 2022/0036231 A1 · Method and device for processing quantum data

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2022/0036231 A1
- Document ID: US20220036231A1
- Status: Published application
- Kind: A1
- Application number: 17/501,764
- Filed: 2021-10-14
- Published: 2022-02-03
- Earliest claimed: 2020-11-18
- Assignees: Beijing Baidu Netcom Science Technology Co., Ltd.
- Applicants: Beijing Baidu Netcom Science Technology Co., Ltd.
- Inventors: Xin WANG; Zhixin SONG; Guangxi LI
- Web page: https://patentgrep.com/patent/US20220036231A1

## CPC

- G06N 10/00: Quantum computing, i.e. information processing based on quantum-mechanical phenomena
- G06N 10/60: Quantum algorithms, e.g. based on quantum optimisation, quantum Fourier or Hadamard transforms
- G06F 18/2148: {characterised by the process organisation or structure, e.g. boosting cascade}
- G06N 3/02: Neural networks
- G06N 3/0499: Feedforward networks
- G06N 3/08: Learning methods
- G06N 3/09: Supervised learning
- G06N 10/20: Models of quantum computing, e.g. quantum circuits or universal quantum computers
- G06N: COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A method and device for processing quantum data are provided, which are related to the field of quantum computation. The method includes: determining a quantum data set and category information characterizing a data type of the quantum data set; applying a local quantum circuit to a quantum data point contained in the quantum data set, wherein the local quantum circuit is obtained after part of qubits are selected from a plurality of qubits contained in a parameterized quantum circuit; acquiring state information of qubits in the local quantum circuit after being applied to the quantum data point through measurement, and taking the state information and the category information as training data for training a classical neural network to obtain a trained classical neural network, wherein a data type of a quantum data set to be processed can be identified by the trained classical neural network.

## Claims

### Claim 1

A method for processing quantum data, comprising:
determining a quantum data set and category information characterizing a data type of the quantum data set;
applying a local quantum circuit to a quantum data point contained in the quantum data set, wherein the local quantum circuit is obtained after part of qubits are selected from a plurality of qubits contained in a parameterized quantum circuit; and
acquiring state information of qubits in the local quantum circuit after being applied to the quantum data point through measurement, and taking the state information and the category information as training data for training a classical neural network to obtain a trained classical neural network, wherein a data type of a quantum data set to be processed can be identified by the trained classical neural network.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
determining the parameterized quantum circuit, selecting part of qubits from the plurality of qubits contained in the parameterized quantum circuit, and taking a quantum circuit containing the selected part of qubits as the local quantum circuit, wherein a plurality of pieces of state information can be obtained by adjusting the selected part of qubits.

### Claim 3 (depends on 1)

The method of claim 1, further comprising:
acquiring a total degree of difference between pieces of predicted information corresponding to all quantum data points in the quantum data set and the category information, wherein the pieces of predicted information are output by the classical neural network and are used for characterizing data categories of the quantum data points; the total degree of difference is determined based on a degree of difference between predicted information corresponding to each quantum data point in the quantum data set and the category information; and
adjusting a parameter of the local quantum circuit based on the total degree of difference, to adjust the state information serving as the training data.

### Claim 4 (depends on 2)

The method of claim 2, further comprising:
acquiring a total degree of difference between pieces of predicted information corresponding to all quantum data points in the quantum data set and the category information, wherein the pieces of predicted information are output by the classical neural network and are used for characterizing data categories of the quantum data points; the total degree of difference is determined based on a degree of difference between predicted information corresponding to each quantum data point in the quantum data set and the category information; and
adjusting a parameter of the local quantum circuit based on the total degree of difference, to adjust the state information serving as the training data.

### Claim 5

A method for processing quantum data, comprising:
determining a quantum data set and category information characterizing a data type of the quantum data set;
applying a local quantum circuit to a quantum data point contained in the quantum data set, wherein the local quantum circuit is obtained after part of qubits are selected from a plurality of qubits contained in a parameterized quantum circuit;
acquiring state information of qubits in the local quantum circuit after being applied to the quantum data point through measurement, and taking the state information and the category information as training data for training a classical neural network; and
inputting the training data into the classical neural network to train the classical neural network and obtain a trained classical neural network, wherein a data type of a quantum data set to be processed can be identified by the trained classical neural network.

### Claim 6 (depends on 5)

The method of claim 5, further comprising:
determining the parameterized quantum circuit, selecting part of qubits from the plurality of qubits contained in the parameterized quantum circuit, and taking a quantum circuit containing the selected part of qubits as the local quantum circuit, wherein a plurality of pieces of state information can be obtained by adjusting the selected part of qubits.

### Claim 7 (depends on 5)

The method of claim 5, further comprising:
outputting predicted information characterizing a data category of the quantum data point, to obtain pieces of predicted information corresponding to all quantum data points in the quantum data set, after the training data is input into the classical neural network;
obtaining a total degree of difference based on a degree of difference between predicted information corresponding to each quantum data point and the category information; and
determining a loss function based on the total degree of difference, adjusting a parameter of the classical neural network and a parameter of the local quantum circuit based on the loss function to complete training of the classical neural network.

### Claim 8 (depends on 6)

The method of claim 6, further comprising:
outputting predicted information characterizing a data category of the quantum data point, to obtain pieces of predicted information corresponding to all quantum data points in the quantum data set, after the training data is input into the classical neural network;
obtaining a total degree of difference based on a degree of difference between predicted information corresponding to each quantum data point and the category information; and
determining a loss function based on the total degree of difference, adjusting a parameter of the classical neural network and a parameter of the local quantum circuit based on the loss function to complete training of the classical neural network.

### Claim 9 (depends on 7)

The method of claim 7, further comprising:
calculating a cross entropy between the predicted information corresponding to the quantum data point and the category information, and taking the calculated cross entropy as the degree of difference between the predicted information corresponding to the quantum data point and the category information.

### Claim 10 (depends on 5)

The method of claim 5, further comprising:
acquiring a quantum data set to be processed;
applying the local quantum circuit of which a parameter is adjusted to the quantum data set to be processed;
acquiring state information of qubits in the local quantum circuit after being applied to a quantum data point in the quantum data set to be processed through measurement; and
inputting the state information of the qubits in the local quantum circuit into the trained classical neural network, to obtain predicted information characterizing a data type of the quantum data set to be processed.

### Claim 11

A quantum device, comprising:
an information determination unit configured for determining a quantum data set and category information characterizing a data type of the quantum data set;
a circuit processing unit configured for applying a local quantum circuit to a quantum data point contained in the quantum data set, wherein the local quantum circuit is obtained after part of qubits are selected from a plurality of qubits contained in a parameterized quantum circuit; and
a measurement unit configured for acquiring state information of qubits in the local quantum circuit after being applied to the quantum data point through measurement, and taking the state information and the category information as training data for training a classical neural network to obtain a trained classical neural network, wherein a data type of a quantum data set to be processed can be identified by the trained classical neural network.

### Claim 12 (depends on 11)

The quantum device of claim 11, further comprising:
a selecting unit configured for determining the parameterized quantum circuit, selecting part of qubits from the plurality of qubits contained in the parameterized quantum circuit, and taking a quantum circuit containing the selected part of qubits as the local quantum circuit, wherein a plurality of pieces of state information can be obtained by adjusting the selected part of qubits.

### Claim 13 (depends on 11)

The quantum device of claim 11, further comprising:
a degree of difference acquiring unit configured for acquiring a total degree of difference between pieces of predicted information corresponding to all quantum data points in the quantum data set and the category information, wherein the pieces of predicted information are output by the classical neural network and are used for characterizing data categories of the quantum data points; the total degree of difference is determined based on a degree of difference between predicted information corresponding to each quantum data point in the quantum data set and the category information; and
a parameter adjusting unit configured for adjusting a parameter of the local quantum circuit based on the total degree of difference, to adjust the state information serving as the training data.

### Claim 14 (depends on 12)

The quantum device of claim 12, further comprising:
a degree of difference acquiring unit configured for acquiring a total degree of difference between pieces of predicted information corresponding to all quantum data points in the quantum data set and the category information, wherein the pieces of predicted information are output by the classical neural network and are used for characterizing data categories of the quantum data points; the total degree of difference is determined based on a degree of difference between predicted information corresponding to each quantum data point in the quantum data set and the category information; and
a parameter adjusting unit configured for adjusting a parameter of the local quantum circuit based on the total degree of difference, to adjust the state information serving as the training data.

### Claim 15

A quantum device for processing quantum data, comprising:
a quantum data processing unit configured for determining a quantum data set and category information characterizing a data type of the quantum data set; applying a local quantum circuit to a quantum data point contained in the quantum data set, wherein the local quantum circuit is obtained after part of qubits are selected from a plurality of qubits contained in a parameterized quantum circuit;
a quantum circuit measuring unit configured for acquiring state information of qubits in the local quantum circuit after being applied to the quantum data point through measurement, and taking the state information and the category information as training data for training a classical neural network; and
a classical data processing unit configured for inputting the training data into the classical neural network to train the classical neural network and obtain a trained classical neural network, wherein a data type of a quantum data set to be processed can be identified by the trained classical neural network.

### Claim 16 (depends on 15)

The quantum device of claim 15, wherein
the quantum data processing unit is further configured for determining the parameterized quantum circuit, selecting part of qubits from the plurality of qubits contained in the parameterized quantum circuit, and taking a quantum circuit containing the selected part of qubits as the local quantum circuit, wherein a plurality of pieces of state information can be obtained by adjusting the selected part of qubits.

### Claim 17 (depends on 15)

The quantum device of claim 15, wherein
the classical data processing unit is further configured for outputting predicted information characterizing a data category of the quantum data point, to obtain pieces of predicted information corresponding to all quantum data points in the quantum data set, after the training data is input into the classical neural network; obtaining a total degree of difference based on a degree of difference between predicted information corresponding to each quantum data point and the category information; determining a loss function based on the total degree of difference; and adjusting a parameter of the classical neural network based on the loss function to complete training of the classical neural network; and
the quantum data processing unit is further configured for adjusting a parameter of the local quantum circuit based on the loss function to complete training of the classical neural network.

### Claim 18 (depends on 16)

The quantum device of claim 16, wherein
the classical data processing unit is further configured for outputting predicted information characterizing a data category of the quantum data point, to obtain pieces of predicted information corresponding to all quantum data points in the quantum data set, after the training data is input into the classical neural network; obtaining a total degree of difference based on a degree of difference between predicted information corresponding to each quantum data point and the category information; determining a loss function based on the total degree of difference; and adjusting a parameter of the classical neural network based on the loss function to complete training of the classical neural network; and
the quantum data processing unit is further configured for adjusting a parameter of the local quantum circuit based on the loss function to complete training of the classical neural network.

### Claim 19 (depends on 17)

The quantum device of claim 17, wherein the classical data processing unit is further configured for calculating a cross entropy between the predicted information corresponding to the quantum data point and the category information, and taking the calculated cross entropy as the degree of difference between the predicted information corresponding to the quantum data point and the category information.

### Claim 20 (depends on 17)

The quantum device of claim 17, wherein
the quantum data processing unit is further configured for acquiring a quantum data set to be processed; and applying the local quantum circuit of which a parameter is adjusted to the quantum data set to be processed;
the quantum circuit measuring unit is further configured for acquiring state information of qubits in the local quantum circuit after being applied to a quantum data point in the quantum data set to be processed through measurement; and
the classical data processing unit is further configured for inputting the state information of the qubits in the local quantum circuit into the trained classical neural network, to obtain predicted information characterizing a data type of the quantum data set to be processed.
