CN102376094B - For the fast image marking method that video detects - Google Patents

For the fast image marking method that video detects Download PDF

Info

Publication number
CN102376094B
CN102376094B CN201010254669.5A CN201010254669A CN102376094B CN 102376094 B CN102376094 B CN 102376094B CN 201010254669 A CN201010254669 A CN 201010254669A CN 102376094 B CN102376094 B CN 102376094B
Authority
CN
China
Prior art keywords
pixel
scanned
buffer zone
scanning
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.)
Active
Application number
CN201010254669.5A
Other languages
Chinese (zh)
Other versions
CN102376094A (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.)
Shanghai Baokang Electronic Control Engineering Co Ltd
Original Assignee
Shanghai Baokang Electronic Control Engineering Co Ltd
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 Shanghai Baokang Electronic Control Engineering Co Ltd filed Critical Shanghai Baokang Electronic Control Engineering Co Ltd
Priority to CN201010254669.5A priority Critical patent/CN102376094B/en
Publication of CN102376094A publication Critical patent/CN102376094A/en
Application granted granted Critical
Publication of CN102376094B publication Critical patent/CN102376094B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Analysis (AREA)

Abstract

The present invention relates to a kind of fast image marking method detected for video, the method comprises the following steps: first set up buffer zone to be scanned, start to line by line scan and detect first need marked pixels time, mark this pixel, and by its adjacent marked pixels that needs stored in buffer zone to be scanned, scan the pixel in buffer zone to be scanned subsequently, scan when needing marked pixels, this pixel of same mark, and by its adjacent marked pixels that needs stored in buffer zone to be scanned, repeat this process until the picture element scan in buffer zone to be scanned is complete, afterwards, the pixel of other non-scanned in scan image, until complete the scanning of whole pixel.Adopt such fast image marking method, once the pixel in buffer zone to be scanned is scanned, namely the scanning of one group of connected pixel is completed, repeating label can not be produced, eliminate the step merging mark, and not by the constraint of dynamic object shape, speed of convergence is very fast, greatly improves the speed that video detects.

Description

