CN109993310A - Parallel Quantum Evolutionary implementation method based on FPGA - Google Patents
Parallel Quantum Evolutionary implementation method based on FPGA Download PDFInfo
- Publication number
- CN109993310A CN109993310A CN201910305526.3A CN201910305526A CN109993310A CN 109993310 A CN109993310 A CN 109993310A CN 201910305526 A CN201910305526 A CN 201910305526A CN 109993310 A CN109993310 A CN 109993310A
- Authority
- CN
- China
- Prior art keywords
- state
- article
- quantum
- chromosome
- parallel
- 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.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06N—COMPUTING ARRANGEMENTS BASED ON SPECIFIC COMPUTATIONAL MODELS
- G06N3/00—Computing arrangements based on biological models
- G06N3/12—Computing arrangements based on biological models using genetic models
- G06N3/126—Evolutionary algorithms, e.g. genetic algorithms or genetic programming
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06Q—INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
- G06Q10/00—Administration; Management
- G06Q10/04—Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02D—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
- Y02D10/00—Energy efficient computing, e.g. low power processors, power management or thermal management
Abstract
The Parallel Quantum Evolutionary implementation method based on FPGA that the invention discloses a kind of mainly solves the problems, such as the prior art not really by hardware realization quantum function.Its implementation are as follows: 1) initialization population and greatest iteration number;2) init state matrix;3) it is configured FPGA as the equipment end of open operation language OpenCL;4) by parallel quantum observation state matrix, chromosome is obtained;5) chromosome is modified;6) fitness value is calculated according to modified chromosome, and to not being that the corresponding chromosome of adaptive optimal control angle value updates;8) step 4) -6 is repeated), terminate to evolve until finding globally optimal solution or reaching maximum number of iterations.The present invention utilizes the concurrency of FPGA, Parallel Implementation quantum evolution, while FPGA being made to be provided with the basic function of quantum, can be applied to Industrial Engineering, network communication and traffic programme.
Description
Technical field
The invention belongs to quantum technical fields, further relate to a kind of Parallel Quantum Evolutionary implementation method, can apply
In Industrial Engineering, network communication and traffic programme.
Background technique
Quantum evolutionary algorithm is to solve a kind of method particularly important in combinatorial optimization problem.But due to quantum computer
Problem is captured, expeditiously quantum evolutionary algorithm can not be applied in practical problem.
Qian Jie is mentioned in the paper " the quantum evolution method for solving of multiple quadratic knapsack problem " that Wang Baohua et al. delivers at it
Go out to calculate using quantum evolution and has solved combinatorial optimization problem.The quantum observation operation of the quantum evolutionary algorithm can will be at partially restrained
Reason is completed with one step of observation, and decoding efficiency is high and is not easy to fall into local optimum.The result of test experiments also indicates that this algorithm ratio
The precision of traditional algorithm and more efficient.In fact, quantum observation and quantum, which update, has parallel characteristics, but in this method
Quantum observation and update are serial implementations, do not embody the concurrency of quantum really.
The paper " Parallel Quantum Evolutionary Algorithm based on MapReduce model " that Jia Ruiyu, Liu Fanfan et al. are delivered at it
In disclose a kind of method based on MapReduce model Parallel Quantum Evolutionary Algorithm.This article proposes to be based on MapReduce
The Parallel Quantum Evolutionary Algorithm MRQEA of model, and be deployed in Hadoop cloud computing platform and run.By to 0-1 knapsack
The test result of problem proves that MRQEA algorithm has good speed-up ratio and parallel efficiency when handling large data collection.But
Deficiency existing for this method is, first, since the programming model that this method uses is complicated, and run based on large-scale cluster, nothing
Method uses whenever and wherever possible;Second, this method is due to only by the parallel quantum evolution of the distributed parallel thought of MapReduce
Algorithm, thus there is no really pass through hardware realization quantum function.
Summary of the invention
It is an object of the invention in view of the above shortcomings of the prior art, propose a kind of Parallel Quantum Evolutionary based on FPGA
Implementation method, to update function using the observation of the quantum of high-performance hardware FPGA Parallel Implementation quantum evolutionary algorithm and Quantum rotating gate
Can, make hardware that there is the basic function of quantum, and there is higher portability, simpler operation and lower power consumption, simultaneously
It can guarantee timeliness of the quantum algorithm in solving practical problems.
Realizing the object of the invention basic ideas is: using the concurrency of high-performance hardware FPGA, by quantum observation and quantum
Revolving door updates original serial mode processing mode and is changed to parallel processing manner, realizes quantum parallelism, and utilize the algorithm
Combinatorial optimization problem in practice, such as Multidimensional Knapsack Problems are solved, implementation step includes the following:
(1) value and limitation data of article are read in, and is stored in the matrix form;
(2) init state matrix uses state matrixIndicate the quantum state of solution, wherein m is
The number of article, t are indicated in t for the probability amplitude that α and β are that gene position takes 0 and 1 respectively;As t=0,
(3) using FPGA as the equipment end of open operation language OpenCL, and equipment end working group is divided, in creation two
Core, wherein first kernel Parallel Implementation quantum observation, second kernel update state matrix parallel;
(4) it is observed by parallel quantum, obtains chromosome coding string:
(4a) generates random number in (0,1) range in central processor CPU host side, and by the β of itself and state matrix
Value is passed to together in the global memory of open operation language OpenCL equipment end;
(4b) executes first kernel, i.e., Parallel Implementation is to state matrix in open operation language OpenCL equipment end
Quantum observation, obtain the chromosome coding string after state matrix is repeatedly observed, then be copied in central processor CPU host side
In depositing;
(5) chromosome is corrected:
(5a) limits data according to chromosome coding string, article, judges whether to meet constraint condition:
If meeting constraint condition executes (5b), otherwise, execute (5c), wherein X=(x1…xm), xi=0 or 1 indicates i-th
The state of article, w indicate the limitation of article, CjFor the constraint condition of jth dimension.
(5b) corrects chromosome according to the Item Value that state is " 0 " and limitation ratio, until it is unsatisfactory for constraint condition, then
It according to the fitness value E of revised chromosome and Item Value data calculating target function, is currently solved, and is judged current
Whether solution is optimal solution, if so, otherwise the current solution of output executes (6);
(5c) corrects chromosome according to the value that state is " 1 " and limitation ratio, until meet constraint condition, further according to repairing
The fitness value E of chromosome and Item Value data calculating target function after just, is currently solved, and whether judge current solution
It for optimal solution, solves if so, output is current, otherwise, executes (6);
(6) state matrix is updated parallel:
Current solution, the preceding optimal solution once obtained and state matrix U are passed in central processor CPU host side and open by (6a)
In the global memory for putting operation language OpenCL equipment end;
(6b) executes second kernel, i.e., concurrently to current state matrix in open operation language OpenCL equipment
It is updated to obtain new state matrix, and is copied in the memory of central processor CPU host side;
(7) step (4)-(6) are repeated, terminate to evolve until finding globally optimal solution or reaching maximum number of iterations.
Compared with the prior art, the present invention has the following advantages:
First, the present invention directly utilizes the concurrency of OpenCL hardware device, and quantum observation and Quantum rotating gate are updated
Original serial mode processing mode is changed to parallel processing manner, and the concurrency of quantum algorithm is realized from hardware view, and
Hardware can be made to have quantum basic function after primary compiling.
Second, the present invention realizes Parallel Quantum Evolutionary Algorithm on OpenCL hardware device FPGA, compared to directly existing
Simulation result on computer, FPGA are low in energy consumption and high-efficient;Compared to large-scale high property cluster, FPGA is small in size, can be portable,
It is easy to operate.In addition, quantum energy can be made to use in more hardware platforms using OpenCL programming framework.
Detailed description of the invention
Fig. 1 is implementation flow chart of the invention;
Fig. 2 is to divide schematic diagram in the working group of OpenCL equipment end in the present invention;
Fig. 3 is that first Core Operational item task divides schematic diagram in the present invention;
Fig. 4 is that second Core Operational item task divides schematic diagram in the present invention;
Fig. 5 is the experimental result that the present invention is applied to Multidimensional Knapsack Problems.
Specific embodiment
With reference to the accompanying drawing, the embodiment of the present invention and effect are described in further detail.
The bright embodiment of this law be used for solve Multidimensional Knapsack Problems, i.e., using the present invention realize loaded article not
In the case where more than knapsack constraint, guarantee that the article total value for being packed into knapsack is maximum.
Referring to Fig.1, specific implementation step of the invention is described in further detail:
Step 1, initialization data and parameter.
The value of article and the weight data and volume data of article 1a) are read in, and is stored in the matrix form, knapsack is set
Constraint, maximum number of iterations parameter, largest item total value, the wherein value data of article such as table 1, the weight data of article
Such as table 2 and volume data table 3;
1. Item Value data of table
41850 | 38261 | 23800 | 21697 | 7074 | 5587 | 5560 |
5500 | 3450 | 2391 | 761 | 460 | 367 | 24785 |
47910 | 30250 | 107200 | 4235 | 9835 | 9262 | 15000 |
6399 | 6155 | 10874 | 37100 | 27040 | 4117 | 32240 |
1600 | 4500 | 70610 | 6570 | 15290 | 23840 | 16500 |
7010 | 16020 | 8000 | 31026 | 2568 | 2365 | 4350 |
1972 | 4975 | 29400 | 7471 | 2700 | 3840 | 22400 |
3575 | 13500 | 1125 | 11950 | 12753 | 10568 | 15600 |
20652 | 13150 | 2900 | 1790 | 4970 | 5770 | 8180 |
2450 | 7140 | 12470 | 6010 | 16000 | 11000 | 11093 |
4685 | 2590 | 11500 | 5820 | 2842 | 5000 | 3300 |
2800 | 5420 | 900 | 13300 | 8540 | 7140 | 12470 |
6010 | 16000 | 11100 | 11093 | 4685 | 2590 | 11500 |
5820 | 2842 | 5000 | 3300 | 2800 | 5420 | 900 |
13300 | 8450 | 5300 | 750 | 1435 | 2100 | 7215 |
2605 | 2422 | 5500 | 8550 | 2700 | 540 | 2550 |
2450 | 725 | 445 | 700 | 1720 | 2675 | 220 |
300 | 405 | 150 | 70 |
2. weight data of table
75 | 40 | 365 | 95 | 25 | 17 | 125 | 20 | 22 | 24 | 75 | 50 | 15 | 0 | 0 |
12 | 0 | 10 | 0 | 50 | 0 | 0 | 10 | 0 | 0 | 50 | 60 | 150 | 0 | 0 |
75 | 0 | 102 | 0 | 0 | 40 | 60 | 0 | 165 | 0 | 0 | 0 | 45 | 0 | 0 |
0 | 25 | 0 | 150 | 0 | 0 | 0 | 158 | 0 | 85 | 95 | 0 | 89 | 20 | 0 |
0 | 0 | 0 | 0 | 0 | 80 | 0 | 110 | 0 | 15 | 0 | 60 | 5 | 135 | 0 |
0 | 25 | 0 | 300 | 35 | 100 | 0 | 0 | 25 | 0 | 0 | 225 | 25 | 0 | 0 |
0 | 0 | 0 | 0 | 0 | 5 | 0 | 60 | 0 | 100 | 0 | 0 | 0 | 0 | 0 |
3. volume data of table
0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 0 | 5 | 10 |
10 | 50 | 2 | 5 | 5 | 10 | 5 | 6 | 11 | 41 | 30 | 5 | 40 | 2 | 6 |
100 | 10 | 25 | 39 | 30 | 13 | 30 | 15 | 60 | 5 | 5 | 10 | 5 | 15 | 91 |
24 | 10 | 15 | 90 | 15 | 60 | 5 | 55 | 60 | 50 | 75 | 100 | 65 | 15 | 10 |
30 | 35 | 50 | 15 | 45 | 80 | 40 | 110 | 80 | 80 | 36 | 20 | 90 | 50 | 25 |
50 | 35 | 30 | 60 | 10 | 150 | 110 | 70 | 10 | 20 | 30 | 104 | 40 | 40 | 94 |
150 | 50 | 10 | 50 | 50 | 16 | 10 | 20 | 50 | 90 | 10 | 15 | 39 | 20 | 20 |
Knapsack 1b) is arranged is constrained to 3000, and the present embodiment is provided with 2 dimension constraints, and the maximum of every one-dimensional representation knapsack holds
Amount, if maximum number of iterations is 300, largest item total value is set as 1095445.
Step 2, init state matrix.
State matrix U is for indicating Multidimensional Knapsack Problems solution in the state of vector subspace in quantum evolution, it is with probability
Width improves the diversity of Multidimensional Knapsack Problems solution as gene position.Its representation is as follows:
Wherein m is the number of article, and t is indicated in t for the probability amplitude that α and β are that gene position takes 0 and 1 respectively;Work as t=0
When,
Step 3, it is configured FPGA as the equipment end of open operation language OpenCL.
3a) central processor CPU host side and open operation language OpenCL equipment end are connected by PCIe bus interface
It connects, for powering for FPGA, FPGA and host side is made to carry out data communication end to end;
3b) divide open operation language OpenCL equipment end working group:
Referring to Fig. 2, this step is implemented as follows:
Two kernels 3b1) are created, wherein first kernel Parallel Implementation quantum observation, second kernel update shape parallel
State matrix.
3b2) according to two subtasks that two kernels are in quantum evolution, two work are marked off in OpenCL equipment end
Group is responsible for executing the two subtasks, and as a result such as Fig. 2, wherein Fig. 2 (a) is the job crew group of OpenCL equipment end, each
Working group is all two dimension;Fig. 2 (b) is the working group after dividing, and working group is one-dimensional.
Step 4, it is observed by parallel quantum, obtains chromosome coding string.
4a) central processor CPU host side generate (0,1) range in random number, and by its in state matrix U
β value is passed to together in the global memory of open operation language OpenCL equipment end;
4b) in open operation language OpenCL equipment end, first kernel is executed, i.e., Parallel Implementation is to state matrix
Quantum observation:
Referring to Fig. 3, which is further described:
In Fig. 3 abscissa be divide after working group in work item global line index, each work item be responsible for one with
Machine number is compared with β value, if random number is greater than β value, gene position state is collapsed in 1, and otherwise, gene position state is collapsed in 0, most
The chromosome coding string after state matrix is repeatedly observed is obtained afterwards, then chromosome coding string is copied to central processor CPU master
In generator terminal memory.
Step 5, chromosome is corrected.
5a) according to chromosome coding string, the weight data and volume data of article, judge whether the constraint for meeting knapsack:
Wherein X=(x1…xm), xiWhether be put into i-th article in=0 or 1 expression knapsack, w indicate article weight or
Volume, CjKnapsack for jth dimension constrains:
If meeting the constraint of knapsack, according to the Item Value and weight ratio or Item Value and volume ratio that state is " 0 ",
Execute 5b),
If being unsatisfactory for the constraint of knapsack, according to the Item Value and weight ratio or Item Value and volume that state is " 1 "
Than executing 5c),
5b) chromosome for meeting constraint is modified:
5b1) calculate the cost performance for i-th of article that state in j dimension is " 0 ":And by gained
As a result c is arranged in descending order, wherein v is the value of article, and w is the weight or volume of article, and n is number of dimensions;
It 5b2) begins stepping through from the highest article of cost performance, if the state for having article is " 0 ", is set as in order of sequence
" 1 " keeps the state if the state of article is " 1 ", until the chromosome is unsatisfactory for constraining, terminates amendment;
5c) chromosome for being unsatisfactory for constraint is corrected:
5c1) calculate i-th of article cost performance that state in j dimension is " 1 ":And gained is tied
Fruit c is arranged in descending order, wherein v is the value of article, and w is the weight or volume of article, and n is number of dimensions;
It 5c2) begins stepping through according to sequence order from the minimum article of cost performance, if the state of article is " 1 ", is set as
" 0 " keeps the state if the state of article is " 0 ", until the chromosome meets constraint, terminates amendment;
Step 6, fitness value is calculated.
According to the fitness value E of revised chromosome each time and Item Value data calculating target function:
Wherein, X=(x1…xm), P=(p1…pm), xiI-th article, p whether are put into in=0 or 1 expression knapsackiIt is pair
Answer the value of article;
Judge whether the fitness value E currently obtained is bigger than the preceding fitness value once obtained, if so, output is current suitable
Angle value is answered, otherwise, the fitness value once obtained before keeping executes step 7.
Step 7, state matrix is updated parallel.
7a) in central processor CPU host side, by current solution E, the preceding optimal solution once obtained and state matrix U, together
In the global memory of incoming open operation language OpenCL equipment end;
7b) in open operation language OpenCL equipment, execute second kernel, i.e., concurrently to current state matrix into
Row, which updates, obtains new state matrix:
Referring to Fig. 4, this step is implemented as follows:
Abscissa is the global line index of work item in the working group after dividing in Fig. 4, and each work item is responsible for updating shape
A quantum gene position in state matrix U is updated each quantum gene position using Quantum rotating gate, Quantum rotating gate
Form it is as follows:
Quantum gene position in updated state matrix are as follows:
Updated state matrix is finally obtained, form is as follows:
WhereinWithRespectively updated i-th of gene position takes 0 and takes 1 probability amplitude, and i=1,2 ..., m, m are
The number of article, wherein θi=s (αiβi)*Δθi, i=1 ..., m are each quantum gene positions towards 0 or 1 rotation angle, s
(αiβi) it is direction of rotation, Δ θiIt is angle step;
s(αiβi) value such as following table
Wherein E is current fitness value, EbestIt is optimal fitness value, xiAnd biRespectively corresponding current solution and most
I-th of value in excellent solution.
Step 8, repeat step 4 to step 7, until find largest item total value or reach maximum number of iterations terminate into
Change.
Effect of the invention is described in further detail below with reference to emulation experiment.
1. emulation experiment condition:
Emulation experiment condition are as follows: AMD isomery development platform and FPGA isomery development platform.
AMD isomery development platform host side CPU is AMD Ryzen 52500U with Radeon Vega Mobile
Gfx, 2.00GHz, memory 8G, 64 WINDOWS10 systems, software use Microsoft Visual Studio2013, programming
Language is OpenCL, and Software Development Kit is AMD APP SDK, OpenCL hardware device end: AMD RadeonTMVega
8Mobile Graphics。
FPGA isomery development platform host side CPU is Core (TM) i7-7700,3.60GHz, memory 16G, 64 Centos
System, programming language OpenCL, Software Development Kit are Altera OpenCL SDK, OpenCL hardware device end:
Intel Arria 10GX FPGA。
2. emulation experiment content and its simulation experiment result analysis:
With the present invention is based on FPGA isomery development platform and it is existing based on AMD isomery development platform realize parallel quantum into
The method of change respectively carries out very Multidimensional Knapsack Problems, as a result such as Fig. 5.
Wherein, Fig. 5 (a) is to adopt the simulation result diagram being obtained by the present invention, and Fig. 5 (b) is to use existing method
Obtained simulation result diagram, Fig. 5 (c) are the time comparison diagram of two methods.Comparison diagram 5 (a) and Fig. 5 (b) are it is found that of the invention
Method can similarly find optimal solution, meanwhile, from Fig. 5 (c) as can be seen that method timeliness of the invention is higher than existing side
Method.
The two methods solution time used is compared, the results are shown in Table 4.
4 present invention of table and existing method emulation experiment 20 times experiments time contrast table used
Experiment number | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 |
Existing method | 4.106 | 4.211 | 4.898 | 3.963 | 4.262 | 3.143 | 3.055 | 4.133 | 3.794 | 4.211 |
The present invention | 1.34 | 0.81 | 1.23 | 1.36 | 0.98 | 1.12 | 0.99 | 1.66 | 2.7 | 1.25 |
Experiment number | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 |
Existing method | 4.775 | 3.609 | 3.409 | 4.622 | 4.703 | 4.612 | 4.032 | 4.105 | 4.433 | 5.213 |
The present invention | 1.33 | 0.89 | 1.04 | 2.44 | 1.64 | 2.26 | 1.25 | 1.29 | 1.11 | 1.00 |
As table 4 as it can be seen that the time used in method of the invention is considerably less than the existing method institute based on AMD isomery development platform
Time.
Claims (6)
1. a kind of Parallel Quantum Evolutionary implementation method based on FPGA, which is characterized in that matched using open operation language OpenCL
High-performance hardware equipment FPGA is set, using the multi-threading parallel process data of high-performance hardware equipment FPGA, realizes parallel quantum
It evolves, step includes the following:
(1) value and limitation data of article are read in, and is stored in the matrix form;
(2) init state matrix uses state matrixIndicate the quantum state of solution, wherein m is article
Number, t indicates in t for the probability amplitude that α and β are that gene position takes 0 and 1 respectively;As t=0,
(3) using FPGA as the equipment end of open operation language OpenCL, and equipment end working group is divided, creates two kernels,
Wherein first kernel Parallel Implementation quantum observation, second kernel update state matrix parallel;
(4) it is observed by parallel quantum, obtains chromosome coding string:
(4a) generates random number in (0,1) range in central processor CPU host side, and by the β value one of itself and state matrix
In global memory with incoming open operation language OpenCL equipment end;
(4b) executes first kernel, i.e. amount of the Parallel Implementation to state matrix in open operation language OpenCL equipment end
Son observation, obtains the chromosome coding string after state matrix is repeatedly observed, then be copied to central processor CPU host end memory
In;
(5) chromosome is corrected:
(5a) limits data according to chromosome coding string, article, judges whether to meet constraint condition:
If meeting constraint condition executes (5b), otherwise, execute (5c),
Wherein X=(x1…xm), xi=0 or 1 indicates the state of i-th article, and w indicates the limitation of article, CjFor the constraint of jth dimension
Condition.
(5b) corrects chromosome according to the Item Value that state is " 0 " and limitation ratio, until it is unsatisfactory for constraint condition, further according to
The fitness value E of revised chromosome and Item Value data calculating target function, is currently solved, and judges that current solution is
No is optimal solution, if so, otherwise the current solution of output executes (6);
(5c) corrects chromosome according to the value that state is " 1 " and limitation ratio, until meeting constraint condition, after amendment
Chromosome and Item Value data calculating target function fitness value E, currently solved, and judge whether current solution is most
Excellent solution, if so, otherwise the current solution of output executes (6);
(6) state matrix is updated parallel:
(6a) transports current solution, the preceding optimal solution once obtained and incoming open of state matrix U in central processor CPU host side
In the global memory for calculating language OpenCL equipment end;
(6b) executes second kernel in open operation language OpenCL equipment, i.e., concurrently carries out to current state matrix
Update obtains new state matrix, and is copied in the memory of central processor CPU host side;
(7) step (4)-(6) are repeated, terminate to evolve until finding globally optimal solution or reaching maximum number of iterations.
2. the method according to claim 1, wherein Parallel Implementation sees the quantum of state matrix in step (4b)
It surveys, is that the parallel random number by generation and the β value of state matrix in open operation language OpenCL equipment end memory compare
Compared with if random number is greater than β value, gene position state is collapsed in 1, and otherwise, gene position state is collapsed in 0, finally obtains coded strings.
3. the method according to claim 1, wherein fitness value E is calculated in step (5b) and (5c), by such as
Lower formula calculates:
Wherein, X=(x1…xm), P=(p1…pm),xi=0 or 1 indicates the state of i-th article, piIt is the valence of corresponding article
Value.
4. the method according to claim 1, wherein according to the Item Value and limitation that state is " 0 " in (5b)
Than correcting chromosome, realizing that steps are as follows:
(5b1) calculates the cost performance for i-th of article that state in j dimension is " 0 ":And by acquired results
C is arranged in descending order, wherein v is the value of article, and w is the limitation of article, and n is number of dimensions;
(5b2) is begun stepping through from the highest article of cost performance in order of sequence, if the state for having article is " 0 ", is set as " 1 ",
If the state of article is " 1 ", original state is kept.
5. the method according to claim 1, wherein according to the Item Value and limitation that state is " 1 " in (5c)
Than correcting chromosome, realizing that steps are as follows:
(5c1) calculates i-th of article cost performance that state in j dimension is " 1 ":And by acquired results c
It arranges in descending order, wherein v is the value of article, and w is the limitation of article, and n is number of dimensions;
(5c2) is begun stepping through according to sequence order from the minimum article of cost performance, if the state of article is " 1 ", is set as " 0 ",
If the state of article is " 0 ", original state is kept.
6. method according to claim 1, which is characterized in that the parallel update state matrix in step (6b), is by simultaneously
For row Quantum rotating gate come what is be updated, Quantum rotating gate formula is as follows:
Quantum gene position in updated state matrix are as follows:
Wherein θi=s (αiβi)*Δθi, i=1 ..., m are each quantum gene positions towards 0 or 1 rotation angle, s (αiβi)
It is direction of rotation, Δ θiIt is angle step.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910305526.3A CN109993310B (en) | 2019-04-16 | 2019-04-16 | Parallel quantum evolution implementation method based on FPGA |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910305526.3A CN109993310B (en) | 2019-04-16 | 2019-04-16 | Parallel quantum evolution implementation method based on FPGA |
Publications (2)
Publication Number | Publication Date |
---|---|
CN109993310A true CN109993310A (en) | 2019-07-09 |
CN109993310B CN109993310B (en) | 2023-03-24 |
Family
ID=67133844
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910305526.3A Active CN109993310B (en) | 2019-04-16 | 2019-04-16 | Parallel quantum evolution implementation method based on FPGA |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109993310B (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112446432A (en) * | 2020-11-30 | 2021-03-05 | 西安电子科技大学 | Handwritten picture classification method based on quantum self-learning self-training network |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102866912A (en) * | 2012-10-16 | 2013-01-09 | 首都师范大学 | Single-instruction-set heterogeneous multi-core system static task scheduling method |
CN107330808A (en) * | 2017-07-21 | 2017-11-07 | 山东万腾电子科技有限公司 | Complex scene scheduling method and system based on quantum evolutionary algorithm |
WO2018161468A1 (en) * | 2017-03-10 | 2018-09-13 | 东莞理工学院 | Global optimization, searching and machine learning method based on lamarck acquired genetic principle |
-
2019
- 2019-04-16 CN CN201910305526.3A patent/CN109993310B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102866912A (en) * | 2012-10-16 | 2013-01-09 | 首都师范大学 | Single-instruction-set heterogeneous multi-core system static task scheduling method |
WO2018161468A1 (en) * | 2017-03-10 | 2018-09-13 | 东莞理工学院 | Global optimization, searching and machine learning method based on lamarck acquired genetic principle |
CN107330808A (en) * | 2017-07-21 | 2017-11-07 | 山东万腾电子科技有限公司 | Complex scene scheduling method and system based on quantum evolutionary algorithm |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112446432A (en) * | 2020-11-30 | 2021-03-05 | 西安电子科技大学 | Handwritten picture classification method based on quantum self-learning self-training network |
CN112446432B (en) * | 2020-11-30 | 2023-06-30 | 西安电子科技大学 | Handwriting picture classification method based on quantum self-learning self-training network |
Also Published As
Publication number | Publication date |
---|---|
CN109993310B (en) | 2023-03-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Mikami et al. | Massively distributed SGD: ImageNet/ResNet-50 training in a flash | |
Jin et al. | MRPGA: an extension of MapReduce for parallelizing genetic algorithms | |
Cheatham et al. | Bulk synchronous parallel computing—a paradigm for transportable software | |
De Toro et al. | PSFGA: a parallel genetic algorithm for multiobjective optimization | |
CN104699461A (en) | Configuring thread scheduling on a multi-threaded data processing apparatus | |
CN106294288B (en) | A kind of distribution non-negative matrix factorization method | |
CN109978171B (en) | Grover quantum simulation algorithm optimization method based on cloud computing | |
US9626624B2 (en) | Programmable probability processing | |
Behrens et al. | Efficient SIMD Vectorization for Hashing in OpenCL. | |
Campos et al. | Scaling a convolutional neural network for classification of adjective noun pairs with tensorflow on gpu clusters | |
CN108595379A (en) | A kind of parallelization convolution algorithm method and system based on multi-level buffer | |
Jia et al. | GPU implementation of the linear scaling three dimensional fragment method for large scale electronic structure calculations | |
CN109993310A (en) | Parallel Quantum Evolutionary implementation method based on FPGA | |
Schäfer et al. | Libgeodecomp: A grid-enabled library for geometric decomposition codes | |
Barrachina et al. | A flexible research-oriented framework for distributed training of deep neural networks | |
Shadravan et al. | A distributed sailfish optimizer based on multi-agent systems for solving non-convex and scalable optimization problems implemented on GPU | |
CN107545323A (en) | Logistics Distribution Method, device, equipment and the storage medium of commodity | |
Taka et al. | MaxEVA: Maximizing the Efficiency of Matrix Multiplication on Versal AI Engine | |
Zhou et al. | A Parallel Scheme for Large‐scale Polygon Rasterization on CUDA‐enabled GPUs | |
Bolanos et al. | Mapping and Scheduling in Heterogeneous NoC through Population-Based Incremental Learning. | |
Crary et al. | Using fpga devices to accelerate tree-based genetic programming: A preliminary exploration with recent technologies | |
Topa | Cellular automata model tuned for efficient computation on GPU with global memory cache | |
Pecero et al. | A new genetic algorithm for scheduling for large communication delays | |
Mu et al. | An efficient approach based on the gradient definition for solving conditional nonlinear optimal perturbation | |
CN117407177B (en) | Task execution method, device, electronic equipment and readable storage medium |
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 |