Quantum computing system, kernel function determination system, storage medium and program product
By stimulating qubits in the quantum computing system to superposition states of equal probability distribution and applying phase operators, the problem of preparing the initial state of the matrix eigenvalue is solved and the efficiency of determining the target matrix eigenvalue is improved.
Patent Information
- Application Number
- CN202410442483.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-12
- Publication Date
- 2024-08-23
AI Technical Summary
In the prior art, it is difficult to prepare the initial state for determining the eigenvalues of the matrix, which leads to difficulties in determining the eigenvalues of the target matrix in quantum computing methods.
By exciting the first qubit and the second qubit to a superposition state of equal probability distribution, and controlling the quantum state of the first qubit, the phase operator of the target matrix is applied to the second qubit, so that the characteristic value of The phase factor is transferred to the probability amplitude of the first qubit and an inverse quantum Fourier transform is performed to measure the target characteristic value.
It reduces the difficulty of preparing the initial state when determining the eigenvalues of the target matrix, and improves the efficiency of the quantum computing method in determining the eigenvalues of the target matrix.
Smart Images

Figure CN118536611A
Abstract
Description
Technical Field
[0001] The embodiments in this specification relate to the field of quantum computing, and specifically to a quantum computing system, a kernel function determination system, a storage medium, and a program product. Background Art
[0002] In many fields such as quantum computing or artificial intelligence, it is often necessary to determine the eigenvalues of a matrix when processing some data tasks. Specifically, for example, for a kernel matrix that represents the similarity between sample data, the eigenvalues of the kernel matrix can describe the degree of discreteness of the sample data after being mapped to a high-dimensional feature space. A larger degree of discreteness can indicate that the sample data is easier to classify when mapped to a high-dimensional feature space. This plays a key role in data classification tasks.
[0003] In the prior art, when some quantum computing methods are used to determine a certain eigenvalue of a matrix, for example, when a quantum phase estimation method is used to determine the main eigenvalue of a matrix, it is necessary to use the matrix as a Hamiltonian matrix, and excite the initial state of the quantum bit to the eigenstate corresponding to the main eigenvalue, and further determine the main eigenvalue of the matrix through a quantum circuit.
[0004] However, it is difficult to directly determine the eigenstate of a certain eigenvalue of a matrix in the prior art, and it is also difficult to determine the eigenvalue. Therefore, there is a technical problem in the prior art that when using some quantum computing methods to determine the target eigenvalue of the target matrix, the initial state is difficult to prepare. Summary of the invention
[0005] Multiple embodiments in this specification provide a quantum computing system, a kernel function determination system, a storage medium, and a program product, which to a certain extent reduce the difficulty of preparing the initial state when determining the target eigenvalue of the target matrix using a quantum computing method.
[0006] One embodiment of the present specification provides a quantum computing system, which is used to determine a target eigenvalue that meets a specified value condition among multiple eigenvalues of a target matrix; the target matrix is a real symmetric matrix whose matrix elements are all positive values; the quantum computing system includes: multiple quantum bits; the multiple quantum bits are divided into a first quantum bit and a second quantum bit; a quantum measurement and control unit, configured to perform the following steps: excite the first quantum bit and the second quantum bit to a superposition state of equal probability distribution; controlled by the quantum state of the first quantum bit, apply a phase operator constructed by the target matrix to the second quantum bit, so that the phase factor carrying the eigenvalue of the target matrix is transferred to the probability amplitude of the quantum state of the first quantum bit; perform an inverse quantum Fourier transform on the first quantum bit; and measure the first quantum bit to obtain a measurement result that can indicate the target eigenvalue.
[0007] One embodiment of the present specification provides a system for determining a kernel function, comprising: a basic computing unit, configured to perform the following steps: obtaining a matrix set including multiple candidate matrices; wherein the multiple candidate matrices are kernel matrices constructed by different kernel functions, and are used to describe the similarity between different sample data; using the multiple candidate matrices as target matrices, and using a quantum computing system as described in any of the above embodiments to obtain target eigenvalues corresponding to the multiple candidate matrices respectively; and determining the target kernel function in the kernel functions corresponding to the multiple candidate matrices respectively according to the target eigenvalues.
[0008] One embodiment of the present specification provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the steps performed by a quantum measurement and control unit or a basic computing unit in the quantum computing system described in any of the above embodiments are implemented; or, when the computer program is executed by a processor, the steps performed by a basic computing unit in the kernel function determination system described in any of the above embodiments are implemented.
[0009] One embodiment of the present specification provides a computer program product, which is used to execute the steps performed by a quantum measurement and control unit or a basic computing unit in a quantum computing system described in any of the above embodiments; or, when the computer program is executed by a processor, it implements the steps performed by a basic computing unit in a system for determining the kernel function described in any of the above embodiments.
[0010] The multiple implementation methods provided in this specification are to excite the first quantum bit and the second quantum bit to a superposition state of equal probability distribution, and controlled by the quantum state of the first quantum bit, apply a phase operator constructed by a target matrix to the second quantum bit so that the phase factor carrying the eigenvalue of the target matrix is transferred to the probability amplitude of the quantum state of the first quantum bit, and measure the first quantum bit after the inverse quantum Fourier transform, so as to obtain a measurement result indicating the target eigenvalue. Since it is only necessary to excite the first quantum bit and the second quantum bit to a superposition state of equal probability distribution, it is possible to reduce the difficulty of preparing the initial state when determining the target eigenvalue of the target matrix by quantum computing methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] Figure 1 A schematic diagram of a quantum computing system provided for one embodiment of the present specification.
[0012] Figure 2 A flowchart of steps performed by a quantum measurement and control unit in a quantum computing system provided for one embodiment of the present specification.
[0013] Figure 3A schematic diagram of a quantum circuit corresponding to the steps performed by a quantum measurement and control unit of a quantum computing system provided in one embodiment of the present specification.
[0014] Figure 4 A schematic diagram of a flow chart of a reference calculation unit in a kernel function determination system provided in one embodiment of the present specification. DETAILED DESCRIPTION
[0015] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of this application.
[0016] In the description of the embodiments of the present application, it should be understood that the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, the features defined as "first" and "second" may explicitly or implicitly include one or more of the features. In the description of the embodiments of the present application, the meaning of "multiple" is two or more, unless otherwise clearly and specifically defined.
[0017] In the related art, for a known operator and an eigenstate corresponding to the operator, a quantum phase estimation method can estimate the phase of the eigenvalue corresponding to the eigenstate.
[0018] The quantum phase estimation method in the related art requires the use of two groups of quantum bits. The first group of quantum bits can be used to carry the phase information of the eigenvalue. The second group of quantum bits will evolve according to the quantum operation applied to them so that the phase information of the eigenvalue is transferred to the probability amplitude of the first group of quantum bits. By performing an inverse quantum Fourier transform on the first group of quantum bits, the phase of the eigenvalue can be measured.
[0019] By designing a reasonable quantum operation operator and using the quantum phase estimation method, it is possible to estimate a certain eigenvalue of the target matrix. Specifically, by constructing an operator through the target matrix, the eigenvalue of the target matrix can be mapped to the phase of the eigenvalue corresponding to the operator, thereby determining the eigenvalue of the target matrix through the quantum phase estimation method.
[0020] However, in the quantum phase estimation method, the second group of quantum bits needs to be prepared to a special initial state. Specifically, the initial state of the second group of quantum bits is the eigenstate corresponding to the estimated eigenvalue. Therefore, in the data processing task of determining a certain eigenvalue of the target matrix, it is difficult to determine the eigenstate corresponding to the eigenvalue.
[0021] Specifically, for example, the target matrix may be a kernel matrix constructed from sample data. The sample data may be samples used to train a machine learning model. The kernel matrix can be used to describe the similarity between these samples. The data processing task may be to determine the main eigenvalue of the target matrix, that is, the maximum eigenvalue, in order to evaluate the correlation between different sample data. Due to the large number of sample data, the order of the kernel matrix constructed from the sample data is high, so that the classical computing method needs to spend a lot of money to realize the decomposition of the kernel matrix. The use of quantum phase estimation methods requires first determining the eigenstate corresponding to the main eigenvalue, which is also difficult to determine in advance.
[0022] Therefore, it is necessary to provide a quantum computing system, a kernel function determination system, a storage medium, and a program product. For multiple quantum bits divided into a first quantum bit and a second quantum bit, by preparing the two to a superposition state with equal probability, the difficulty of preparing the initial state can be reduced. On this basis, controlled by the quantum state of the first quantum bit, the phase operator constructed by the target matrix acts on the second quantum bit, so that the phase factor carrying the eigenvalue of the target matrix is transferred to the probability amplitude of the quantum state of the first quantum bit, and then the first quantum bit is subjected to an inverse quantum Fourier transform. At least one measurement is performed on the first quantum bit after the inverse quantum Fourier transform, and a measurement result that can indicate the target eigenvalue can be obtained. Therefore, it is possible to solve the technical problem that it is difficult to prepare the initial state when determining the target eigenvalue of the target matrix by a quantum computing method.
[0023] See also Figure 1 One embodiment of the present specification provides a quantum computing system. The quantum computing system may include a basic computing unit and / or a quantum computing unit.
[0024] The basic computing unit may be an electronic device with certain computing and display capabilities. Specifically, for example, the basic computing unit may include a desktop computer, a tablet computer, a laptop computer, a smart phone, a smart TV, and a smart wearable device equipped with a display screen. The basic computing unit may have a network communication module, a processor, and a memory.
[0025] In some embodiments, the basic computing unit can be used as a client. Alternatively, the basic computing unit can be deployed with a client software program. The basic computing unit can send specified data or data computing tasks to the quantum computing unit for computing, receive quantum computing results fed back by the quantum computing unit, and process and display the quantum computing results fed back by the quantum computing unit.
[0026] Based on the existing computer architecture, the basic computing unit may also include a server or a workstation. The server may be a distributed server, which may be a system with multiple processors, memories, network communication modules, etc. operating in coordination. Alternatively, the server may also be a server cluster formed by several servers. The basic computing unit may process the quantum computing results fed back by the quantum computing unit through a server or a workstation, and then send the processing results to the client for display.
[0027] A quantum computing unit can be a device that uses the characteristics of quantum mechanics to realize quantum computing. Specifically, the quantum computing unit can use the quantum state of the quantum bit as a data carrier, and drive the evolution of the quantum bit based on the linear superposition principle of the quantum state to realize a specified operation process. For example, the quantum computing unit can be a superconducting quantum bit control circuit based on ultra-low temperature technology. Alternatively, the quantum computing unit can be a quantum bit control circuit built using quantum well technology. Of course, the quantum computing unit can also be an optical quantum integrated chip, etc.
[0028] The basic computing unit and the quantum computing unit can communicate with each other. For example, the basic computing unit and the quantum computing unit can communicate with each other through a wired connection. Alternatively, the basic computing unit and the quantum computing unit can communicate wirelessly through a network communication module.
[0029] See also Figure 2 In one embodiment of the present specification, a quantum computing system is provided. The quantum computing system can be used to determine a target eigenvalue that meets a specified value condition among multiple eigenvalues of a target matrix; the target matrix is a real symmetric matrix whose matrix elements are all positive; the quantum computing system includes: multiple quantum bits; the multiple quantum bits are divided into a first quantum bit and a second quantum bit; a quantum measurement and control unit, configured to perform the following steps.
[0030] Step S110: Excite the first quantum bit and the second quantum bit to a superposition state with equal probability distribution.
[0031] In this embodiment, the target matrix may be a real symmetric matrix whose matrix elements are all positive values. Specifically, for example, the target matrix may be a covariance matrix, a kernel matrix, or a correlation coefficient matrix.
[0032] In this embodiment, the target eigenvalue may be an eigenvalue that meets the specified value condition among the multiple eigenvalues corresponding to the target matrix. Specifically, for example, the specified value condition may be the maximum value. Accordingly, the target eigenvalue may be the maximum eigenvalue of the target matrix. Of course, the target eigenvalue may also be the second largest eigenvalue.
[0033] In this embodiment, the first qubit may be a qubit used to carry the eigenvalues of the target matrix. Specifically, for example, the first qubit may carry all the eigenvalues of the target matrix.
[0034] In some embodiments, there may be a plurality of first qubits, and the number of first qubits may be associated with the accuracy of the measured target characteristic value.
[0035] In this embodiment, the second qubit can transfer the eigenvalue of the target matrix to the probability amplitude of the first qubit under the action of the phase operator constructed by the target matrix, so that the target eigenvalue can be obtained by measuring the first qubit.
[0036] In some embodiments, the number of second qubits may be associated with the order of the target matrix. The order of the target matrix may be a. Accordingly, the number of second qubits may be the square root of a. For example, the order of the target matrix may be 16. Accordingly, the number of second qubits may be 4.
[0037] For different tasks, the number of first quantum bits and / or second quantum bits can be determined according to actual conditions, and the implementation methods of this specification are not specifically limited here.
[0038] In this embodiment, exciting the first quantum bit and the second quantum bit to a superposition state of equal probability distribution can be achieved by a Hadamard gate. In some embodiments, there can be multiple second quantum bits. Accordingly, the step of exciting the second quantum bit to a superposition state of equal probability distribution can include: applying the Hadamard gate to the multiple second quantum bits respectively, so that the second quantum bits are in a superposition state of equal probability distribution.
[0039] In this embodiment, the superposition state of equal probability distribution can be approximated to the eigenstate of the phase operator. Since the probability amplitudes of different quantum states in the superposition state of equal probability distribution are the same, multiple eigenvalues corresponding to the phase operator constructed by the target matrix can have the same or similar chances to be transferred to the probability amplitude of the first quantum bit, and thus have a certain probability of being measured.
[0040] Step S120: controlled by the quantum state of the first quantum bit, the phase operator constructed by the target matrix is applied to the second quantum bit so that the phase factor carrying the eigenvalue of the target matrix is transferred to the probability amplitude of the quantum state of the first quantum bit.
[0041] In this embodiment, the phase operator can adjust the phase of the second quantum bit according to the direction indicated by the target matrix.
[0042] In some embodiments, referring to Formula 1, the quantum phase operator is an exponential function with the Euler number as the base and the target matrix and a specified imaginary number as the exponential term.
[0043] U=e iθM (1)
[0044] Where M is the target matrix, which is a Hermitian operator. θ is the phase parameter, which determines the effect of the phase operator. i is an imaginary number. e is the Euler number.
[0045] In this embodiment, the phase factor may represent a coefficient formed by the eigenvalue. After the phase operator acts on the second qubit, the phase factor may be obtained in the probability amplitude of the second qubit. Due to the quantum entanglement between the first qubit and the second qubit, the phase factor may be transferred to the probability amplitude of the first qubit.
[0046] In some implementations, the phase factor is an exponent of an exponential term whose base is the Euler number and whose exponent term is composed of the eigenvalue of the target matrix and the specified imaginary number. Specifically, for example, the phase factor can be Among them, λ j It can represent the j-th eigenvalue of the target matrix.
[0047] See also Figure 3 In this embodiment, quantum entanglement between the first quantum bit and the second quantum bit can be achieved through a controlled gate. Specifically, for example, when the first quantum bit is in the |1> state, the quantum measurement and control unit can act on the second quantum bit with a phase operator. Figure 3 Here m can represent the number of second quantum bits.
[0048] In some embodiments, there are multiple first quantum bits; the step of applying the phase operator constructed by the target matrix to the second quantum bit under the control of the quantum state of the first quantum bit includes: applying the phase operator to the second quantum bit a corresponding number of times under the control of the quantum states of the multiple first quantum bits respectively; wherein the number of times the phase operator is applied to the second quantum bit controlled by different first quantum bits is different.
[0049] In some embodiments, the number of the first qubits is N; wherein the i-th first qubit can be used to control the effect on the second qubit 2 (i-1) The phase operator is described below; wherein i is a positive integer less than or equal to N.
[0050] For example, see Figure 3, when the first quantum bit is in the |1> state, the quantum measurement and control unit applies one quantum operation represented by the phase operator to the second quantum bit. When the third quantum bit is in the |1> state, the quantum measurement and control unit applies four quantum operations represented by the phase operator to the second quantum bit.
[0051] Step S130: performing an inverse quantum Fourier transform on the first quantum bit.
[0052] In this embodiment, the inverse quantum Fourier transform can restore the phase information to the computational basis information. After the inverse quantum Fourier transform, the eigenvalue in the probability amplitude of the first quantum bit can be mapped to the quantum state.
[0053] Step S140: Measure the first quantum bit to obtain a measurement result that can indicate the target characteristic value.
[0054] In this embodiment, after measuring the first qubit, the binary value obtained by collapsing the first qubit can be used to represent the eigenvalue. After multiple measurements, multiple eigenvalues can be obtained. Further, the target eigenvalue can be determined from the multiple eigenvalues.
[0055] In some cases, measuring the first qubit once can obtain an eigenvalue of a target matrix. However, the probability of different eigenvalues of the target matrix being measured is not the same. Among them, the main eigenvalue, that is, the maximum eigenvalue, is most likely to be measured.
[0056] Specifically, when the target matrix is a real symmetric matrix and the matrix elements are all positive, according to the Perron-Frobenius theory, it can be determined that the maximum principal component of the target matrix is in the first quadrant. Therefore, the maximum eigenvalue of the target matrix is the spectral radius of the target matrix. And, according to the Perron-Frobenius theory, each element in the eigenvector corresponding to the principal eigenvalue of the target matrix is a positive value. Please refer to Formula 2, Formula 3 and Formula 4, the second quantum bit is excited to a superposition state of equal probability, and this is used as the initial state for characteristic estimation, and the probability of obtaining the principal eigenvalue for each measurement can be estimated.
[0057]
[0058] Where N represents the number of quantum states that the second quantum bit can represent, and ψ represents the initial state of the second quantum bit.
[0059]
[0060] Among them, x i represents the i-th quantum state of the second quantum bit. Can represent the average length of the amplitude.
[0061] Furthermore, by integrating Formula 3, we can obtain Formula 4.
[0062]
[0063] It can be found from formula 4 that the average length of the amplitude converges. Therefore, the main eigenvalue of the main eigenvector can be found with an average probability of 2 / π.
[0064] Theoretical derivation based on Formula 2 to Formula 4 proves that each measurement can have a high probability of obtaining a measurement result that can indicate the target eigenvalue. Specifically, since the probability of the maximum eigenvalue being measured can be approximately 2 / π, the maximum eigenvalue of the target matrix can be determined by measuring a certain number of times and comparing the sizes of the measured values.
[0065] In some embodiments, since the maximum eigenvalue of the target matrix can better reflect the characteristics of the target matrix, it has a richer application. For example, when the target matrix is a kernel matrix, the maximum eigenvalue can be used to analyze the degree of discreteness of the sample data forming the matrix in a high-dimensional space. If the degree of discreteness of the sample data is large, that is, the similarity is small, it may mean that there are abnormal data in the sample data. Therefore, the quantum computing system provided in the embodiments of this specification can also be used to analyze abnormal data in the sample data more quickly.
[0066] In some embodiments, the target matrix is a kernel matrix used to describe the similarity between different sample data; the target eigenvalue is the eigenvalue of the target matrix with the largest value; the quantum computing system also includes a basic computing unit; the basic computing unit is configured to perform the following steps: obtain the measurement result; wherein the measurement result includes multiple measurement values obtained by the quantum measurement and control unit on the first quantum bit multiple times; determine the measurement value with the largest value among the multiple measurement values as the target eigenvalue; when the target eigenvalue is greater than a specified threshold, determine that abnormal data exists in the sample data.
[0067] In this embodiment, the maximum eigenvalue may also represent the spectral radius of the kernel matrix. The stability of the data may be evaluated by analyzing the spectral radius of the kernel matrix. A larger spectral radius may indicate that the similarity between the data is smaller, so abnormal data may be detected in some cases.
[0068] In this embodiment, when the maximum eigenvalue of the target matrix exceeds a specified threshold, it can be considered that there is abnormal data in the sample data. The specified threshold can be given by a staff member or automatically determined by a machine learning model, and the embodiment of this specification is not specifically limited here.
[0069] In some embodiments, each matrix element in the kernel matrix can be calculated by a kernel function to represent the similarity between different samples. In the kernel method of the support vector machine model, the kernel matrix can be used to nonlinearly map sample data from a low-dimensional feature space to a high-dimensional feature space, so that the sample data is easier to classify in the high-dimensional feature space.
[0070] Among them, the larger eigenvalues and corresponding eigenvectors of the kernel matrix can be used to represent the representative dimensions in the high-dimensional space. The larger the eigenvalue, the greater the variance of the sample data distribution in the corresponding dimension, which also means that the information of the sample data for this dimension is more conducive to classification. In addition, when constructing a new feature space, dimensions with larger eigenvalues can also be given priority to reduce the data dimension while retaining important information.
[0071] Therefore, the embodiments of this specification also provide a system for determining a kernel function. By providing a quantum computing system with multiple kernel matrices constructed based on different kernel functions, when processing a batch of sample data, the kernel function with the best mapping effect can be quickly selected by comparing the eigenvalues of the kernel matrix, thereby improving the accuracy of the classification task to a certain extent.
[0072] See also Figure 4 The embodiment of the specification also provides a system for determining a kernel function. The system for determining a kernel function includes: a basic computing unit. The basic computing unit is configured to perform the following steps.
[0073] Step S210: Obtain a matrix set including a plurality of candidate matrices; wherein the plurality of candidate matrices are kernel matrices constructed by different kernel functions and are used to describe the similarity between different sample data.
[0074] In this embodiment, the candidate matrix can be a kernel matrix constructed by different kernel functions for the same batch of sample data. When these kernel matrices are applied to classification tasks, the sample data can be mapped to different feature spaces. Different feature spaces have different gains for classification tasks.
[0075] Since the spectral radius of the kernel matrix can determine the mapping effect of the kernel function, the larger the spectral radius, the better the mapping effect of the corresponding kernel function in mapping sample data to the high-dimensional feature space. Therefore, through the kernel matrix, that is, the maximum eigenvalue, it is relatively convenient to select the kernel function with the best mapping effect.
[0076] Step S220: using the multiple candidate matrices as target matrices, and using a quantum computing system as described in any one of the implementation modes of this specification to obtain target eigenvalues corresponding to the multiple candidate matrices respectively.
[0077] In this embodiment, multiple candidate matrices can be used as target matrices respectively, and the target eigenvalues can be determined by the quantum computing system. By comparing the sizes of the target eigenvalues corresponding to different candidate matrices, the target kernel function can be determined in the kernel functions corresponding to the candidate matrices.
[0078] Step S230: determining a target kernel function from kernel functions corresponding to a plurality of candidate matrices according to the target eigenvalue.
[0079] In some implementations, the target eigenvalue may be the maximum eigenvalue of the kernel matrix. Accordingly, by comparing the target eigenvalues corresponding to different candidate matrices, the kernel function corresponding to the target eigenvalue with the largest value may be selected as the target kernel function.
[0080] In some embodiments, the target eigenvalue may also be the maximum eigenvalue and the second largest eigenvalue of the kernel matrix. Accordingly, by comparing the maximum eigenvalue and the second largest eigenvalue corresponding to different candidate matrices, the target kernel function may also be selected. For example, by comparing the average of the maximum eigenvalue and the second largest eigenvalue corresponding to each candidate matrix, the kernel function corresponding to the candidate matrix with the largest average value may be selected as the target kernel function.
[0081] In some implementations, the target kernel function can be used in a support vector machine model to classify the sample data forming the candidate matrix. The sample data can be financial stock data, image data, text data, etc. The implementation of this specification is not specifically limited here.
[0082] The present embodiment of the specification may provide a computer-readable storage medium having a computer program stored thereon, characterized in that when the computer program is executed by a processor, the steps performed by a quantum measurement and control unit or a basic computing unit in the quantum computing system described in any embodiment of the specification are implemented; or, when the computer program is executed by a processor, the steps performed by a basic computing unit in the determination system of the kernel function described in any embodiment of the specification are implemented.
[0083] The present description may provide a computer program product, characterized in that the computer program product is used to execute the steps performed by the quantum measurement and control unit or the basic computing unit in the quantum computing system described in any embodiment of this specification; or, when the computer program is executed by a processor, it implements the steps performed by the basic computing unit in the determination system of the kernel function described in any embodiment of this specification.
[0084] The present embodiment can provide an electronic device, which includes: a memory, and one or more processors communicatively connected to the memory; the memory stores instructions that can be executed by the one or more processors, and the instructions are executed by the one or more processors to enable the one or more processors to implement the method in any of the above embodiments.
[0085] In some embodiments, the electronic device may include a processor, a non-volatile storage medium, an internal memory, a communication interface, a display device, and an input device connected by a system bus. The non-volatile storage medium may store an operating system and related computer programs.
[0086] It should be understood that the specific examples herein are only intended to help those skilled in the art to better understand the embodiments of the present specification, rather than to limit the scope of the present invention.
[0087] It can be understood that in the various implementations of this specification, the size of the sequence number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the implementation methods of this specification.
[0088] It can be understood that the various embodiments described in this specification can be implemented individually or in combination, and the embodiments of this specification are not limited to this.
[0089] Unless otherwise specified, all technical and scientific terms used in the embodiments of this specification have the same meaning as those generally understood by those skilled in the art of the technical field of this specification. The terms used in this specification are only for the purpose of describing specific embodiments and are not intended to limit the scope of this specification. The term "and / or" used in this specification includes any and all combinations of one or more related listed items. The singular forms of "a", "above", and "the" used in the embodiments of this specification and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.
[0090] It can be understood that the processor of the embodiment of this specification can be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method implementation can be completed by the hardware integrated logic circuit or software instructions in the processor. The above processor can be a general processor, a digital signal processor (Digital Signal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The methods, steps and logic block diagrams disclosed in the embodiment of this specification can be implemented or executed. The general processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in the embodiment of this specification can be directly embodied as a hardware decoding processor to perform, or the hardware and software modules in the decoding processor are combined and executed. The software module can be located in a mature storage medium in the field such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory, and the processor reads the information in the memory and completes the steps of the above method in combination with its hardware.
[0091] It is understood that the memory in the embodiments of this specification may be a volatile memory or a non-volatile memory, or may include both volatile and non-volatile memory. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (programmable ROM, PROM), an erasable programmable read-only memory (erasablePROM, EPROM), an electrically erasable programmable read-only memory (EEPROM) or a flash memory. The volatile memory may be a random access memory (RAM). It should be noted that the memory of the systems and methods described herein is intended to include, but is not limited to, these and any other suitable types of memory.
[0092] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this specification.
[0093] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method implementation methods and will not be repeated here.
[0094] In the several embodiments provided in this specification, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device implementation described above is only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0095] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0096] In addition, each functional unit in each embodiment of the present specification may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0097] If the functions are implemented in the form of software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this specification, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for a computer device (which can be a personal computer, server, or network device, etc.) to perform all or part of the steps of the method described in each embodiment of this specification. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc., various media that can store program codes.
[0098] The above is only a specific implementation of this specification, but the protection scope of the present invention is not limited thereto. Any person skilled in the art who is familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in this specification, which should be included in the protection scope of this specification. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.
Claims
1. A quantum computing system, characterized in that: The quantum computing system is used to determine a target eigenvalue that meets a specified value condition among multiple eigenvalues of a target matrix; The target matrix is a real symmetric matrix in which all matrix elements are positive; The quantum computing system comprises: A plurality of quantum bits; the plurality of quantum bits are divided into a first quantum bit and a second quantum bit; The quantum measurement and control unit is configured to perform the following steps: Exciting the first quantum bit and the second quantum bit to a superposition state with equal probability distribution; Controlled by the quantum state of the first qubit, a phase operator constructed by the target matrix is applied to the second qubit so that a phase factor carrying an eigenvalue of the target matrix is transferred to a probability amplitude of the quantum state of the first qubit; performing an inverse quantum Fourier transform on the first quantum bit; The first quantum bit is measured to obtain a measurement result that can indicate the target characteristic value.
2. The system according to claim 1, characterized in that The target matrix is a kernel matrix used to describe the similarity between different sample data; the target eigenvalue is the eigenvalue of the target matrix with the largest value; the quantum computing system also includes a basic computing unit; the basic computing unit is configured to perform the following steps: Acquire the measurement result; wherein the measurement result includes multiple measurement values obtained by the quantum measurement and control unit measuring the first quantum bit multiple times; Determine the maximum measured value among the multiple measured values as the target feature value; When the target feature value is greater than a specified threshold, it is determined that abnormal data exists in the sample data.
3. The system according to claim 1, characterized in that The quantum phase operator is an exponential function with the Euler number as the base, and the target matrix and the specified imaginary number as the exponential term; the phase factor is an exponent with the Euler number as the base, and the eigenvalue of the target matrix and the specified imaginary number as the exponent of the exponential term.
4. The system according to claim 1, characterized in that There are multiple first quantum bits; the step of controlling the quantum state of the first quantum bit and applying the phase operator constructed by the target matrix to the second quantum bit includes: The phase operator is respectively controlled by the quantum states of the plurality of first quantum bits to act on the second quantum bit for a corresponding number of times; wherein the number of times the phase operator is acted on the second quantum bit controlled by different first quantum bits is different.
5. The system according to claim 4, characterized in that The number of the first quantum bits is N; wherein the i-th first quantum bit is used to control the effect on the second quantum bit 2 (i-1) The phase operator is described below; wherein i is a positive integer less than or equal to N.
6. The system according to claim 1, characterized in that There are multiple second quantum bits; the step of exciting the second quantum bits to a superposition state with equal probability distribution includes: The Hadamard gate is applied to the plurality of second quantum bits respectively, so as to make the second quantum bits reach a superposition state with equal probability distribution.
7. A kernel function determination system, characterized in that: include: The basic computing unit is configured to perform the following steps: Acquire a matrix set including a plurality of candidate matrices; wherein the plurality of candidate matrices are kernel matrices constructed by different kernel functions and are used to describe the similarity between different sample data; Using the multiple candidate matrices as target matrices, and using the quantum computing system according to any one of claims 1, 3 to 4, to obtain target eigenvalues corresponding to the multiple candidate matrices respectively; According to the target eigenvalue, a target kernel function is determined from kernel functions corresponding to a plurality of candidate matrices.
8. The system according to claim 7, characterized in that The target kernel function is used in a support vector machine model to classify the sample data forming the candidate matrix.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it implements the steps performed by a quantum measurement and control unit or a basic computing unit in a quantum computing system as described in any one of claims 1 to 6; or, when the computer program is executed by a processor, it implements the steps performed by a basic computing unit in a kernel function determination system as described in any one of claims 7 to 8.
10. A computer program product, characterized in that The computer program product is used to execute the steps performed by the quantum measurement and control unit or the basic computing unit in the quantum computing system described in any one of claims 1 to 6; or, when the computer program is executed by a processor, it implements the steps performed by the basic computing unit in the kernel function determination system described in any one of claims 7 to 8.
Citation Information
Cited By
Signal spectrum analysis method and device, electronic equipment and readable storage medium
CN118759255A