For the fast image marking method that video detects
Technical field
The present invention relates to image analysis technology, particularly motion image detection technology, specifically refer to the fast image marking method detected for video.
Background technology
The common way of current Moving Targets Based on Video Streams detection technique is, after setting up initial background estimation model, front and back two width image is done respectively and splits, obtain the bianry image comprising multiple connected region, system utilizes the style characteristic of image object, position feature etc. automatically to identify suspicious motion target.Now, need to utilize mark disposal route to detect respectively each connected region block, specifically referring to when lining by line scan to bianry image, to needing the pixel of mark to mark, and giving identical connection label to the marked pixels in same connected region block.Produced problem of lining by line scan like this is, some pixel can by repeating label, therefore, need to rescan whole image, and the minimum label label of each labeled pixel changed in its neighborhood, carry out merging mark, to eliminate the repeating label problem of a pixel, repeatedly perform this process, until do not need change of marking.When processing little and convex target in this way, speed of convergence is comparatively slow, and treatment effeciency is very low.
Traditional Region growing labels method and current majority are improved one's methods all to be needed to process above-mentioned repeating label problem, and the implementation efficiency of these disposal routes largely depends on the order of severity of repeating label.
Summary of the invention
The object of the invention is to overcome above-mentioned shortcoming of the prior art, provide a kind of based on storage of array mode, can not repeating label be produced, without the need to carrying out label merging, treatment step is simple, fast convergence rate, the fast image marking method detected for video that efficiency is higher.
In order to realize above-mentioned object, the fast image marking method for video detection of the present invention comprises the following steps:
(0) according to the size of data of image to be marked, initialization buffer zone to be scanned;
(1) the non-scanning element treated in marking image is lined by line scan;
(2) when scanning the pixel needing mark, entering step (3), when not scanning the pixel needing mark, entering step (6);
(3) what mark scanned needs marked pixels, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned;
(4) scanning the pixel in buffer zone to be scanned, when scanning the pixel needing mark, returning step (3), when not scanning the pixel needing mark, entering step (5);
(5) step (1) is returned;
(6) complete image tagged, terminate the method.
In the fast image marking method that this detects for video, described neighbor comprises surrounding eight pixels adjacent with the pixel marked.
In the fast image marking method that this detects for video, described buffer zone to be scanned is two-dimensional array, and single group numerical value is for storing the two-dimensional coordinate of a pixel, and described step (3) specifically refers to:
(3) what mark scanned needs marked pixels, and all adjacent of this pixel is needed the two-dimensional coordinate of marked pixels all stored in described buffer zone to be scanned two-dimensional array.
In the fast image marking method that this detects for video, the pixel in described scanning buffer zone to be scanned, is specially:
Extract the coordinate figure in the two-dimensional array of buffer zone to be scanned, and according to coordinate figure scanning respective pixel.
In the fast image marking method that this detects for video, described image to be marked is that each pixel is all with the bianry image that 0 or 1 represent.
In the fast image marking method that this detects for video, also can comprise the following steps before entering step (5):
(5-0) by previous carry out step (1) after the pixel that marks be labeled as one group of connected pixel further, this described group connected pixel forms a dynamic object.
Have employed the fast image marking method detected for video of this invention, first it set up buffer zone to be scanned according to the size of image to be marked, start to line by line scan and detect first need marked pixels time, mark this pixel, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned, scan the pixel in buffer zone to be scanned subsequently, scan when needing marked pixels, this pixel of same mark, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned, repeat this process until the picture element scan in buffer zone to be scanned is complete, afterwards, start the pixel of other non-scanned in scan image, until complete the scanning of whole pixel.Such labeling method, once the pixel in buffer zone to be scanned is scanned, namely completes the scanning of one group of connected pixel, and this group connected pixel forms a dynamic object.The disposable scanning completed connected pixel of the method, can not carry out repeating label, eliminates the step merging mark, achieve real Fast Labeling, and not by the constraint of dynamic object shape, speed of convergence is very fast, thus greatly improve the speed of video detection.
Accompanying drawing explanation
Fig. 1 is the process flow diagram of the fast image marking method for video detection of the present invention.
Fig. 2 be in the preferred embodiments of the present invention by adjacent pixel coordinate stored in the schematic diagram in the array of buffer zone to be scanned.
The present invention is used for detection method process flow diagram when video detects by Fig. 3.
Embodiment
In order to more clearly understand technology contents of the present invention, describe in detail especially exemplified by following examples.
Referring to shown in Fig. 1, is the process flow diagram of a kind of embodiment of the fast image marking method for video detection provided by the present invention.The method comprises the following steps:
(0) according to the size of data of image to be marked, initialization buffer zone to be scanned;
(1) the non-scanning element treated in marking image is lined by line scan;
(2) when scanning the pixel needing mark, entering step (3), when not scanning the pixel needing mark, entering step (6);
(3) what mark scanned needs marked pixels, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned;
(4) scanning the pixel in buffer zone to be scanned, when scanning the pixel needing mark, returning step (3), when not scanning the pixel needing mark, entering step (5);
(5) step (1) is returned;
(6) complete image tagged, terminate the method.
In one preferred embodiment of the invention, as shown in Figure 2, described neighbor comprises surrounding eight pixels adjacent with the pixel I marked, i.e. eight fields, its coordinate can be expressed as (x1, y1), (x2, y2) ... (x8, y8).Described buffer zone to be scanned is two-dimensional array, single group numerical value is for storing the two-dimensional coordinate of a pixel, described step (3) specifically refers to: what (3) mark scanned needs marked pixels, and all adjacent of this pixel is needed the two-dimensional coordinate of marked pixels all stored in described buffer zone to be scanned two-dimensional array.Pixel in described scanning buffer zone to be scanned, is specially: extract the coordinate figure in the two-dimensional array of buffer zone to be scanned, and according to coordinate figure scanning respective pixel.
In another preferred embodiment of the invention, described image to be marked is that each pixel is all with the bianry image that 0 or 1 represent.
In the preferred embodiment of one of the present invention, further comprising the steps of before entering step (5):
(5-0) by previous carry out step (1) after the pixel that marks be labeled as one group of connected pixel further, this described group connected pixel forms a dynamic object.
In an application of the invention, for video detect fast image marking method step as shown in Figure 3.Obtaining binary image data to be detected, and after the two-dimensional array of initialization buffer zone to be scanned, start picture element scan line by line, find the pixel of first need mark, after marking this pixel, the pixel coordinate its eight neighborhood domestic demand marked is stored in buffer zone to be scanned, then start eight neighborhood relation of equivalence to detect, after completing the detection of eight neighborhood relation of equivalence, be communicated with data label, forming a dynamic object be made up of connected pixel, having continued the scanning to not examining pixel subsequently, until all picture element scans of image to be checked are complete.
Have employed the fast image marking method detected for video of this invention, first it set up buffer zone to be scanned according to the size of image to be marked, start to line by line scan and detect first need marked pixels time, mark this pixel, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned, scan the pixel in buffer zone to be scanned subsequently, scan when needing marked pixels, this pixel of same mark, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned, repeat this process until the picture element scan in buffer zone to be scanned is complete, afterwards, start the pixel of other non-scanned in scan image, until complete the scanning of whole pixel.Such labeling method, once the pixel in buffer zone to be scanned is scanned, namely completes the scanning of one group of connected pixel, and this group connected pixel forms a dynamic object.The disposable scanning completed connected pixel of the method, can not carry out repeating label, eliminates the step merging mark, achieve real Fast Labeling, and not by the constraint of dynamic object shape, speed of convergence is very fast, thus greatly improve the speed of video detection.
In this description, the present invention is described with reference to its specific embodiment.But, still can make various amendment and conversion obviously and not deviate from the spirit and scope of the present invention.Therefore, instructions and accompanying drawing are regarded in an illustrative, rather than a restrictive.

Claims (4)

1., for the fast image marking method that video detects, it is characterized in that, described method comprises the following steps:
(0) according to the size of data of image to be marked, initialization buffer zone to be scanned;
(1) pixel scanned without step (1) or step (4) treated in marking image is lined by line scan;
(2) when scanning the pixel needing mark, entering step (3), when not scanning the pixel needing mark, entering step (6);
(3) what mark scanned needs marked pixels, and by all adjacent marked pixels that needs of this pixel stored in buffer zone to be scanned;
(4) scanning the pixel in buffer zone to be scanned, when scanning the pixel needing mark, returning step (3), when not scanning the pixel needing mark, entering step (5);
(5) step (1) is returned;
(6) complete image tagged, terminate the method;
Further comprising the steps of before entering step (5):
(5-0) by previous carry out step (1) after the pixel that marks be labeled as one group of connected pixel further, this described group connected pixel forms a dynamic object;
Described buffer zone to be scanned is two-dimensional array, and single group numerical value is for storing the two-dimensional coordinate of a pixel, and described step (3) specifically refers to:
What mark scanned needs marked pixels, and all adjacent of this pixel is needed the two-dimensional coordinate of marked pixels all stored in described buffer zone to be scanned two-dimensional array.
2. the fast image marking method detected for video according to claim 1, is characterized in that, neighbor comprises surrounding eight pixels adjacent with the pixel marked.
3. the fast image marking method detected for video according to claim 1, it is characterized in that, the pixel in described scanning buffer zone to be scanned, is specially:
Extract the coordinate figure in the two-dimensional array of buffer zone to be scanned, and according to coordinate figure scanning respective pixel.
4. the fast image marking method detected for video according to claim 1, it is characterized in that, described image to be marked is that each pixel is all with the bianry image that 0 or 1 represent.
CN201010254669.5A 2010-08-17 2010-08-17 For the fast image marking method that video detects Active CN102376094B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201010254669.5A CN102376094B (en) 2010-08-17 2010-08-17 For the fast image marking method that video detects

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201010254669.5A CN102376094B (en) 2010-08-17 2010-08-17 For the fast image marking method that video detects

Publications (2)

Publication Number Publication Date
CN102376094A CN102376094A (en) 2012-03-14
CN102376094B true CN102376094B (en) 2016-03-09

Family

ID=45794644

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201010254669.5A Active CN102376094B (en) 2010-08-17 2010-08-17 For the fast image marking method that video detects

Country Status (1)

Country Link
CN (1) CN102376094B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103679682A (en) * 2012-09-07 2014-03-26 鸿富锦精密工业(深圳)有限公司 System and method for finding image spots
CN108875631A (en) * 2018-06-14 2018-11-23 北京华开领航科技有限责任公司 A kind of track switch opens direction and determines method and device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101246554A (en) * 2008-03-11 2008-08-20 中国科学院光电技术研究所 Multi-target image segmentation method based on image element marking
CN101727654A (en) * 2009-08-06 2010-06-09 北京理工大学 Method realized by parallel pipeline for performing real-time marking and identification on connected domains of point targets

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
TWI386030B (en) * 2008-06-11 2013-02-11 Vatics Inc Algorithm for hybrid connected-component-labeling

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101246554A (en) * 2008-03-11 2008-08-20 中国科学院光电技术研究所 Multi-target image segmentation method based on image element marking
CN101727654A (en) * 2009-08-06 2010-06-09 北京理工大学 Method realized by parallel pipeline for performing real-time marking and identification on connected domains of point targets

Also Published As

Publication number Publication date
CN102376094A (en) 2012-03-14

Similar Documents

Publication Publication Date Title
TWI506563B (en) A method and apparatus for enhancing reality of two - dimensional code
TW201113815A (en) QR code processing method and apparatus thereof
CN102510448B (en) Multiprocessor-embedded image acquisition and processing method and device
CN104573674A (en) 1D (one-dimensional) barcode recognition for real-time embedded system
TW201143358A (en) Method for distinguishing a 3D image from a 2D image and for identifying the presence of a 3D image format by feature correspondence determination
CN104463067A (en) Method for extracting macro blocks of Grid Matrix two-dimensional bar code
CN110298867A (en) A kind of video target tracking method
CN102663399A (en) Image local feature extracting method on basis of Hilbert curve and LBP (length between perpendiculars)
CN102376094B (en) For the fast image marking method that video detects
US8798391B2 (en) Method for pre-processing an image in facial recognition system
CN102957930A (en) Method and system for automatically identifying 3D (Three-Dimensional) format of digital content
Xie et al. Panet: A pixel-level attention network for 6d pose estimation with embedding vector features
US8306111B2 (en) Image analysis using a hybrid connected component labeling process
Park et al. Fast stitching algorithm by using feature tracking
CN114998347B (en) Semiconductor panel corner positioning method and device
Shen et al. Plant image mosaic based on depth and color dual information feature source from Kinect
CN100454327C (en) Identification method for data matrix code
Wu et al. Research of quickly identifying markers on augmented reality
CN103198449B (en) A kind of digital watermark method of 3-D view
JP5975484B2 (en) Image processing device
CN110969043A (en) Two-dimensional code detection system and method based on key point detection
TW201023649A (en) Method and apparatus of tile-based belief propagation
CN101599260B (en) Method and device for enlarging or shrinking image through sharable hardware
CN116030272B (en) Target detection method, system and device based on information extraction
CN113392795B (en) Combined detection model training, combined detection method, device, equipment and medium

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant