CN107644402A - Quick flake antidote based on GPU - Google Patents

Quick flake antidote based on GPU Download PDF

Info

Publication number
CN107644402A
CN107644402A CN201710693674.8A CN201710693674A CN107644402A CN 107644402 A CN107644402 A CN 107644402A CN 201710693674 A CN201710693674 A CN 201710693674A CN 107644402 A CN107644402 A CN 107644402A
Authority
CN
China
Prior art keywords
video
coordinate
grid
flake
image
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.)
Pending
Application number
CN201710693674.8A
Other languages
Chinese (zh)
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.)
Tianjin University
Original Assignee
Tianjin University
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 Tianjin University filed Critical Tianjin University
Priority to CN201710693674.8A priority Critical patent/CN107644402A/en
Publication of CN107644402A publication Critical patent/CN107644402A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Processing (AREA)

Abstract

The present invention relates to field of video monitoring, to propose a kind of real-time flake video correction algorithm based on GPU, while ensureing to calculate performance, increases its real-time.The technical solution adopted by the present invention is the quick flake antidote based on GPU, to extract a number of image during whole video first, correct the acquisition of parameter;Coordinate diagram is demarcated according to fish eye images feature, asks for the ideal value and actual value of calibration point pixel, while generate coordinate map;Then, after coordinate map being used for each frame of flake video, undistorted video is obtained.Present invention is mainly applied to the occasions that manufacture of video monitoring product.

Description

Quick flake antidote based on GPU
Technical field
It is a kind of novel algorithm for being corrected in real time to flake video the present invention relates to field of video monitoring. Specifically related to one kind by GPU parallel processings, come the algorithm corrected in real time to flake video.
Background technology
Go deep into social and economic construction, the monitoring problem in city is also increasingly subject to pay attention to.In order to take into account simultaneously The real-time and cost of monitoring, fish eye camera are widely used.Fish eye lens have short focus, big visual field it is excellent Point.But the image of fish eye lens video camera shooting has very serious deformation.If to utilize these that there is gross distortion figure The projection information of picture is, it is necessary to be the perspective projection image for meeting people's visual custom by image flame detections of these deformations[1]
The amount of calculation of fish eye images correction is very big.For embedded device, because it is processed the limitation of device dominant frequency, Therefore, it is difficult to reach real-time performance requirement.But by parallel computing, the limitation of processor host frequency can be broken through, is realized High-performance calculation [2].But the video correction algorithm for being currently based upon CPU can not reach wanting for real-time correction flake video Ask.There is graphics processor (Graphic Processing Unit, GPU) large-scale parallel of concurrent thread more than one to handle up Architecture [3], and there is very strong flexibility, the application requirement of flake video correction can be met.
Because the correction parameter that each frame of flake video obtains is the same, therefore is extracted in the process of whole video first The middle a number of image of extraction, correct the acquisition of parameter.Coordinate diagram is demarcated according to fish eye images feature, asks for calibration point The ideal value and actual value of pixel, while generate coordinate map.Then, coordinate map is used for each frame of flake video Afterwards, you can obtain undistorted video.
Document [1] conducts a preliminary study to the basic theory and key technology of fish eye lens vision system, and proposes A kind of scheme of embedded fully-directional visual system platform and image processor hardware design.Document [4] calculates flake distortion Corresponding relation between image and correcting image pixel, it is proposed that a kind of flake border head based on spherical perspective projection constraint is rectified Correction method.Document [5] proposes a kind of flexible new calibration algorithm, determines camera distortion parameter by characteristic image, then calculate Go out corresponding relation.
The present invention proposes a kind of flake video correction algorithm based on GPU, for solving fish eye camera pattern distortion Problem.
[1] Feng is that good is based on fish-eye omni-directional visual and full-view stereo ball vision research [D] University Of Tianjin, 2012.
[2] design of the embedded flake video correction schemes of Wang Chen and realization [D] Southeast China University, 2015.
[3] GPU parallel computings and application study [D] Nanjing Aero-Space under the mutually literary high-performance calculations cloud environment of Lv University, 2015.
[4] a kind of flake border head antidote [J] computers based on spherical perspective projection constraint of Ying Xianghua, Hu Zhanyi Journal, 2003,25 (12):1792-1708
[5]Zhang Z.A Flexible New Technique for Camera Calibration[J].IEEE Transactions on Pattern Analysis&Machine Intelligence,2000,22(11):1330-1334。
The content of the invention
For overcome the deficiencies in the prior art, the present invention is directed to propose a kind of real-time flake video correction algorithm based on GPU, While ensureing to calculate performance, increase its real-time.The technical solution adopted by the present invention is the quick flake correction based on GPU Method, a number of image is extracted during whole video first, correct the acquisition of parameter;According to fish eye images Feature demarcates coordinate diagram, asks for the ideal value and actual value of calibration point pixel, while generate coordinate map;Then, coordinate After mapping table is used for each frame of flake video, undistorted video is obtained.
Specifically:
Step 1:A number of image is extracted from video, obtains correction parameter;
Step 2:Coordinate is demarcated according to feature of image:Coordinate diagram is demarcated centered on camera lens, the mark of coordinate is carried out to image It is fixed, by the evenly distributed round dot of square, the ideal value and actual value of calibration point pixel are asked for, generates coordinate map;
Step 3:Correct frame by frame, after the coordinate of central point and correction shape is obtained, flake video is realized using GPU The correction of each frame, so as to the video after entirely being corrected.
In an example of the present invention, step is as follows:
Step 1:A number of image is extracted from video:Input the chessboard trrellis diagram of distortion extracted from video and Tessellated size;
Step 2:1) correction parameter is obtained:Extract X-comers, 2) image of input is converted into gray-scale map, 3) find The adjacent square of grid, the grid of back generation is inputted, for each grid, all travel through all grids, calculate phase The distance of adjacent grid fixed point, and find the grid of minimum distance, the grid is denoted as be current grid adjacent square, warp Original adjacent o'clock after expansion is spent and has become two from one, substituted the two points with a point now, this point The common intersection of two grids before being exactly expansion, 4) check that whether horizontal grid is concordant, in every a line and each row All angle points, investigate whether the angle point is projected in the row or the first of the row is put on formed line segment, finally to ensure The correctness of gridiron pattern grid extraction, 5) sub-pix angle point is found out, for the grid finally extracted, find its sub-pix Accurate angle point, returns to these angle points, and 6) the continuous interative computation of Jacobian matrix is utilized, finally give translation matrix, spin matrix And rotating vector, distortion factor is obtained, that is, obtains the mapping relations of x coordinate and y-coordinate;
Step 3:Using GPU it is parallel coordinate transform, the image after being corrected are carried out to image;
Step 4:To each frame in the video that is obtained in step 1, corrected, you can the video after being corrected.
The features of the present invention and beneficial effect are:
It is an advantage of the invention that the real-time processing of video correction can be realized, the acquisition for correcting parameter is only carried out once, because This has no effect on the speed of whole algorithm.And the coordinate mapping of most critical, this algorithm have carried out GPU parallel processings, improved whole The processing speed of individual video.
As shown in Figure 2 and Figure 3.The algorithm has obvious rectification effect.Fig. 2 is the figure of fish eye camera acquisition before correction Picture, Fig. 3 are the image after correction.
Brief description of the drawings:
Fig. 1 algorithm flow charts.
Fish eye images before Fig. 2 corrections.
Image after Fig. 3 corrections.
Embodiment
Although fish-eye big visual field feature makes it be widely used in multiple fields.It is but non-due to its imaging model Linear property, the image that can make to obtain have very serious distortion.Although current existing scholar begins one's study, flake video rectifys Direct problem, but effective and real-time proposals are but or seldom.In terms of the correction algorithm of flake video, to ensure correction simultaneously Accuracy and real-time.It is an object of the invention to propose a kind of real-time flake video correction algorithm based on GPU, ensure to calculate While performance, increase its real-time.
The main process of this algorithm is to extract a number of image during whole video first, corrected The acquisition of parameter.Then, coordinate diagram is demarcated according to fish eye images feature, asks for the ideal value and actual value of calibration point pixel, together Shi Shengcheng coordinate maps.Finally, after coordinate map being used for each frame of flake video, correct, obtain undistorted frame by frame Video.
Concrete scheme is a kind of quick flake correction algorithm based on GPU, and step is as follows:
Step 1:A number of image is extracted from video, obtains correction parameter.
Step 2:Coordinate is demarcated according to feature of image:It is zero that the distortion of optical center, which can be ignored, centered on camera lens, from The more remote place distortion of camera lens is bigger.Coordinate diagram is demarcated centered on camera lens, the demarcation of coordinate is carried out to image, by square equal Even arrangement round dot, the ideal value and actual value of calibration point pixel are asked for, generate coordinate map.
Step 3:Correct frame by frame, after the coordinate of central point and correction shape is obtained, flake video is realized using GPU The correction of each frame, so as to the video after entirely being corrected.
Specific steps are as shown in Figure 1.
In an example of the present invention, the quick flake correction algorithm based on GPU:
Step 1:A number of image is extracted from video:Input the chessboard trrellis diagram of distortion extracted from video and Tessellated size (the angle point number in transverse and longitudinal coordinate).Fig. 2, tessellated size is (15,10) cm in 3.
Step 2:1) correction parameter is obtained:Extract X-comers.2) image of input is converted into gray-scale map.3) find The adjacent square of grid.The grid of back generation is inputted, for each grid, all grids is all traveled through, calculates phase The distance of adjacent grid fixed point, and find the grid of minimum distance, the grid is denoted as be current grid adjacent square.Through Original adjacent o'clock after expansion is spent and has become two from one, substituted the two points with a point now, this point The common intersection of two grids before being exactly expansion.4) check that whether horizontal grid is concordant.For in every a line and each row All angle points, investigate whether the angle point is projected in the row or the first of the row is put on formed line segment, finally to ensure The correctness of gridiron pattern grid extraction.5) sub-pix angle point is found out.For the grid finally extracted, its sub-pix is found Accurate angle point, return to these angle points.6) the continuous interative computation of Jacobian matrix is utilized, finally gives translation matrix, spin matrix And rotating vector, distortion factor is obtained, that is, obtains the mapping relations of x coordinate and y-coordinate.
Step 3:Using GPU it is parallel coordinate transform, the image after being corrected are carried out to image.
Step 4:To each frame in the video that is obtained in step 1, corrected, you can the video after being corrected.

Claims (3)

1. a kind of quick flake antidote based on GPU, it is characterized in that, a fixed number is extracted during whole video first The image of amount, correct the acquisition of parameter;Coordinate diagram is demarcated according to fish eye images feature, asks for the ideal value of calibration point pixel And actual value, while generate coordinate map;Then, after coordinate map being used for each frame of flake video, obtain without abnormal Become video.
2. the quick flake antidote based on GPU as claimed in claim 1, it is characterized in that, specifically:
Step 1:A number of image is extracted from video, obtains correction parameter;
Step 2:Coordinate is demarcated according to feature of image:Coordinate diagram is demarcated centered on camera lens, the demarcation of coordinate is carried out to image, is pressed The evenly distributed round dot of square, the ideal value and actual value of calibration point pixel are asked for, generates coordinate map;
Step 3:Correct frame by frame, after the coordinate of central point and correction shape is obtained, each of flake video is realized using GPU The correction of frame, so as to the video after entirely being corrected.
3. the quick flake antidote based on GPU as claimed in claim 1, it is characterized in that, in an example, step is such as Under:
Step 1:A number of image is extracted from video:Input the chessboard trrellis diagram and chessboard for the distortion extracted from video The size of lattice;
Step 2:1) correction parameter is obtained:Extract X-comers, 2) image of input is converted into gray-scale map, 3) find grid Adjacent square, by back generation grid input, for each grid, all travel through all grids, calculate adjacent The distance of grid fixed point, and finds the grid of minimum distance, the grid is denoted as be current grid adjacent square, have passed through Become two from one within original adjacent o'clock after expansion, substitute the two points with a point now, this, which is put, is exactly The common intersection of two grids before expansion, 4) check that whether horizontal grid is concordant, for owning in every a line and each row Angle point, investigate the angle point and whether be projected in the first of the row or the row and put on formed line segment, finally to ensure chessboard The correctness of lattice grid extraction, 5) sub-pix angle point is found out, for the grid finally extracted, find the accurate of its sub-pix Angle point, returns to these angle points, and 6) the continuous interative computation of Jacobian matrix is utilized, finally give translation matrix, spin matrix and rotation Steering volume, distortion factor is obtained, that is, obtain the mapping relations of x coordinate and y-coordinate;
Step 3:Using GPU it is parallel coordinate transform, the image after being corrected are carried out to image;
Step 4:To each frame in the video that is obtained in step 1, corrected, you can the video after being corrected.
CN201710693674.8A 2017-08-14 2017-08-14 Quick flake antidote based on GPU Pending CN107644402A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710693674.8A CN107644402A (en) 2017-08-14 2017-08-14 Quick flake antidote based on GPU

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710693674.8A CN107644402A (en) 2017-08-14 2017-08-14 Quick flake antidote based on GPU

Publications (1)

Publication Number Publication Date
CN107644402A true CN107644402A (en) 2018-01-30

Family

ID=61110781

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710693674.8A Pending CN107644402A (en) 2017-08-14 2017-08-14 Quick flake antidote based on GPU

Country Status (1)

Country Link
CN (1) CN107644402A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021179605A1 (en) * 2020-03-12 2021-09-16 佳都新太科技股份有限公司 Gpu-based camera video projection method and apparatus, device, and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101072288A (en) * 2007-06-15 2007-11-14 林进灯 Method for obtaining fish-eye image correction relationship and fish-eye correction
JP2008048443A (en) * 2007-09-21 2008-02-28 Fujitsu Ltd Fisheye lens camera apparatus and image extraction method thereof
US20130120524A1 (en) * 2011-11-14 2013-05-16 Nvidia Corporation Navigation device
CN103268612A (en) * 2013-05-27 2013-08-28 浙江大学 Single image fisheye camera calibration method based on low rank characteristic recovery
CN103839227A (en) * 2012-11-23 2014-06-04 富士通株式会社 Fisheye image correction method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101072288A (en) * 2007-06-15 2007-11-14 林进灯 Method for obtaining fish-eye image correction relationship and fish-eye correction
JP2008048443A (en) * 2007-09-21 2008-02-28 Fujitsu Ltd Fisheye lens camera apparatus and image extraction method thereof
US20130120524A1 (en) * 2011-11-14 2013-05-16 Nvidia Corporation Navigation device
CN103839227A (en) * 2012-11-23 2014-06-04 富士通株式会社 Fisheye image correction method and device
CN103268612A (en) * 2013-05-27 2013-08-28 浙江大学 Single image fisheye camera calibration method based on low rank characteristic recovery

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
GIRAFFFEEE: "利用opencv棋盘格标定法对鱼眼图像校正分析", 《CSDN博客》 *
司磊 等: "鱼眼图像畸变校正算法", 《硅谷》 *

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2021179605A1 (en) * 2020-03-12 2021-09-16 佳都新太科技股份有限公司 Gpu-based camera video projection method and apparatus, device, and storage medium

Similar Documents

Publication Publication Date Title
CN103198488B (en) PTZ surveillance camera realtime posture rapid estimation
CN104794728A (en) Method for reconstructing real-time three-dimensional face data with multiple images
CN104183016B (en) A kind of construction method of quick 2.5 dimension building model
CN104537616A (en) Correction method for fisheye image distortion
CN109658444B (en) Regular three-dimensional color point cloud registration method based on multi-modal features
CN106780389B (en) Fisheye image correction method and device based on coordinate transformation
CN104809739B (en) A kind of method of bugeye lens camera video real time correction
CN103247075A (en) Variational mechanism-based indoor scene three-dimensional reconstruction method
CN108492333B (en) Spacecraft attitude estimation method based on satellite-rocket docking ring image information
CN109758355A (en) One kind is based on the processing of human acupoint two dimensional image and 3 D stereo localization method
CN102054291A (en) Method and device for reconstructing three-dimensional face based on single face image
CN102831601A (en) Three-dimensional matching method based on union similarity measure and self-adaptive support weighting
CN104217435A (en) Method of determining intrinsic parameters of parabolic catadioptric camera through linearity of two mutually-shielded spheres
CN107145224B (en) Human eye sight tracking and device based on three-dimensional sphere Taylor expansion
CN107105218B (en) A kind of visual field picture image generation method and device
CN110264527A (en) Real-time binocular stereo vision output method based on ZYNQ
CN112101247B (en) Face pose estimation method, device, equipment and storage medium
CN112669280A (en) Unmanned aerial vehicle oblique aerial photography right-angle image control point target detection method based on LSD algorithm
CN106778767A (en) Visual pattern feature extraction and matching process based on ORB and active vision
CN110738730A (en) Point cloud matching method and device, computer equipment and storage medium
CN109583377A (en) A kind of control method, device and host computer that pipeline model is rebuild
CN107958489B (en) Curved surface reconstruction method and device
CN103955687B (en) A kind of method for rapidly positioning of the light spot image center based on centroid method
CN107644402A (en) Quick flake antidote based on GPU
CN112184807B (en) Golf ball floor type detection method, system and 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
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20180130