CN113434723B - Image retrieval method, device and medium based on quantum Grover algorithm - Google Patents

Image retrieval method, device and medium based on quantum Grover algorithm Download PDF

Info

Publication number
CN113434723B
CN113434723B CN202110574823.5A CN202110574823A CN113434723B CN 113434723 B CN113434723 B CN 113434723B CN 202110574823 A CN202110574823 A CN 202110574823A CN 113434723 B CN113434723 B CN 113434723B
Authority
CN
China
Prior art keywords
quantum
target solution
solution state
state
feature vector
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.)
Active
Application number
CN202110574823.5A
Other languages
Chinese (zh)
Other versions
CN113434723A (en
Inventor
郭雄
张弛
杨宏
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Electronics Standardization Institute
Original Assignee
China Electronics Standardization Institute
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by China Electronics Standardization Institute filed Critical China Electronics Standardization Institute
Priority to CN202110574823.5A priority Critical patent/CN113434723B/en
Publication of CN113434723A publication Critical patent/CN113434723A/en
Application granted granted Critical
Publication of CN113434723B publication Critical patent/CN113434723B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/50Information retrieval; Database structures therefor; File system structures therefor of still image data
    • G06F16/58Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually
    • G06F16/583Retrieval characterised by using metadata, e.g. metadata not derived from the content or metadata generated manually using metadata automatically derived from the content
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06NCOMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
    • G06N10/00Quantum computing, i.e. information processing based on quantum-mechanical phenomena

Abstract

The disclosure provides an image retrieval method, device and medium based on quantum Grover algorithm. The method specifically comprises the following steps: step S1, obtaining a feature vector of an image to be retrieved; s2, calculating the distance between the feature vector and each standard feature vector in a standard database, wherein each standard feature vector corresponds to one standard image; and step S3, determining a standard image corresponding to the standard feature vector with the shortest distance as a result of the image retrieval based on a quantum Grover algorithm. The method achieves the aim of less using iterative operators by measuring and verifying whether the system state solution of the currently obtained quantum system is the target image to be searched, thereby improving the efficiency of image retrieval.

Description

Image retrieval method, device and medium based on quantum Grover algorithm
Technical Field
The disclosure relates to the field of quantum computing, in particular to an image retrieval method, device and medium based on a quantum Grover algorithm.
Background
The quantum computing is a computing mode combining the quantum mechanics principle and classical computing science, and the method utilizes the states of microscopic particles to process and store information, so that parallel computing can be realized. The basic principle of the mode is as follows: firstly, preparing an initial state of information, then completing information processing and storage by utilizing characteristics of state superposition, entanglement, interference and the like in quantum mechanics, and finally measuring an established quantum system by utilizing a measuring system to obtain required information. The quantum superposition state principle can store 2n information in n quantum bits, so that the quantum system has strong information storage capacity, and precious computing resources are saved. Meanwhile, in quantum computing, a series of unitary transformation is realized to realize information operation, and the unitary transformation is the unique reversible transformation without energy loss in quantum mechanics, so that the quantum system has strong information processing capability. The quantum algorithm is soul of quantum computing, and like classical algorithm can save time in classical computing and realize specific function operation, the quantum algorithm can fully embody superiority and strong parallel computing capacity of quantum computing in quantum computing, and is concerned by scientists.
In 1989, deutsch proposed a quantum algorithm that can rapidly verify whether a function is a balance function or an identity function, i.e., deutsch algorithm; 1994, a well-known Shor algorithm was proposed that can accelerate exponentially to get a large factorization operation. The Shor algorithm has wide application in the current cryptography and can decipher an RSA public key cryptosystem. Both quantum algorithms can show that the quantum algorithm has strong accelerating operation capability, and in some specific cases, the computing resource can be greatly saved. In 1996, grover proposed a parallel algorithm for target search in a chaotic database, the main problem of the research of which is actually the inverse of the solution function. The inverse problem of a function can be described as: assuming now that there is a function y=f (x), the Grover algorithm can find the corresponding x value given the y value, which is the inverse of the function. For classical algorithms, an exhaustive method is required to perform the operation, the computational complexity is O (2 n ) The method comprises the steps of carrying out a first treatment on the surface of the The Grover algorithm can reduce the computational complexity of the problem toThe square acceleration function can be realized.
With the development of information society, the use of images and videos is becoming more and more widespread. How to efficiently manage massive image data in the internet age becomes an unavoidable problem. The rapid and accurate image retrieval technology can ensure the rapid and safe development of society. The existing image retrieval scheme has the defects that the retrieval speed is limited by the calculation efficiency in the retrieval process, and the efficiency of image retrieval is seriously influenced. The quantum algorithm and the image retrieval are combined, so that the method has great advantages in the aspects of processing speed, safety, information capacity and the like.
The classical Grover scheme mainly transforms the probability amplitude of the quantum ground state to ensure that the probability amplitude of the quantum ground state corresponding to the solving result reaches the maximumLarge. The initial state of Grover algorithm is a uniform superposition state, which can be obtained by Hadamard transformation on zero state, and then repeatedly applying G iteration operator to initial state |c>: and finally, realizing the probability amplitude of the target solution of the method and simultaneously restraining the probability amplitude of the non-target solution. The target state is marked with a quantum black box oracle operator. The G iteration operator is a core part of the Grover algorithm, and specifically comprises the following 2 steps: (1) Applying the operator o=i-2|t><t|; (2) Application U ψ =2|ψ><ψ| -I. Applying the G iteration operator to the initial state |c>The probability of the target state can be greatly increased and the probability of the non-target state can be greatly reduced by the last k times, so that the high probability can obtain the target solution of the problem.
However, the Grover algorithm also suffers from drawbacks and in some cases fails. For example, let N be the number of data in the database to be searched, i.e. the total capacity of the image database, and M be the number of target images in the database meeting the search requirements. When at M>N/4, the number of iterations is notIn order to search the target image with higher probability, multiple applications of the G iterative operator are required to be added, the probability of obtaining the target solution can be greatly increased, but at the same time, the implementation of the G iterative operator in the quantum circuit of Grover is quite complex, if more G iterative algorithms are called for each calculation, the quantum circuit of the whole algorithm is more complex, so that for the problem of large database, the calculation resource is wasted undoubtedly and the calculation complexity is increased.
Disclosure of Invention
The disclosure provides an image retrieval scheme based on a quantum Grover algorithm to solve the technical problems.
The first aspect of the present disclosure provides an image retrieval method based on a quantum Grover algorithm, the method comprising: step S1, obtaining a feature vector of an image to be retrieved; s2, calculating the distance between the feature vector and each standard feature vector in a standard database, wherein each standard feature vector corresponds to one standard image; and step S3, determining a standard image corresponding to the standard feature vector with the shortest distance as a result of the image retrieval based on a quantum Grover algorithm.
Specifically, in the step S3, determining the shortest distance specifically includes: step S31, initializing the distance between the feature vector and each standard feature vector to define a target solution state and a non-target solution state of the quantum system from the distance; step S32, searching and marking the target solution state of the quantum system from each initialized distance by using a quantum black box Oracle operator O; step S33, turning over the system state of which the target solution state is marked completely so as to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and step S34, measuring the overturned system state, carrying out Oracle function verification on the measured value, and determining that the measured value is the shortest distance if the verification passes.
Specifically, in the step S31, the initializing further includes: based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state.
Specifically, in the step S32, the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by flipping the phase of the target solution state while preserving the phase of the non-target solution state.
Specifically, in the step S34, the verification is to determine whether the measured value satisfies a condition of the target solution state defined in the initialization, and if so, the verification is regarded as passing.
A second aspect of the present disclosure provides an image retrieval apparatus based on a quantum Grover algorithm, the apparatus comprising: an acquisition unit configured to acquire a feature vector of an image to be retrieved; a calculation unit configured to calculate distances between the feature vectors and respective standard feature vectors in a standard database, wherein each standard feature vector corresponds to one standard image; and a determination unit configured to determine, based on a quantum Grover algorithm, a standard image corresponding to a standard feature vector having the shortest distance as a result of the image retrieval
Specifically, the determination unit is further configured to determine the shortest distance according to: initializing the distances between the feature vectors and the standard feature vectors to define a target solution state and a non-target solution state of the quantum system from the distances; searching and marking the target solution state of the quantum system from initialized distances by using a quantum black box Oracle operator O; flipping the system state completing marking the target solution state to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and measuring the system state after the overturn, carrying out Oracle function verification on the measured value, and determining the measured value as the shortest distance if the verification passes.
Specifically, the initializing further includes: based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state.
Specifically, the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by turning over the phase of the target solution state while preserving the phase of the non-target solution state.
Specifically, the verification is to determine whether the measured value satisfies a condition of a target solution state defined in the initialization, and if so, the measured value is regarded as passing the verification.
A third aspect of the present disclosure provides a non-transitory computer readable medium storing instructions which, when executed by a processor, perform steps in an image retrieval method based on a quantum Grover algorithm according to the first aspect of the present disclosure.
In summary, the quantum oracle operator in the Grover algorithm is deformed by the classical oracle verification function, the classical oracle verification function can be added in the later stage of operation while the G iteration operator is reserved, and whether the currently obtained solution is the target image to be searched or not is measured and verified, so that fewer calls of the G iteration operator are achieved, and meanwhile, the G iteration operator is improved, so that the iteration times of the Grover algorithm are reduced, and the image retrieval efficiency is improved.
Drawings
In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the following description will briefly describe the drawings that are required to be used in the embodiments or the description in the prior art, and it is apparent that the drawings in the following description are some embodiments of the present disclosure, and other drawings may be obtained according to these drawings without inventive effort to those skilled in the art.
FIG. 1a is a flow chart of an image retrieval method based on quantum Grover algorithm according to an embodiment of the present disclosure;
FIG. 1b is a flow chart of determining a shortest distance according to an embodiment of the present disclosure;
FIG. 2 is a schematic diagram of an improved Grover algorithm according to an embodiment of the present disclosure;
FIG. 3 is a quantum wire schematic diagram of an improved Grover algorithm according to an embodiment of the present disclosure; and
fig. 4 is a block diagram of an image retrieval device based on a quantum Grover algorithm according to an embodiment of the present disclosure.
Detailed Description
The following description of the embodiments of the present disclosure will be made clearly and fully with reference to the accompanying drawings, in which it is evident that the embodiments described are some, but not all, of the embodiments of the present disclosure. Based on the embodiments in this disclosure, all other embodiments that a person of ordinary skill in the art would obtain without making any inventive effort are within the scope of protection of this disclosure.
The first aspect of the present disclosure provides an image retrieval method based on a quantum Grover algorithm. FIG. 1a is a flow chart of an image retrieval method based on quantum Grover algorithm according to an embodiment of the present disclosure; as shown in fig. 1a, the method comprises: step S1, obtaining a feature vector of an image to be retrieved; s2, calculating the distance between the feature vector and each standard feature vector in a standard database, wherein each standard feature vector corresponds to one standard image; and step S3, determining a standard image corresponding to the standard feature vector with the shortest distance as a result of the image retrieval based on a quantum Grover algorithm.
FIG. 1b is a flowchart of determining the shortest distance according to an embodiment of the present disclosure, as shown in FIG. 1b, where determining the shortest distance specifically includes: step S31, initializing the distance between the feature vector and each standard feature vector to define a target solution state and a non-target solution state of the quantum system from the distance; step S32, searching and marking the target solution state of the quantum system from each initialized distance by using a quantum black box Oracle operator O; step S33, turning over the system state of which the target solution state is marked completely so as to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and step S34, measuring the overturned system state, carrying out Oracle function verification on the measured value, and determining that the measured value is the shortest distance if the verification passes.
In some embodiments, defining the target solution state includes randomly selecting an element t [ y ] with subscript y from the database]Let t [ y ]]As a minimum. Let y1=y, and randomly select an element t [ y2 ] of subscript y2, different from y1, from the database]. If the element t [ j ] with subscript j]Satisfy the following requirementsAnd->Then call t [ j ]]For the target solution, |t>Referred to as the target solution state. Others are non-target solution states.
In some embodiments, first, a graph is computedFeature vectors of all images in the image library are stored in a certain database a. The feature vectors of the images to be searched are also saved in the database a. And calculating the distance between the image to be searched and the feature vectors of all the images in the database, and storing the calculation result in the other database B. When the distance between the feature vectors is smaller, the images are considered to be more similar, and then the image retrieval problem is converted into a problem of retrieving the minimum value in the database B with the size of n=2n, and the image corresponding to the minimum value is the target image. The number of images conforming to the search target is M, and the probability of occurrence of the target image is
In step S31, the distances between the feature vectors and the respective standard feature vectors are initialized. Specifically, the initializing further includes: based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state.
In some embodiments, preparing the initial state of all 0's includes first preparing the initial stateAs an initial state of the quantum search problem system. Wherein->As a tensor operation, the system is made into an n-dimensional hilbert space, n representing the qubit of the system.
In some embodiments, preparing a homogeneous quantum superposition state includes converting an initial state into a homogeneous quantum superposition state using a Hadamard operator HThe matrix of Hadamard operators is expressed as:
the function of this operator is to store all N elements in the image database B in the above qubits and to present each solution with a uniform probability. Decomposing the uniform superposition state into a sum of normalized target solution states:
and the sum of normalized non-target solution states:
the uniform quantum superposition |ψ > can be expressed as:
order theThe uniform quantum superposition state can be written as |ψ>=cosθ|α>+sinθ|β>。
In step S32, the target solution state of the quantum system is looked up and marked from the initialized respective distances using a quantum black box Oracle operator O. Specifically, the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by turning over the phase of the target solution state while preserving the phase of the non-target solution state.
In some embodiments, marking the target state includes marking the target state using a quantum black box Oracle operator O, derived from a classical Oracle validation function, typically in the form of a quantum black box Oracle operator: o=i-2|t > < t|, where t is the target solution. The function of the O operator in this method is to find whether the target solution state |t > exists in the uniform superimposed state |ψ >, such that t is the minimum solution. If this state exists, it is marked. Applying O operators to |a >, |β > respectively, yields:
O|β>=(I-2|t><t|)|β>=|β>-2|β>=-|β>
O|α>=(I-2|t><t|>|α>=|α>-0=|α>
it can be seen that the O operator acts to flip the phase of the target solution state |β >, i.e., a negative sign is added before the target solution state, without any effect on the non-target solution state |a >, which then acts to mark the target solution state.
In step S33, the system state that completes marking the target solution state is flipped to approach the target solution state, so that the probability amplitude of the target solution state is enlarged and the probability amplitude of the non-target solution state is reduced.
In some embodiments, the current system state is flipped. Definition of the flip operator U ψ So that U ψ =2|ψ><psi-I, the operator functions to set the current system state to the system initial state |psi>The inversion is performed for the symmetry axis so that the probability amplitude of the target solution state is amplified and the probability amplitude of the non-target solution state is reduced. Wherein O operator and U ψ Merging is called G iterative operator, g=u ψ O, which is the core of the Grover algorithm. Applying 2 times a G iteration operator (G 2 ) The state change of the system is as follows:
1 >=G|ψ>=G(cosθ|α>+sinθ|β>)
=cos3θ|α>+sin3θ|β>
2 >=G|ψ 1 >=G(cos3θ|α>+sin3θ|β>)
=cos5θ|α>+sin5θ|β>
let phi>=|ψ 2 >=G 2 |ψ>Reference U ψ =2|ψ><psi-I in state phi>For reference, a new flip operator U is defined φ =2|φ><phi-I. Easily-knownU φ The operators are unitary operators. Define a new iterative operator, set to G' =u φ O. For system state |phi after inversion>Applying G' operatorsSecondary (wherein->Representing a rounding-up operation) such that the system state after the operation approaches the target solution state |β>。
In step S34, the system state after the overturn is measured, and the measured value is subjected to Oracle function verification, and if the verification passes, the measured value is determined to be the shortest distance. Specifically, in the step S34, the verification is to determine whether the measured value satisfies a condition of the target solution state defined in the initialization, and if so, the verification is regarded as passing.
In some embodiments, the flipped system state is measured and Oracle function verification is performed on the measured values:
if the measured value y' satisfies: let y '=y and output y when t [ y' ] < t [ y ], where t [ y ] is the shortest distance in the database B, and the corresponding standard image is the matching image obtained by searching.
Fig. 2 is a schematic diagram of a modified Grover algorithm according to an embodiment of the present disclosure, as shown in fig. 2, in which a target solution state is first defined from an image database, and an entire quantum system initialization process is completed through all-zero initialization and uniform superposition state preparation. And then searching for a target state solution through the operation of the G iteration operator, and finally obtaining a final target matching image through quantum measurement and oracle function verification. Specific quantum wire implementation is shown in fig. 3, fig. 3 is a quantum wire schematic diagram of an improved Grover algorithm according to an embodiment of the present disclosure.
In summary, since the modified Grover algorithm is measured once and verified by classical oracle, a solution to the inverse problem of the function can be found with a probability of 2/3. Therefore, the image retrieval method using the improved Grover algorithm has higher success rate. In other words, the method applies x+2 iterative operators, and then through multiple quantum measurement and classical oracle function verification, the target image in the database can be found with a probability of more than 2/3. Compared with the quantum circuit of the classical Grover algorithm iterative operator, the improved Grover algorithm combines the Grover quantum algorithm with classical verification, so that the calling times of the G quantum circuit are reduced, and the complexity of the quantum circuit of the algorithm is reduced. Meanwhile, a new G iteration operator is introduced, so that the searching success probability basis (reaching 95%) of the algorithm can be maintained, and the required G iteration operator is reduced to 1/5 of the original G iteration operator, thereby improving the efficiency of image retrieval.
A second aspect of the present disclosure provides an image retrieval device based on a quantum Grover algorithm. Fig. 4 is a block diagram of an image retrieval apparatus based on a quantum Grover algorithm according to an embodiment of the present disclosure, and as shown in fig. 4, the apparatus 400 includes: an acquisition unit 401 configured to acquire a feature vector of an image to be retrieved; a computing unit 402 configured to compute a distance between the feature vector and each standard feature vector in a standard database, wherein each standard feature vector corresponds to one standard image; and a determining unit 403 configured to determine, based on a quantum Grover algorithm, a standard image corresponding to a standard feature vector having the shortest distance as a result of the image retrieval
Specifically, the determining unit 403 is further configured to determine the shortest distance according to the following manner: initializing the distances between the feature vectors and the standard feature vectors to define a target solution state and a non-target solution state of the quantum system from the distances; searching and marking the target solution state of the quantum system from initialized distances by using a quantum black box Oracle operator O; flipping the system state completing marking the target solution state to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and measuring the system state after the overturn, carrying out Oracle function verification on the measured value, and determining the measured value as the shortest distance if the verification passes.
Specifically, the initializing further includes: based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state.
Specifically, the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by turning over the phase of the target solution state while preserving the phase of the non-target solution state.
Specifically, the verification is to determine whether the measured value satisfies a condition of a target solution state defined in the initialization, and if so, the measured value is regarded as passing the verification.
A third aspect of the present disclosure provides a non-transitory computer readable medium storing instructions which, when executed by a processor, perform steps in an image retrieval method based on a quantum Grover algorithm according to the first aspect of the present disclosure.
In summary, the quantum oracle operator in the Grover algorithm is deformed by the classical oracle verification function, the classical oracle verification function can be added in the later stage of operation while the G iteration operator is reserved, and whether the currently obtained solution is the target image to be searched or not is measured and verified, so that fewer calls of the G iteration operator are achieved, and meanwhile, the G iteration operator is improved, so that the iteration times of the Grover algorithm are reduced, and the image retrieval efficiency is improved.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present disclosure, and not for limiting the same; although the present disclosure has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some or all of the technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present disclosure.

Claims (3)

1. An image retrieval method based on a quantum over algorithm, which is characterized by comprising the following steps:
step S1, obtaining a feature vector of an image to be retrieved;
s2, calculating the distance between the feature vector and each standard feature vector in a standard database, wherein each standard feature vector corresponds to one standard image; and
s3, determining a standard image corresponding to the standard feature vector with the shortest distance as a result of image retrieval based on a quantum Grover algorithm;
wherein, in the step S3, determining the shortest distance specifically includes:
step S31, initializing the distance between the feature vector and each standard feature vector to define a target solution state and a non-target solution state of the quantum system from the distance;
wherein the initializing further comprises:
based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state;
step S32, searching and marking the target solution state of the quantum system from each initialized distance by using a quantum black box Oracle operator O;
the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by turning over the phase of the target solution state and retaining the phase of the non-target solution state;
step S33, turning over the system state of which the target solution state is marked completely so as to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and
step S34, measuring the system state after overturning, carrying out Oracle function verification on the measured value, and determining that the measured value is the shortest distance if the verification passes;
the Oracle function verification is specifically as follows: and judging whether the measured value meets the condition of the target solution state defined in the initialization, and if so, judging that the measured value passes the verification.
2. An image retrieval apparatus based on quantum Grover algorithm, the apparatus comprising:
an acquisition unit configured to acquire a feature vector of an image to be retrieved;
a calculation unit configured to calculate distances between the feature vectors and respective standard feature vectors in a standard database, wherein each standard feature vector corresponds to one standard image; and
a determination unit configured to determine, based on a quantum Grover algorithm, a standard image corresponding to a standard feature vector having a shortest distance as a result of the image retrieval;
wherein the determining unit is further configured to determine the shortest distance according to:
initializing the distances between the feature vectors and the standard feature vectors to define a target solution state and a non-target solution state of the quantum system from the distances;
wherein the initializing further comprises:
based on the initial all-zero state of the quantum system, storing each distance on a quantum bit of the quantum system by utilizing a Hadamard operator H, so that the quantum system is in a quantum uniform superposition state;
searching and marking the target solution state of the quantum system from initialized distances by using a quantum black box Oracle operator O;
the quantum black box Oracle operator O searches the target solution state in the quantum uniform superposition state, and marks the target solution state of the quantum system by turning over the phase of the target solution state and retaining the phase of the non-target solution state;
flipping the system state completing marking the target solution state to be close to the target solution state, so that the probability amplitude of the target solution state is amplified, and the probability amplitude of the non-target solution state is reduced; and
measuring the system state after overturning, carrying out Oracle function verification on the measured value, and determining that the measured value is the shortest distance if the verification passes;
the Oracle function verification is specifically as follows: and judging whether the measured value meets the condition of the target solution state defined in the initialization, and if so, judging that the measured value passes the verification.
3. A non-transitory computer readable medium storing instructions which, when executed by a processor, perform the steps of a quantum Grover algorithm based image retrieval method according to claim 1.
CN202110574823.5A 2021-05-26 2021-05-26 Image retrieval method, device and medium based on quantum Grover algorithm Active CN113434723B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110574823.5A CN113434723B (en) 2021-05-26 2021-05-26 Image retrieval method, device and medium based on quantum Grover algorithm

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110574823.5A CN113434723B (en) 2021-05-26 2021-05-26 Image retrieval method, device and medium based on quantum Grover algorithm

Publications (2)

Publication Number Publication Date
CN113434723A CN113434723A (en) 2021-09-24
CN113434723B true CN113434723B (en) 2023-10-10

Family

ID=77802809

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110574823.5A Active CN113434723B (en) 2021-05-26 2021-05-26 Image retrieval method, device and medium based on quantum Grover algorithm

Country Status (1)

Country Link
CN (1) CN113434723B (en)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1383078A1 (en) * 2002-07-08 2004-01-21 STMicroelectronics S.r.l. Quantum gate for carrying out a Grover's quantum algorithm and a relative method of performing the interference operation of a Grover's quantum algorithm
CN102955855A (en) * 2012-10-30 2013-03-06 河南理工大学 Palm print database search method based on quantum algorithms
CN105960651A (en) * 2013-12-05 2016-09-21 微软技术许可有限责任公司 A method and system for computing distance measures on a quantum computer
CN106650808A (en) * 2016-12-20 2017-05-10 北京工业大学 Image classification method based on quantum nearest-neighbor algorithm
CN107204008A (en) * 2017-06-08 2017-09-26 上海海事大学 Quantum image matching method
CN107622312A (en) * 2017-10-18 2018-01-23 浙江工商大学 Based on the quantum coherence and the method for quantum entanglement under Grover searching algorithms
CN110162536A (en) * 2019-04-10 2019-08-23 深圳大学 A kind of quantum searching method, system, electronic device and storage medium
CN110569711A (en) * 2019-07-19 2019-12-13 沈阳工业大学 human body action oriented recognition method
CN112182494A (en) * 2020-09-27 2021-01-05 中国人民解放军战略支援部队信息工程大学 Integer decomposition optimization method and system based on Grover quantum computing search algorithm

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10891555B2 (en) * 2018-08-07 2021-01-12 Nxgen Partners Ip, Llc Universal quantum computer, communication, QKD security and quantum networks using OAM Qu-dits with digital light processing
US11079790B2 (en) * 2018-08-28 2021-08-03 Synopsys, Inc. Semiconductor digital logic circuitry for non-quantum enablement of quantum algorithms

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1383078A1 (en) * 2002-07-08 2004-01-21 STMicroelectronics S.r.l. Quantum gate for carrying out a Grover's quantum algorithm and a relative method of performing the interference operation of a Grover's quantum algorithm
CN102955855A (en) * 2012-10-30 2013-03-06 河南理工大学 Palm print database search method based on quantum algorithms
CN105960651A (en) * 2013-12-05 2016-09-21 微软技术许可有限责任公司 A method and system for computing distance measures on a quantum computer
CN106650808A (en) * 2016-12-20 2017-05-10 北京工业大学 Image classification method based on quantum nearest-neighbor algorithm
CN107204008A (en) * 2017-06-08 2017-09-26 上海海事大学 Quantum image matching method
CN107622312A (en) * 2017-10-18 2018-01-23 浙江工商大学 Based on the quantum coherence and the method for quantum entanglement under Grover searching algorithms
CN110162536A (en) * 2019-04-10 2019-08-23 深圳大学 A kind of quantum searching method, system, electronic device and storage medium
CN110569711A (en) * 2019-07-19 2019-12-13 沈阳工业大学 human body action oriented recognition method
CN112182494A (en) * 2020-09-27 2021-01-05 中国人民解放军战略支援部队信息工程大学 Integer decomposition optimization method and system based on Grover quantum computing search algorithm

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
先进计算研究与标准研究;杨宏等;《中国标准化》;243-245 *
在纠缠量子系统中的图像几何形状存储和检索;黎海生等;《华东交通大学学报》;14-18 *

Also Published As

Publication number Publication date
CN113434723A (en) 2021-09-24

Similar Documents

Publication Publication Date Title
Larocca et al. Group-invariant quantum machine learning
Liu et al. Intelligent and secure content-based image retrieval for mobile users
US11575502B2 (en) Homomorphic encryption processing device, system including the same and method of performing homomorphic encryption processing
JP2019079226A (en) Conversion device, determination device, and calculation device
Tezuka et al. Grover search revisited: Application to image pattern matching
Knill et al. Introduction to quantum information processing
Wong et al. Quantum speedup for protein structure prediction
AU2022201682A1 (en) Method and apparatus for denoising quantum device, electronic device, and computer readable medium
Yang et al. Image feature extraction in encrypted domain with privacy-preserving Hahn moments
CN111107076A (en) Safe and efficient matrix multiplication outsourcing method
Lisnichenko et al. Quantum image representation: A review
Riazi et al. Sub-linear privacy-preserving near-neighbor search
CN113434723B (en) Image retrieval method, device and medium based on quantum Grover algorithm
Caraiman et al. New applications of quantum algorithms to computer graphics: the quantum random sample consensus algorithm
Tiepelt et al. Quantum LLL with an application to mersenne number cryptosystems
Lloyd et al. Quantum algorithms for topological and geometric analysis of big data
Miao et al. Isometric tensor network optimization for extensive Hamiltonians is free of barren plateaus
Duan et al. Hamiltonian-based data loading with shallow quantum circuits
Jiang et al. Quantum image sharpness estimation based on the Laplacian operator
Petrenko et al. Universal quantum gate as a tool for modeling quantum cryptanalysis algorithms on a quantum circuit
Chang Parameterized Quantum Circuits with Quantum Kernels for Machine Learning: A Hybrid Quantum-Classical Approach
Wu et al. Secure data sharing with flow model
Allgood A quantum algorithm to locate unknown hashes for known n-grams within a large malware corpus
Wang et al. Bang-bang algorithms for quantum many-body ground states: A tensor network exploration
Ghosh et al. Existential Unforgeability in Quantum Authentication From Quantum Physical Unclonable Functions Based on Random von Neumann Measurement

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant