CN102855473B - A kind of image multi-target detection method based on similarity measurement - Google Patents
A kind of image multi-target detection method based on similarity measurement Download PDFInfo
- Publication number
- CN102855473B CN102855473B CN201210299415.4A CN201210299415A CN102855473B CN 102855473 B CN102855473 B CN 102855473B CN 201210299415 A CN201210299415 A CN 201210299415A CN 102855473 B CN102855473 B CN 102855473B
- Authority
- CN
- China
- Prior art keywords
- image
- bof
- detected
- target
- vector
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Expired - Fee Related
Links
- 238000001514 detection method Methods 0.000 title claims abstract description 51
- 238000005259 measurement Methods 0.000 title claims abstract description 9
- 239000013598 vector Substances 0.000 claims abstract description 37
- 238000000034 method Methods 0.000 claims abstract description 12
- 238000000605 extraction Methods 0.000 claims description 2
- 238000005286 illumination Methods 0.000 abstract description 2
- 238000011524 similarity measure Methods 0.000 description 4
- 238000004364 calculation method Methods 0.000 description 2
- 238000010586 diagram Methods 0.000 description 2
- 238000000691 measurement method Methods 0.000 description 2
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
- 238000011897 real-time detection Methods 0.000 description 1
- 230000009466 transformation Effects 0.000 description 1
Landscapes
- Image Analysis (AREA)
Abstract
本发明涉及一种基于相似性度量的图像多目标检测方法,该方法具体步骤:步骤一:提取目标样本库中每幅图像的特征点,计算出每幅图像的BOF词袋向量,从而构成所述目标样本库的BOF向量集合;步骤二:利用目标样本库的BOF向量集合构建所述目标样本库的M-Tree索引;步骤三:将待检测图像在M-tree索引中进行多目标检测,并将检测果返回给用户;该方法利用BOF向量进行目标检测,具有很好的鲁棒性,对目标形变,遮挡,光照变化不敏感;可以一次检测多个目标,不需要重复检测,可以实现高效的在线多目标检测;该方法可广泛用于网络信息安全、图像多目标检测,视频多目标跟踪等多个领域。
The invention relates to an image multi-target detection method based on similarity measurement. The specific steps of the method are as follows: step 1: extract the feature points of each image in the target sample library, and calculate the BOF word bag vector of each image, thereby forming the The BOF vector set of the target sample library; Step 2: Utilize the BOF vector set of the target sample library to construct the M-Tree index of the target sample library; Step 3: Carry out multi-target detection on the image to be detected in the M-tree index, And return the detection results to the user; this method uses BOF vectors for target detection, which has good robustness and is not sensitive to target deformation, occlusion, and illumination changes; multiple targets can be detected at one time, without repeated detection, and can be realized Efficient online multi-target detection; this method can be widely used in many fields such as network information security, image multi-target detection, and video multi-target tracking.
Description
技术领域 technical field
本发明涉及一种图像检测方法,尤其涉及一种基于相似性度量的图像多目标检测方法。The invention relates to an image detection method, in particular to an image multi-target detection method based on similarity measure.
背景技术 Background technique
图像目标的匹配和检测一直是计算机视觉中一个非常重要的领域。在图像目标的检测中,检测方法主要有基于图像局部特征的检测方法和基于滑动窗口的检测方法。其中,基于图像局部特征的检测方法包括以下步骤:特征检测,特征识别,以及模型匹配。然而,基于滑动窗口的检测方法则是通过不同大小的窗口对输入图像进行扫描,并判断所扫描的图像块之中是否含有目标对象。Image object matching and detection has always been a very important field in computer vision. In the detection of image objects, the detection methods mainly include detection methods based on local features of images and detection methods based on sliding windows. Wherein, the detection method based on local image features includes the following steps: feature detection, feature recognition, and model matching. However, the detection method based on the sliding window scans the input image through windows of different sizes, and judges whether the scanned image block contains the target object.
这些算法已经比较成熟并且可以达到实时检测,但是这些方法在应用到多目标检测的时候存在扩展性问题。基于图像局部特征的检测方法在检测多个目标时,需要分别将每个目标图像的特征点与待检测图像的特征点进行匹配,分别找到每个目标匹配的位置,这样会导致匹配时间随目标数量的增加呈线性增加的趋势;基于滑动窗口的检测方法在检测多个目标时,需要将待检测图像子块分别与每个目标图像进行匹配,分别判断是否是目标位置,这样匹配时间也会随目标数量的增加线性增加。These algorithms are relatively mature and can achieve real-time detection, but these methods have scalability problems when applied to multi-target detection. When the detection method based on image local features detects multiple targets, it needs to match the feature points of each target image with the feature points of the image to be detected, and find the matching position of each target respectively, which will cause the matching time to vary with the target The increase of the number shows a linear increase trend; when the detection method based on the sliding window detects multiple targets, it needs to match the sub-blocks of the image to be detected with each target image to judge whether it is the target position, so the matching time will also decrease increases linearly with the number of targets.
由上所述,现有基于图像局部特征的检测方法和基于滑动窗口的检测方法的检测时间会随着待检测样本目标数量的增加线性增加。对于大量的图像目标,检测效率很低,不适合应用以上方法。在检测的过程中,用户希望系统能够具有很好的检测速度,能够在大规模的目标图像数据里很快的检测到目标。From the above, the detection time of existing detection methods based on local image features and sliding window detection methods will increase linearly with the increase in the number of sample targets to be detected. For a large number of image objects, the detection efficiency is very low, and it is not suitable to apply the above methods. During the detection process, the user hopes that the system can have a good detection speed and can quickly detect the target in large-scale target image data.
发明内容 Contents of the invention
本发明所要解决的技术问题是提供一种基于相似性度量的图像多目标检测方法,该方法可一次检测多个目标,且效率高,快速、准确。The technical problem to be solved by the present invention is to provide an image multi-target detection method based on similarity measurement, which can detect multiple targets at one time, and is efficient, fast and accurate.
本发明解决上述技术问题的技术方案如下:一种基于相似性度量的图像多目标检测方法,其特征在于,该方法具体步骤如下:The technical solution of the present invention to solve the above-mentioned technical problems is as follows: an image multi-target detection method based on similarity measurement, characterized in that the specific steps of the method are as follows:
步骤一:提取目标样本库中每幅图像的特征点,计算出每幅图像的BOF词袋向量,从而构成所述目标样本库的BOF向量集合;Step 1: Extract the feature points of each image in the target sample library, and calculate the BOF bag-of-words vector of each image, thereby forming the BOF vector set of the target sample library;
步骤二:利用所述目标样本库的BOF向量集合构建所述目标样本库的M—Tree索引;Step 2: Utilize the BOF vector set of the target sample library to construct the M-Tree index of the target sample library;
步骤三:将待检测图像在所述M-Tree索引中进行多目标检测,并将检测果返回给用户。Step 3: Perform multi-target detection on the image to be detected in the M-Tree index, and return the detection result to the user.
本发明的有益效果是:本发明所述的一种基于相似性度量的图像多目标检测方法,该方法利用BOF向量构建M-Tree索引进行目标检测,具有很好的鲁棒性,对目标形变,遮挡,光照变化不敏感;可以一次检测多个目标,不需要重复检测,可以实现高效的在线多目标检测;该方法可广泛用于网络信息安全、图像多目标检测,视频多目标跟踪等多个领域。The beneficial effect of the present invention is: a kind of image multi-target detection method based on similarity measure described in the present invention, this method utilizes BOF vector to construct M-Tree index to carry out target detection, has very good robustness, and the target deformation , occlusion, and illumination changes are not sensitive; multiple targets can be detected at one time without repeated detection, and efficient online multi-target detection can be realized; this method can be widely used in network information security, image multi-target detection, video multi-target tracking, etc. fields.
在上述技术方案的基础上,本发明还可以做如下改进。On the basis of the above technical solutions, the present invention can also be improved as follows.
进一步,所述图像特征点的提取是利用sift尺度不变特征变换算法进行的。Further, the extraction of the feature points of the image is carried out by using the SIFT scale-invariant feature transformation algorithm.
进一步,所述计算每幅图像的BOF向量,步骤如下:Further, the steps of calculating the BOF vector of each image are as follows:
1)选取一个具有代表性的图像库,并计算该图像库的所有特征点的聚类类中心,即特征词典;1) Select a representative image library, and calculate the cluster centers of all feature points in the image library, that is, the feature dictionary;
2)计算待计算BOF向量的图像的特征点和步骤1)中所述的聚类类中心之间的欧几里得距离;2) Calculate the Euclidean distance between the feature points of the image of the BOF vector to be calculated and the cluster centers described in step 1);
3)找到离待计算BOF向量的图像的特征点最近的类中心,计算该类中心的频数,并将频数加1;3) Find the nearest class center from the feature point of the image to be calculated BOF vector, calculate the frequency of the class center, and add 1 to the frequency;
4)重复步骤2)、3),直到完成待生成BOF向量的图像的所有的特征点的频数计算,得到该图像的频数直方图,将所述频数直方图向量化即得到该图像的BOF向量。4) Repeat steps 2) and 3) until the frequency calculation of all the feature points of the image to be generated BOF vector is completed, and the frequency histogram of the image is obtained, and the frequency histogram is vectorized to obtain the BOF vector of the image .
进一步,所述将待检测图像在M-tree索引中进行多目标检测,步骤如下:Further, the described image to be detected is carried out multi-target detection in the M-tree index, and the steps are as follows:
1)根据需要定义一个固定尺寸的滑动窗口;1) Define a fixed-size sliding window as needed;
2)所述滑动窗口在待检测图像上按照一定规则进行滑动,得到待检测图像块;2) The sliding window slides on the image to be detected according to certain rules to obtain image blocks to be detected;
3)计算所述待检测图像块的BOF向量;3) calculating the BOF vector of the image block to be detected;
4)将所述待检测图像块的BOF向量在所述M-Tree索引中进行匹配;4) matching the BOF vector of the image block to be detected in the M-Tree index;
5)利用相似性度量方法检测所述M-Tree索引中是否存在与所述待检测图像块相似的目标,如果存在,执行步骤6),否则,返回步骤2);5) Using a similarity measurement method to detect whether there is an object similar to the image block to be detected in the M-Tree index, if there is, perform step 6); otherwise, return to step 2);
6)将检测到的相似目标图像以及其在待检测大图像中的位置返回给用户。6) Return the detected similar target images and their positions in the large image to be detected to the user.
进一步,所述一定规则是按照自左向右,自上而下的方向滑动,每次向右或者向下滑动的距离为一个常量。Further, the certain rule is to slide from left to right and from top to bottom, and the distance of each slide to the right or down is a constant.
附图说明 Description of drawings
图1为本发明涉及的一种基于相似性度量的图像多目标检测方法的总流程图;Fig. 1 is the overall flow chart of a kind of image multi-target detection method based on similarity measure that the present invention relates to;
图2为本发明涉及的计算每幅图像BOF向量步骤的流程图;Fig. 2 is the flow chart of calculating the BOF vector step of each image involved in the present invention;
图3为本发明涉及的待检测图像在M-tree索引中进行多目标检测步骤的流程图;Fig. 3 is the flow chart of the multi-target detection steps of the image to be detected in the M-tree index involved in the present invention;
图4为本发明涉及的滑动窗口在待检测图像上滑动的示意图。Fig. 4 is a schematic diagram of the sliding window sliding on the image to be detected involved in the present invention.
附图中,各标号所代表的部件列表如下:In the accompanying drawings, the list of parts represented by each label is as follows:
1、待检测图像,2、滑动窗口。1. The image to be detected, 2. The sliding window.
具体实施方式 detailed description
以下结合附图对本发明的原理和特征进行描述,所举实例只用于解释本发明,并非用于限定本发明的范围。The principles and features of the present invention are described below in conjunction with the accompanying drawings, and the examples given are only used to explain the present invention, and are not intended to limit the scope of the present invention.
如图1所示为本发明涉及的一种基于相似性度量的图像多目标检测方法的总流程图;图2为本发明涉及的计算每幅图像BOF向量步骤的流程图;图3为本发明涉及的待检测图像在M-tree索引中进行多目标检测步骤的流程图;图4是为本发明涉及的滑动窗口在待检测图像上滑动的示意图。如图1、2、3、4所示,一种基于相似性度量的图像多目标检测方法的具体步骤如下:As shown in Figure 1, it is a general flow chart of a kind of image multi-target detection method based on similarity measure that the present invention relates to; Figure 2 is a flow chart of calculating each image BOF vector step involved in the present invention; Figure 3 is the present invention The flow chart of the multi-target detection steps in the M-tree index of the image to be detected involved; FIG. 4 is a schematic diagram of the sliding window sliding on the image to be detected involved in the present invention. As shown in Figures 1, 2, 3, and 4, the specific steps of an image multi-target detection method based on similarity measurement are as follows:
由用户提供目标样本库和待检测图像。The user provides the target sample library and the image to be detected.
步骤一:提取目标样本库中每幅图像的特征点,计算出每幅图像的BOF词袋向量,从而构成所述目标样本库的BOF向量集合;计算每幅图像的BOF向量的步骤如下:Step 1: extract the feature points of each image in the target sample library, and calculate the BOF word bag vector of each image, thereby forming the BOF vector set of the target sample library; the steps of calculating the BOF vector of each image are as follows:
1)选取一个具有代表性的图像库,并计算该图像库的所有特征点的聚类类中心,即特征词典;1) Select a representative image library, and calculate the cluster centers of all feature points in the image library, that is, the feature dictionary;
2)计算待计算BOF向量的图像的特征点和步骤1)中所述的聚类类中心之间的欧几里得距离;2) Calculate the Euclidean distance between the feature points of the image to be calculated BOF vector and the cluster center described in step 1);
3)找到离待计算BOF向量的图像的特征点最近的类中心,计算该类中心的频数,并将频数加1;3) Find the nearest class center from the feature point of the image to be calculated BOF vector, calculate the frequency of the class center, and add 1 to the frequency;
4)重复步骤2)、3),直到完成待生成BOF向量的图像的所有的特征点的频数计算,得到该图像的频数直方图,将所述频数直方图向量化即得到该图像的BOF向量。4) Repeat steps 2) and 3) until the frequency calculation of all the feature points of the image to be generated BOF vector is completed, and the frequency histogram of the image is obtained, and the frequency histogram is vectorized to obtain the BOF vector of the image .
步骤二:利用所述目标样本库的BOF向量集合构建所述目标样本库的M—Tree索引;Step 2: Utilize the BOF vector set of the target sample library to construct the M-Tree index of the target sample library;
步骤三:将待检测图像在所述M-tree索引中进行多目标检测,并将检测果返回给用户;检测具体步骤如下:Step 3: Perform multi-target detection on the image to be detected in the M-tree index, and return the detection result to the user; the specific steps of detection are as follows:
1)根据需要定义一个固定尺寸的滑动窗口2;1) Define a fixed-size sliding window 2 as required;
2)所述滑动窗口2在待检测图像1上按照一定规则进行滑动,得到待检测图像块;2) The sliding window 2 slides on the image to be detected 1 according to certain rules to obtain the image block to be detected;
3)计算所述待检测图像块的BOF向量;3) calculating the BOF vector of the image block to be detected;
4)将所述待检测图像块的BOF向量在所述M-Tree索引中进行匹配;4) matching the BOF vector of the image block to be detected in the M-Tree index;
5)利用相似性度量方法检测所述M-Tree索引中是否存在与所述待检测图像块相似的目标,如果存在,执行步骤6),否则,返回步骤2);5) Using a similarity measurement method to detect whether there is an object similar to the image block to be detected in the M-Tree index, if there is, perform step 6); otherwise, return to step 2);
6)将检测到的相似目标图像以及其在待检测大图像中的位置返回给用户。6) Return the detected similar target images and their positions in the large image to be detected to the user.
其中,所述一定规则是按照自左向右,自上而下的方向滑动,每次向右或者向下滑动的距离为一个常量。Wherein, the certain rule is to slide from left to right and from top to bottom, and the distance of each slide to the right or down is a constant.
以上所述仅为本发明的较佳实施例,并不用以限制本发明,凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。The above descriptions are only preferred embodiments of the present invention, and are not intended to limit the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention shall be included in the protection of the present invention. within range.
Claims (4)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210299415.4A CN102855473B (en) | 2012-08-21 | 2012-08-21 | A kind of image multi-target detection method based on similarity measurement |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201210299415.4A CN102855473B (en) | 2012-08-21 | 2012-08-21 | A kind of image multi-target detection method based on similarity measurement |
Publications (2)
Publication Number | Publication Date |
---|---|
CN102855473A CN102855473A (en) | 2013-01-02 |
CN102855473B true CN102855473B (en) | 2016-03-02 |
Family
ID=47402051
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201210299415.4A Expired - Fee Related CN102855473B (en) | 2012-08-21 | 2012-08-21 | A kind of image multi-target detection method based on similarity measurement |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN102855473B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103413295B (en) * | 2013-07-12 | 2016-12-28 | 长沙理工大学 | A kind of video multi-target long-range tracking |
CN105654054B (en) * | 2015-12-30 | 2018-12-04 | 上海颐本信息科技有限公司 | The intelligent video analysis method of study and more visual dictionary models is propagated based on semi-supervised neighbour |
CN105844290B (en) * | 2016-03-16 | 2019-10-25 | 网易(杭州)网络有限公司 | The method and device of multiple same objects in matching image |
CN106295716A (en) * | 2016-08-23 | 2017-01-04 | 广东工业大学 | A kind of movement of traffic objective classification method based on video information and device |
CN106681850B (en) * | 2016-12-06 | 2019-11-26 | 北京中交兴路信息科技有限公司 | A kind of vehicle model method of calibration and device |
Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1766907A (en) * | 2005-10-24 | 2006-05-03 | 中国电子科技集团公司第四十五研究所 | Multi-target image recognition method based on cluster genetic algorithm |
US20060204079A1 (en) * | 2005-03-10 | 2006-09-14 | Kabushiki Kaisha Toshiba | Pattern recognition apparatus and method |
-
2012
- 2012-08-21 CN CN201210299415.4A patent/CN102855473B/en not_active Expired - Fee Related
Patent Citations (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20060204079A1 (en) * | 2005-03-10 | 2006-09-14 | Kabushiki Kaisha Toshiba | Pattern recognition apparatus and method |
CN1766907A (en) * | 2005-10-24 | 2006-05-03 | 中国电子科技集团公司第四十五研究所 | Multi-target image recognition method based on cluster genetic algorithm |
Non-Patent Citations (3)
Title |
---|
Video Google: A Text Retrieval Approach to Object Matching in Videos;Josef Sivic 等;《Proceedings of the Ninth IEEE International Conference on Computer Vision》;20031231;第1-8页 * |
图像检索中局部特征的提取和描述及其空间组织研究;杨程;《中国优秀硕士学位论文全文数据库 信息科技辑》;20120115(第01期);第27-54页 * |
运动成像平台近景视频运动目标检测技术研究;孙浩;《中国博士学位论文全文数据库 信息科技辑》;20120715(第7期);第78-94页 * |
Also Published As
Publication number | Publication date |
---|---|
CN102855473A (en) | 2013-01-02 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Danelljan et al. | Accurate scale estimation for robust visual tracking | |
JP5164222B2 (en) | Image search method and system | |
JP5385105B2 (en) | Image search method and system | |
US10339409B2 (en) | Method and a device for extracting local features of a three-dimensional point cloud | |
CN102855473B (en) | A kind of image multi-target detection method based on similarity measurement | |
CN111079785A (en) | An image recognition method, device and terminal device | |
JP2012088881A (en) | Person motion detection device and program thereof | |
CN104915673A (en) | Object classification method and system based on bag of visual word model | |
CN103236068A (en) | Method for matching local images | |
CN101650784A (en) | Method for matching images by utilizing structural context characteristics | |
Chang et al. | Fast Random‐Forest‐Based Human Pose Estimation Using a Multi‐scale and Cascade Approach | |
CN106295710B (en) | Image local feature matching process, device and terminal based on non-geometric constraint | |
CN107704867A (en) | Based on the image characteristic point error hiding elimination method for weighing the factor in a kind of vision positioning | |
Fu et al. | Novel affine‐invariant curve descriptor for curve matching and occluded object recognition | |
US9870517B2 (en) | Image object retrieval | |
CN102930292B (en) | A kind of object identification method based on p-SIFT feature | |
CN104978582A (en) | Contour chord angle feature based identification method for blocked target | |
Kabbai et al. | Image matching based on lbp and sift descriptor | |
CN110210511A (en) | A kind of improvement PCA-SIFT method for registering images based on cosine measure | |
Zhou et al. | Person re-identification based on nonlinear ranking with difference vectors | |
KR101528757B1 (en) | Texture-less object recognition using contour fragment-based features with bisected local regions | |
Wang et al. | Scale‐invariant feature matching based on pairs of feature points | |
Zhang et al. | Robust visual correlation tracking | |
CN110163888A (en) | A kind of novel motion segmentation model quantity detection method | |
Al-Azzawy | Eigenface and SIFT for gender classification |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20160302 Termination date: 20210821 |
|
CF01 | Termination of patent right due to non-payment of annual fee |