CN104657553B - A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method - Google Patents

A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method Download PDF

Info

Publication number
CN104657553B
CN104657553B CN201510070071.3A CN201510070071A CN104657553B CN 104657553 B CN104657553 B CN 104657553B CN 201510070071 A CN201510070071 A CN 201510070071A CN 104657553 B CN104657553 B CN 104657553B
Authority
CN
China
Prior art keywords
mrow
time
real
prototype drawing
munderover
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
CN201510070071.3A
Other languages
Chinese (zh)
Other versions
CN104657553A (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 Academy of Launch Vehicle Technology CALT
Beijing Aerospace Automatic Control Research Institute
Original Assignee
China Academy of Launch Vehicle Technology CALT
Beijing Aerospace Automatic Control Research 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 Academy of Launch Vehicle Technology CALT, Beijing Aerospace Automatic Control Research Institute filed Critical China Academy of Launch Vehicle Technology CALT
Priority to CN201510070071.3A priority Critical patent/CN104657553B/en
Publication of CN104657553A publication Critical patent/CN104657553A/en
Application granted granted Critical
Publication of CN104657553B publication Critical patent/CN104657553B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method, initially set up the mathematical modeling of coefficient correlation between figure and Prototype drawing in real time;Then the design of hardware algorithm is carried out using two layers of streamline, and the coefficient correlation between search window selected real-time figure and Prototype drawing is calculated using finite state machine method;After the completion of coefficient correlation between the real-time figure and Prototype drawing that all search windows are selected calculates, find out the abscissa and ordinate of maximum and the corresponding search window upper left corner in real-time figure coordinate system in coefficient correlation, selection area corresponding to the search window is matching area, rationally control hardware resource cost of the invention, meet the requirement for reaching 100M under Xilinx Virtex5 XC5VFX100T, to size it is 80*64 real-time figure and Prototype drawing that size is 25*25 carries out similitude matching operation and only needs 3.5ms, greatly improves algorithm speed.

Description

A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method
Technical field
The present invention relates to a kind of hardware-accelerated method, particularly a kind of similitude based on quick normalized crosscorrelation method is surveyed Hardware-accelerated method is spent, suitable for tailor-made algorithm hardware circuit design field.
Background technology
Have begun to widely apply in space flight model of new generation based on the information processing technology of images match, image procossing Real-time directly affect guidance precision.Image processing algorithm was realized using software based on general processor (such as DSP) in the past It is increasingly difficult to meet the requirement of real-time of space flight model.At present, through coming frequently with the mode for simplifying algorithm sacrifice arithmetic accuracy Reduce algorithm operation time.Realize that algorithm acceleration is to reduce the most effective means of algorithm operation time by hardware algorithm.
Image procossing is using the matching process based on half-tone information, the high still computing of this method matching precision at present Measure bigger.Image matching algorithm based on similarity measure is that wherein amount of calculation is maximum, takes most long algorithm.Similarity measurements Amount criterion is to calculate the criterion of similarity degree between To Template figure and real-time figure.In numerous similitude judging basis, normalizing It is considered as optimal to change cross-correlation method (NCC).It has matching accuracy height, and anti-ambient noise ability is strong, pattern distortion is fitted (when image is little around the distortion difference caused by central point rotation, relative scaling, its matching result can also make us Ying Xingqiang It is satisfied) etc. characteristic.Based on above feature, normalized crosscorrelation method has obtained extensively and effectively applying in matching problem.But It is that normalized crosscorrelation method computational complexity is higher, calculating time consumption is longer, for the higher matching application of requirement of real-time There is certain limitation.The image matching algorithm of similarity measure now based on normalized crosscorrelation method uses High Performance DSP more To realize.But the increase of the increase operand with picture size, this scheme is difficult to meet the requirement of real-time of space flight model.For Meet real-time, or even by the way of arithmetic accuracy is sacrificed, the similarity measure algorithm based on normalized crosscorrelation method it is hard Part accelerates extremely urgent.
The content of the invention
The technology of the present invention solves problem:Overcome the deficiencies in the prior art, there is provided one kind is based on normalized crosscorrelation The hardware-accelerated method of similarity measure of method, by Optimal improvements coefficient correlation algorithmic formula, used two layers in hardware calculating The pipeline design, hardware resource cost rationally being controlled, adoption status machine enters the calculating of Correlation series, and in Xilinx Meet the requirement for reaching 100M under virtex5-XC5VFX100T, greatly improve algorithm speed, meet to the full extent The demand of tailor-made algorithm hardware circuit design.
The present invention technical solution be:A kind of similarity measure based on quick normalized crosscorrelation method is hardware-accelerated Method, step are as follows:
(1) mathematical modeling of coefficient correlation between figure and Prototype drawing in real time is established;The mathematical modeling is by formula:
Provide, ρ (p, q) is the coefficient correlation between the real-time figure and Prototype drawing that search window is selected;P and q is respectively to search Abscissa and ordinate of the rope window upper left corner in real-time figure coordinate system, T (x, y) are the figure of coordinate points (x, y) in Prototype drawing As gray value, S (x+p, y+q) is the image intensity value of corresponding points in real-time figure, and the coordinate points (x, y) are located at Prototype drawing coordinate In system,Represent that search window in real-time figure covers the gray average in subgraph region,The gray average of Prototype drawing is represented, M is Prototype drawing width, and n is Prototype drawing height, and the search window is the rectangular window with Prototype drawing size, shape all same, The origin of coordinates of the figure coordinate system in real time is the upper left corner of real-time figure, and the upper left corner is real-time figure coordinate system X-axis positive direction to the right, The upper left corner is real-time figure coordinate system Y-axis positive direction downwards, and the origin of coordinates of the Prototype drawing coordinate system is the upper left corner of Prototype drawing, The upper left corner is Prototype drawing coordinate system X-axis positive direction to the right, and the upper left corner is Prototype drawing coordinate system Y-axis positive direction downwards;
(2) figure and Prototype drawing in real time are read from memory using hardware, according to the mathematical modeling in step (1), difference Try to achieve in mathematical modeling With
(3) after the completion of the calculating in step (2), into step (4), using in mathematical modeling and step (2) in step (1) Result calculate coefficient correlation between search window selected real-time figure and Prototype drawing;Meanwhile using hardware from memory Read next width figure and Prototype drawing in real time, return to step (2);
(4) coefficient correlation between search window selected real-time figure and Prototype drawing is calculated using finite state machine method;
(5) after the completion of the coefficient correlation between all search windows selected real-time figure and Prototype drawing calculates, correlation is found out The abscissa and ordinate of maximum and the corresponding search window upper left corner in real-time figure coordinate system in coefficient, the search window Corresponding selection area is target area.
Hardware in the step (2) is FPGA or ASIC.
Calculated in the step (4) using finite state machine method between search window selected real-time figure and Prototype drawing Coefficient correlation, it is specially:
The hardware includes two dividers and two square root extractors, and the state machine includes 6 states, respectively sta0 ~sta5, under each state the concrete operations of hardware be:
sta0:Result of calculation in backup-step (2), if first time coefficient correlation computing, prepare Prototype drawing two and remove MethodWithDivisor and dividend, and open two dividers enable, calculate Square of figure summation in real timeAnd real-time figure quadratic sum and m*n productSta1 is gone to, if not first time coefficient correlation, calculates the flat of figure summation in real time Side and in real time figure quadratic sum and m*n product, go to sta2;
sta1:CalculateData are preserved after the completion of calculating and are redirected To sta2;
sta2:Intermediate variable is calculated by the result in sta1And determine that coefficient correlation is transported Evolution number in calculation, jumps to sta3;
sta3:Molecule in coefficient correlation mathematical modeling is calculated by the intermediate variable in sta2;According to what is determined in sta2 Coefficient correlation computing evolution number, if first time coefficient correlation computing, then open Prototype drawing and real-time figure extracting operation enables, enter Row Prototype drawing and real-time figure extracting operation;If not first time coefficient correlation computing, then open real-time figure extracting operation and enable, enter The real-time figure extracting operation of row;Jump to sta4;
sta4:After real-time figure extracting operation terminates, figure in real time and the product of Prototype drawing evolution result are calculated;Open divider It is enabled;Jump to sta5;
sta5:Carry out division calculation and obtain coefficient correlation, division arithmetic jumps to sta0 after terminating, and it is real-time to carry out next width Figure coefficient correlation computing.
State in the state machine uses gray encoding, and specific corresponding relation is:Sta0~000, sta1~001, Sta2~010, sta3~011, sta4~111, sta5~110.
Compared with the prior art, the invention has the advantages that:
(1) present invention carries out Hardware deformation to quick normalized crosscorrelation method formula, it is more suitable for Hardware realization, Formula after change need not read after view data calculates average value and again read off view data, reduce computing;And will be real When figure separated with Prototype drawing computing, in whole coefficient correlation calculating process Prototype drawing only need calculating once, using prime formula Need first to calculate image averaging value, carrying out likeness coefficient calculating, it is necessary to be read twice to view data;
(2) present invention uses two layers of the pipeline design, operation efficiency is substantially increased by parallel computation, using optimization Divider and square root extractor, reduce cycle and hardware algorithm resource needed for likeness coefficient computing, and by using support non-alignment The high-order wide memory of access, reduce the image reading time, reduce algorithm operation time;
(3) the multiplexing computing of divider, square root extractor is controlled present invention employs finite state machine, it is public to complete coefficient correlation The calculating of formula, rationally make use of hardware resource, improve the efficiency of computing;
(4) be currently based on the image matching algorithm of the similarity measure of normalized crosscorrelation method more using High Performance DSP come Realize, the present invention realizes the Hardware Design of the algorithm, realizes available for FPGA or ASIC, is carried significantly relative to DSP operation The high processing speed and efficiency of the algorithm.
Brief description of the drawings
Fig. 1 is the flow chart of the present invention;
Fig. 2 is that Prototype drawing matches schematic diagram with figure in real time;
Fig. 3 is that single match accumulates arithmetic pipelining schematic diagram;
Fig. 4 is two layers of flowing water line computation schematic diagram of coefficient correlation;
Fig. 5 is similarity measure state machine control schematic diagram.
Embodiment
The content not being described in detail in description of the invention belongs to the known technology of professional and technical personnel in the field.Below The embodiment of the present invention is further described in detail with reference to accompanying drawing.
Similarity measurement refers to a kind of specific metric form to determine the similitude between feature to be matched, what it was obtained Similitude is the crucial foundation of images match, directly determines whether image can correctly be matched.
It is as shown in Figure 1 the flow chart of the present invention, from fig. 1, it can be seen that one kind proposed by the present invention is based on normalized crosscorrelation The hardware-accelerated method of similarity measure of method, is comprised the following steps that:
(1) mathematical modeling of coefficient correlation between figure and Prototype drawing in real time is established;
Similarity measure algorithm based on normalized crosscorrelation method is a kind of classical statistical match algorithm of comparison, and its is main Calculating process is as follows:As shown in Fig. 2 figure S size is M × N in real time, Prototype drawing T size is m × n.Yellow region in real-time figure Domain representation Prototype drawing T on figure S when translating in real time, subgraph region that search window is covered.Push up in (p, q) subgraph region upper left corner Coordinate position of the point in figure S in real time, it is related to the normalization of Prototype drawing that subgraph is then calculated by correlation function (formula 1) Value.Images match from left to right, carries out traversal search, then calculates all subgraph position correspondences from up to down to figure S in real time Coefficient correlation, (M-m+1) * (N-n+1) secondary matching primitives, obtain the individual matching factor results of (M-m+1) * (N-n+1) altogether.Based on returning The best match position that the similarity measure algorithm of one change cross-correlation method is calculated is the maximum search of its coefficient correlation Position corresponding to subgraph.
ρ (p, q) is the coefficient correlation between the real-time figure and Prototype drawing that search window is selected in formula 1;P and q are respectively Abscissa and ordinate of the search window upper left corner in real-time figure coordinate system, T (x, y) are coordinate points (x, y) in Prototype drawing Image intensity value, S (x+p, y+q) are the image intensity value of corresponding points in real-time figure, and the coordinate points (x, y) are located at Prototype drawing seat In mark system,Represent that search window in real-time figure covers the gray average in subgraph region,Represent that the gray scale of Prototype drawing is equal Value, m are Prototype drawing width, and n is Prototype drawing height, and the search window is the rectangular window with Prototype drawing size, shape all same Mouthful, the origin of coordinates of the figure coordinate system in real time is the upper left corner of real-time figure, and the upper left corner is square for real-time figure coordinate system X-axis to the right To the upper left corner is real-time figure coordinate system Y-axis positive direction downwards, and the origin of coordinates of the Prototype drawing coordinate system is the upper left of Prototype drawing Angle, the upper left corner are Prototype drawing coordinate system X-axis positive direction to the right, and the upper left corner is Prototype drawing coordinate system Y-axis positive direction downwards;
Abbreviation can obtain after formula mathematics is deployed:
In hardware operation, divide operations much multiply than plus-minus operates more time-consuming, expense resource, therefore reduces divide operations as far as possible Number can improve arithmetic speed.During each similitude matching primitives, template diagram data is constant.Therefore divide operations are tried one's best Go on masterplate figure, such division need to only calculate once.Therefore formula is convertible as shown in formula (3), only needs calculation template figure Summation and the average value of Prototype drawing quadratic sum, no longer calculate real-time figure sum average value.
Extracting operation generally requires multiple cycles, and the extracting operation time is directly proportional to square root extractor bit wide.Formula denominator is entered Row Prototype drawing and figure separates in real time, such Prototype drawing part evolution need to only calculate once, behind constant can be used as to participate in computing, open Square device bit wide can greatly reduce, and shorten the extracting operation time.Final application fortran is as follows:
(2) figure and Prototype drawing in real time are read from memory using hardware, according to the mathematical modeling in step (1), difference Try to achieve in mathematical modeling WithThe hardware is FPGA or ASIC, and Xilinx is selected in the present embodiment virtex5-XC5VFX100T。
Calculate these accumulation data using take location calculatings, digital independent, accumulation calculate three class pipeline design.Prototype drawing and Figure reads m*n gray scale respectively in real time, is designed by memory optimization, once reads multiple gray scales, can reduced single match and tire out Product operation time.The present invention once reads 4 gray scales, accumulates computing by optimizing, single match cumulative operational time can be reduced To a quarter before.Single match accumulation arithmetic pipelining schematic diagram is specifically as shown in Figure 3;
(3) after the completion of the calculating in step (2), into step (4), using in mathematical modeling and step (2) in step (1) Result calculate coefficient correlation between search window selected real-time figure and Prototype drawing;Meanwhile using hardware from memory Next width figure and Prototype drawing in real time are read, return to step (2), two layers of flowing water line computation schematic diagram of coefficient correlation is specifically such as Fig. 4 institutes Show;
Single match obtains after coefficient correlation calculates the average value needed, summation, quadratic sum, the accumulated value such as sum of products, pressing Start to calculate coefficient correlation according to formula (4), at the same time, carry out next matching figure accumulation computing.Because view data is larger, one As single match be accumulated as the critical path of streamline.Designed by memory optimization, reduce single match cumulative operational time, And in the case of view data is little, the coefficient correlation calculating time can exceed that single match cumulative operational time, turn into flowing water The critical path of line.
(4) coefficient correlation between search window selected real-time figure and Prototype drawing is calculated using finite state machine method; The state conversion process is specific as shown in figure 5, as can be seen from Figure 5, the finite state machine method in the present invention is specially:
The hardware includes two dividers and two square root extractors, and the state machine includes 6 states, respectively sta0 ~sta5, under each state the concrete operations of hardware be:
sta0:Result of calculation in backup-step (2), if first time coefficient correlation computing, prepare Prototype drawing two and remove MethodWithDivisor and dividend, and open two dividers and enable, calculate real When figure summation squareAnd real-time figure quadratic sum and m*n productSta1 is gone to, if not first time coefficient correlation, calculates the flat of figure summation in real time Side and in real time figure quadratic sum and m*n product, go to sta2;
sta1:CalculateData are preserved after the completion of calculating and are redirected To sta2;
sta2:Intermediate variable is calculated by the result in sta1And determine that coefficient correlation is transported Evolution number in calculation, jumps to sta3;
sta3:Molecule in coefficient correlation mathematical modeling is calculated by the intermediate variable in sta2;According to what is determined in sta2 Coefficient correlation computing evolution number, if first time coefficient correlation computing, then open Prototype drawing and real-time figure extracting operation enables, enter Row Prototype drawing and real-time figure extracting operation;If not first time coefficient correlation computing, then open real-time figure extracting operation and enable, enter The real-time figure extracting operation of row;Jump to sta4;
sta4:After real-time figure extracting operation terminates, figure in real time and the product of Prototype drawing evolution result are calculated;Open divider It is enabled;Jump to sta5;
sta5:Carry out division calculation and obtain coefficient correlation, division arithmetic jumps to sta0 after terminating, and it is real-time to carry out next width Figure coefficient correlation computing.
State in the state machine uses gray encoding, and specific corresponding relation is:Sta0~000, sta1~001, Sta2~010, sta3~011, sta4~111, sta5~110.
(5) after the completion of the coefficient correlation between all search windows selected real-time figure and Prototype drawing calculates, correlation is found out The abscissa and ordinate of maximum and the corresponding search window upper left corner in real-time figure coordinate system in coefficient, the search window Corresponding selection area is target area.
Present invention FPGA under Xilinx virtex5-XC5VFX100T is realized, meets the requirement for reaching 100M.To size The Prototype drawing that real-time figure and size for 80*64 are 25*25, which carries out similitude matching operation, only needs 3.5ms, relative in TI The speed of service improves two orders of magnitude in C6416 series DSPs.

Claims (4)

  1. A kind of 1. hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method, it is characterised in that step is as follows:
    (1) mathematical modeling of coefficient correlation between figure and Prototype drawing in real time is established;The mathematical modeling is by formula:
    <mrow> <mi>&amp;rho;</mi> <mrow> <mo>(</mo> <mi>p</mi> <mo>,</mo> <mi>q</mi> <mo>)</mo> </mrow> <mo>=</mo> <mfrac> <mrow> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>m</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>n</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msub> <mi>S</mi> <mrow> <mi>p</mi> <mo>,</mo> <mi>q</mi> </mrow> </msub> <mrow> <mo>(</mo> <mi>x</mi> <mo>+</mo> <mi>p</mi> <mo>,</mo> <mi>y</mi> <mo>+</mo> <mi>q</mi> <mo>)</mo> </mrow> <mo>&amp;CenterDot;</mo> <mi>T</mi> <mrow> <mo>(</mo> <mi>x</mi> <mo>,</mo> <mi>y</mi> <mo>)</mo> </mrow> <mo>-</mo> <mover> <mi>T</mi> <mo>&amp;OverBar;</mo> </mover> <mo>&amp;CenterDot;</mo> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>m</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>n</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msub> <mi>S</mi> <mrow> <mi>p</mi> <mo>,</mo> <mi>q</mi> </mrow> </msub> <mrow> <mo>(</mo> <mi>x</mi> <mo>+</mo> <mi>p</mi> <mo>,</mo> <mi>y</mi> <mo>+</mo> <mi>q</mi> <mo>)</mo> </mrow> </mrow> <mrow> <msqrt> <mrow> <mo>(</mo> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>m</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>n</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msub> <mi>S</mi> <mrow> <mi>p</mi> <mo>,</mo> <mi>q</mi> </mrow> </msub> <msup> <mrow> <mo>(</mo> <mrow> <mi>x</mi> <mo>+</mo> <mi>p</mi> <mo>,</mo> <mi>y</mi> <mo>+</mo> <mi>q</mi> </mrow> <mo>)</mo> </mrow> <mn>2</mn> </msup> <mo>)</mo> <mo>&amp;CenterDot;</mo> <mi>m</mi> <mo>&amp;CenterDot;</mo> <mi>n</mi> <mo>-</mo> <msup> <mrow> <mo>(</mo> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>m</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>n</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <msub> <mi>S</mi> <mrow> <mi>p</mi> <mo>,</mo> <mi>q</mi> </mrow> </msub> <mo>(</mo> <mrow> <mi>x</mi> <mo>+</mo> <mi>p</mi> <mo>,</mo> <mi>y</mi> <mo>+</mo> <mi>q</mi> </mrow> <mo>)</mo> <mo>)</mo> </mrow> <mn>2</mn> </msup> </mrow> </msqrt> <mo>&amp;CenterDot;</mo> <msqrt> <mrow> <mfrac> <mrow> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>x</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>m</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <munderover> <mi>&amp;Sigma;</mi> <mrow> <mi>y</mi> <mo>=</mo> <mn>0</mn> </mrow> <mrow> <mi>n</mi> <mo>-</mo> <mn>1</mn> </mrow> </munderover> <mi>T</mi> <msup> <mrow> <mo>(</mo> <mi>x</mi> <mo>,</mo> <mi>y</mi> <mo>)</mo> </mrow> <mn>2</mn> </msup> </mrow> <mrow> <mi>m</mi> <mo>&amp;CenterDot;</mo> <mi>n</mi> </mrow> </mfrac> <mo>-</mo> <msup> <mover> <mi>T</mi> <mo>&amp;OverBar;</mo> </mover> <mn>2</mn> </msup> </mrow> </msqrt> </mrow> </mfrac> </mrow>
    Provide, ρ (p, q) is the coefficient correlation between the real-time figure and Prototype drawing that search window is selected;P and q is respectively search window Abscissa and ordinate of the mouth upper left corner in real-time figure coordinate system, T (x, y) are the image ash of coordinate points (x, y) in Prototype drawing Angle value, S (x+p, y+q) are the image intensity value of corresponding points in real-time figure, and the coordinate points (x, y) are located at Prototype drawing coordinate system In,The gray average of Prototype drawing is represented, m is Prototype drawing width, and n is Prototype drawing height, and the search window is big with Prototype drawing Small, shape all same rectangular window, the origin of coordinates of the figure coordinate system in real time is the upper left corner of real-time figure, and the upper left corner is to the right For real-time figure coordinate system X-axis positive direction, the upper left corner is real-time figure coordinate system Y-axis positive direction downwards, the Prototype drawing coordinate system The origin of coordinates is the upper left corner of Prototype drawing, and the upper left corner is Prototype drawing coordinate system X-axis positive direction to the right, and the upper left corner is Prototype drawing downwards Coordinate system Y-axis positive direction;
    (2) figure and Prototype drawing in real time are read from memory using hardware, according to the mathematical modeling in step (1), tried to achieve respectively In mathematical modeling With
    (3) after the completion of the calculating in step (2), into step (4), the knot in mathematical modeling and step (2) in step (1) is utilized Fruit calculates the coefficient correlation between search window selected real-time figure and Prototype drawing;Meanwhile read using hardware from memory Next width is schemed in real time and Prototype drawing, return to step (2);
    (4) coefficient correlation between search window selected real-time figure and Prototype drawing is calculated using finite state machine method;
    (5) after the completion of the coefficient correlation between all search windows selected real-time figure and Prototype drawing calculates, coefficient correlation is found out In abscissa and ordinate in real-time figure coordinate system of maximum and the corresponding search window upper left corner, the search window is corresponding Selection area be target area.
  2. 2. according to a kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method in claim 1, its It is characterised by:Hardware in the step (2) is FPGA or ASIC.
  3. 3. according to a kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method in claim 1, its It is characterised by:Calculated in the step (4) using finite state machine method between search window selected real-time figure and Prototype drawing Coefficient correlation, be specially:
    The hardware includes two dividers and two square root extractors, and the state machine includes 6 states, and respectively sta0~ Sta5, under each state the concrete operations of hardware be:
    sta0:Result of calculation in backup-step (2), if first time coefficient correlation computing, prepare two divisions of Prototype drawingWithDivisor and dividend, and open two dividers and enable, calculate real-time Scheme square of summationAnd real-time figure quadratic sum and m*n productSta1 is gone to, if not first time coefficient correlation, calculates the flat of figure summation in real time Side and in real time figure quadratic sum and m*n product, go to sta2;
    sta1:CalculateData are preserved after the completion of calculating and are jumped to sta2;
    sta2:Intermediate variable is calculated by the result in sta1And determine in coefficient correlation computing Evolution number, jump to sta3;
    sta3:Molecule in coefficient correlation mathematical modeling is calculated by the intermediate variable in sta2;According to the correlation determined in sta2 Coefficient computing evolution number, if first time coefficient correlation computing, then open Prototype drawing and real-time figure extracting operation enables, carry out mould Plate figure and real-time figure extracting operation;If not first time coefficient correlation computing, then open real-time figure extracting operation and enable, carry out real When figure extracting operation;Jump to sta4;
    sta4:After real-time figure extracting operation terminates, figure in real time and the product of Prototype drawing evolution result are calculated;Opening divider makes Energy;Jump to sta5;
    sta5:Carry out division calculation and obtain coefficient correlation, division arithmetic jumps to sta0 after terminating, and carries out the real-time figure phase of next width Relation number computing.
  4. 4. according to a kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method in claim 3, its It is characterised by:State in the state machine uses gray encoding, and specific corresponding relation is:Sta0~000, sta1~001, Sta2~010, sta3~011, sta4~111, sta5~110.
CN201510070071.3A 2015-02-10 2015-02-10 A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method Active CN104657553B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201510070071.3A CN104657553B (en) 2015-02-10 2015-02-10 A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201510070071.3A CN104657553B (en) 2015-02-10 2015-02-10 A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method

Publications (2)

Publication Number Publication Date
CN104657553A CN104657553A (en) 2015-05-27
CN104657553B true CN104657553B (en) 2018-03-09

Family

ID=53248673

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201510070071.3A Active CN104657553B (en) 2015-02-10 2015-02-10 A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method

Country Status (1)

Country Link
CN (1) CN104657553B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105426918B (en) * 2015-11-23 2019-01-08 南京航空航天大学 Normalize associated picture template matching efficient implementation method
CN107609576A (en) * 2017-08-23 2018-01-19 南京邮电大学 Merge the template matches Parallel Implementation method and device of large form figure
CN107886118A (en) * 2017-10-27 2018-04-06 北京中科慧眼科技有限公司 Binocular solid camera image Region Matching optimization method, equipment and storage medium

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101908230A (en) * 2010-07-23 2010-12-08 东南大学 Regional depth edge detection and binocular stereo matching-based three-dimensional reconstruction method
CN102750537A (en) * 2012-05-08 2012-10-24 中国矿业大学 Automatic registering method of high accuracy images
CN103076338A (en) * 2012-05-31 2013-05-01 西南交通大学 Rapid fuzzy matching method for testing bad conditions of high-speed rail catenary rod type insulators

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101908230A (en) * 2010-07-23 2010-12-08 东南大学 Regional depth edge detection and binocular stereo matching-based three-dimensional reconstruction method
CN102750537A (en) * 2012-05-08 2012-10-24 中国矿业大学 Automatic registering method of high accuracy images
CN103076338A (en) * 2012-05-31 2013-05-01 西南交通大学 Rapid fuzzy matching method for testing bad conditions of high-speed rail catenary rod type insulators

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
FPGA Based Parallel Architectures for Normalized Cross-Correlation;Xiaotao Wang 等;《The 1st International Conference on Information Science and Engineering》;20091231;第225-229页 *
图像匹配中NCC算法的一种快速实现方法;黄真宝 等;《信息化研究》;20110430;第37卷(第2期);第48-52页 *
快速归一化互相关算法及DSP优化实现;吴强 等;《电子测量与仪器学报》;20110630;第25卷(第6期);第495-499页 *

Also Published As

Publication number Publication date
CN104657553A (en) 2015-05-27

Similar Documents

Publication Publication Date Title
US11334744B2 (en) Three-dimensional point cloud label learning device, three-dimensional point cloud label estimating device, three-dimensional point cloud label learning method, three-dimensional point cloud label estimating method, and program
CN102324047B (en) Hyper-spectral image ground object recognition method based on sparse kernel representation (SKR)
CN101299233B (en) Device and method for realizing moving object identification and track based on FPGA
CN104657553B (en) A kind of hardware-accelerated method of similarity measure based on quick normalized crosscorrelation method
CN109658515A (en) Point cloud gridding method, device, equipment and computer storage medium
CN107291419A (en) Floating-point multiplier and floating number multiplication for neural network processor
CN103729643A (en) Recognition and pose determination of 3d objects in multimodal scenes
CN104050675B (en) Feature point matching method based on triangle description
CN105981025A (en) Actually-measured marine environment data assimilation method based on sequence recursive filtering three-dimensional variation
Ttofis et al. Towards accurate hardware stereo correspondence: A real-time fpga implementation of a segmentation-based adaptive support weight algorithm
CN103971122B (en) Three-dimensional face based on depth image describes method
CN106886980A (en) A kind of enhanced method of point cloud density based on three-dimensional laser radar target identification
CN106067172A (en) A kind of underwater topography image based on suitability analysis slightly mates and mates, with essence, the method combined
CN109766752B (en) Target matching and positioning method and system based on deep learning and computer
CN106340010A (en) Corner detection method based on second-order contour difference
CN107301643A (en) Well-marked target detection method based on robust rarefaction representation Yu Laplce&#39;s regular terms
CN108335330A (en) A kind of collection of illustrative plates collaboration real time processing system
Bertolazzi et al. Point data reconstruction and smoothing using cubic splines and clusterization
Jorstad et al. A deformation and lighting insensitive metric for face recognition based on dense correspondences
CN105701800A (en) Multi-mode image matching method
WO2017129115A1 (en) Orientation-based subject-matching in images
CN102855624B (en) A kind of image partition method based on broad sense data fields and Ncut algorithm
CN107229935B (en) Binary description method of triangle features
CN100580705C (en) Method for registration of multispectral image based on small component and noise component
CN111325343B (en) Neural network determination, target detection and intelligent driving control method and device

Legal Events

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