CN107230194A - A kind of smooth filtering method based on object point set - Google Patents
A kind of smooth filtering method based on object point set Download PDFInfo
- Publication number
- CN107230194A CN107230194A CN201710508010.XA CN201710508010A CN107230194A CN 107230194 A CN107230194 A CN 107230194A CN 201710508010 A CN201710508010 A CN 201710508010A CN 107230194 A CN107230194 A CN 107230194A
- Authority
- CN
- China
- Prior art keywords
- point set
- boundary
- object point
- edge
- method based
- 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
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/70—Denoising; Smoothing
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/155—Segmentation; Edge detection involving morphological operators
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Image Processing (AREA)
Abstract
本发明公开了一种基于对象点集的平滑滤波方法,包括步骤:获得边界1;获得边界2;对边界1和边界2之间的区域点集进行平滑滤波处理,所述边界1为对象点集经过10次腐蚀后的边缘点集,所述边界2为对象点集经过10次膨胀后的边缘点集。本发明创造的方法利用腐蚀和膨胀的方法得到边界1和边界2,并且利用边界1和边界2得到区域点集,该区域点集反映出整个对象点集的轮廓信息,对该区域点集进行平滑滤波处理,可以消除图片上的对象与对象之间、对象与背景之间的块效应,提高图片的整体质量。
The invention discloses a smoothing filtering method based on an object point set, comprising the steps of: obtaining a boundary 1; obtaining a boundary 2; performing smoothing and filtering processing on the area point set between the boundary 1 and the boundary 2, and the boundary 1 is an object point set is the edge point set after 10 times of erosion, and the boundary 2 is the edge point set of the object point set after 10 times of expansion. The method created by the present invention utilizes the method of erosion and expansion to obtain boundary 1 and boundary 2, and utilizes boundary 1 and boundary 2 to obtain an area point set, which reflects the outline information of the entire object point set, and performs a process on the area point set Smoothing filter processing can eliminate block effects between objects on the picture and between objects and the background, and improve the overall quality of the picture.
Description
技术领域technical field
本发明涉及图像处理技术领域,特别涉及一种基于对象点集的平滑滤波方法。The invention relates to the technical field of image processing, in particular to a smoothing filtering method based on an object point set.
背景技术Background technique
最新的对象提取技术Mask R-CNN,该技术对图像进行语义分割,分割得到的同种类别的像素的集合称为对象点集。一张图片包括若干个对象点集,如果对某个对象点集进行处理时,比如说对某个对象点集进行对比度的调整,在调整之后,对象点集与对象点集之间、对象点集与背景之间则容易出现块效应,这些块效应会影响到整个图片的质量。因此,如果消除对象点集与对象点集之间、对象点集与背景之间的块效应成了领域内急需解决的问题。The latest object extraction technology Mask R-CNN, this technology performs semantic segmentation on the image, and the set of pixels of the same category obtained by segmentation is called the object point set. A picture includes several object point sets. If a certain object point set is processed, such as adjusting the contrast of a certain object point set, after the adjustment, the distance between the object point set and the object point set, the object point Block effects are prone to appear between the set and the background, and these block effects will affect the quality of the entire picture. Therefore, how to eliminate the block effect between the object point set and the object point set, and between the object point set and the background has become an urgent problem in the field.
发明内容Contents of the invention
为了解决上述问题,本发明提供了一种基于对象点集的平滑滤波方法,该方法可有效地解决对象点集与对象点集之间、对象点集与背景之间的块效应。In order to solve the above problems, the present invention provides a smoothing filtering method based on object point sets, which can effectively solve the block effect between object point sets and object point sets, and between object point sets and background.
本发明解决其技术问题的解决方案是:一种基于对象点集的平滑滤波方法,包括步骤:获得边界1;获得边界2;对边界1和边界2之间的区域点集进行平滑滤波处理,所述边界1为对象点集经过10次腐蚀后的边缘点集,所述边界2为对象点集经过10次膨胀后的边缘点集。The solution of the present invention to solve its technical problem is: a kind of smooth filtering method based on the object point set, comprising steps: obtain boundary 1; obtain boundary 2; carry out smooth filter processing to the area point set between boundary 1 and boundary 2, The boundary 1 is the edge point set of the object point set after 10 erosions, and the boundary 2 is the edge point set of the object point set after 10 expansions.
进一步,所述10次腐蚀的方法包括步骤:Further, the method for said 10 times of corrosion comprises steps:
a1)用当前的对象点集减去当前的边缘点集得到新的对象点集;a1) Subtracting the current edge point set from the current object point set to obtain a new object point set;
a2)用所述新的对象点集获取得到新的边缘点集;a2) Obtaining a new edge point set with the new object point set;
a3)重复步骤a1)-a2)10次。a3) Repeat steps a1)-a2) 10 times.
进一步,所述边缘点集的获取方法包括:以对象点集中的任意一个像素点为中心,该点称为中心像素点,判断所述中心像素点的左、右、上、下的像素点与其是否为同一类别,根据判断结果获取边缘点,将所述边缘点集合为边缘点集。Further, the method for obtaining the edge point set includes: taking any pixel point in the object point set as the center, which is called a central pixel point, and judging the relationship between the left, right, upper, and lower pixel points of the central pixel point Whether they belong to the same category, the edge points are obtained according to the judgment result, and the edge points are collected into an edge point set.
进一步,所述10次膨胀的方法包括步骤:Further, the method of said 10 expansions comprises steps:
a11)将结构元的中心放到当前边缘点集的任意一点上,并且结构元的中心沿着所述边缘点集移动,找到属于结构元但不属于对象点集的像素点,并将所述像素点集合为新的边缘点集;a11) Put the center of the structure element on any point of the current edge point set, and move the center of the structure element along the edge point set, find the pixel point that belongs to the structure element but does not belong to the object point set, and put the The set of pixel points is a new set of edge points;
a12)将当前的对象点集与所述边缘点集合并成为新的对象点集;a12) merging the current object point set and the edge point set into a new object point set;
a13)重复步骤a11)-a12)10次。a13) Repeat steps a11)-a12) 10 times.
进一步,采用3×3的滤波模板对边界1和边界2之间的区域点集进行平滑滤波。Further, a 3×3 filtering template is used to perform smoothing filtering on the region point set between boundary 1 and boundary 2.
本发明的有益效果是:本方法利用腐蚀和膨胀的方法得到边界1和边界2,并且利用边界1和边界2得到区域点集,该区域点集反映出整个对象点集的轮廓信息,对该区域点集进行平滑滤波处理,可以消除图片上的对象与对象之间、对象与背景之间的块效应,提高图片的整体质量。The beneficial effect of the present invention is: this method utilizes the method of erosion and dilation to obtain boundary 1 and boundary 2, and utilizes boundary 1 and boundary 2 to obtain the area point set, and this area point set reflects the outline information of the whole object point set, for this The area point set is processed by smoothing filter, which can eliminate the block effect between objects on the picture and between objects and the background, and improve the overall quality of the picture.
附图说明Description of drawings
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单说明。显然,所描述的附图只是本发明的一部分实施例,而不是全部实施例,本领域的技术人员在不付出创造性劳动的前提下,还可以根据这些附图获得其他设计方案和附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following will briefly describe the drawings that need to be used in the description of the embodiments. Apparently, the described drawings are only some embodiments of the present invention, not all embodiments, and those skilled in the art can obtain other designs and drawings based on these drawings without creative work.
图1是基于对象点集的平滑滤波方法的流程图;Fig. 1 is the flow chart of the smoothing filter method based on object point set;
图2是10次腐蚀的流程图;Fig. 2 is the flowchart of 10 corrosions;
图3是10次膨胀的流程图。Figure 3 is a flowchart of 10 expansions.
具体实施方式detailed description
以下将结合实施例和附图对本发明的构思、具体结构及产生的技术效果进行清楚、完整地描述,以充分地理解本发明的目的、特征和效果。显然,所描述的实施例只是本发明的一部分实施例,而不是全部实施例,基于本发明的实施例,本领域的技术人员在不付出创造性劳动的前提下所获得的其他实施例,均属于本发明保护的范围。另外,文中所提到的所有联接/连接关系,并非单指构件直接相接,而是指可根据具体实施情况,通过添加或减少联接辅件,来组成更优的联接结构。本发明创造中的各个技术特征,在不互相矛盾冲突的前提下可以交互组合。The idea, specific structure and technical effects of the present invention will be clearly and completely described below in conjunction with the embodiments and accompanying drawings, so as to fully understand the purpose, features and effects of the present invention. Apparently, the described embodiments are only some of the embodiments of the present invention, rather than all of them. Based on the embodiments of the present invention, other embodiments obtained by those skilled in the art without creative efforts belong to The protection scope of the present invention. In addition, all the connection/connection relationships mentioned in this article do not refer to the direct connection of components, but mean that a better connection structure can be formed by adding or reducing connection accessories according to specific implementation conditions. The various technical features in the invention can be combined interactively on the premise of not conflicting with each other.
实施例1,参考图1,对经过Mask R-CNN技术处理后的图片进行如下处理:一种基于对象点集的平滑滤波方法,Embodiment 1, with reference to Fig. 1, the picture processed by Mask R-CNN technology is processed as follows: a smoothing filter method based on object point set,
S00:找到需要处理的对象并且得到其当前的对象点集;S00: find the object to be processed and obtain its current object point set;
S01:对象点集经过10次腐蚀得到边界1;S01: The object point set undergoes 10 erosions to obtain boundary 1;
S02:对象点集经过10次膨胀得到边界2;S02: The object point set undergoes 10 expansions to obtain boundary 2;
S03:对边界1和边界2之间的区域点集进行平滑滤波处理。S03: Perform smoothing and filtering processing on the area point set between the boundary 1 and the boundary 2.
需要说明的是步骤S01和S02并没有先后顺序所限制,本实施以步骤S01为先。参考图2,其中,10次腐蚀的方法包括如下步骤:It should be noted that the sequence of steps S01 and S02 is not limited, and this implementation takes step S01 first. With reference to Fig. 2, wherein, the method for 10 corrosions comprises the steps:
S1:用当前的对象点集减去当前的边缘点集得到新的对象点集;S1: Subtract the current edge point set from the current object point set to obtain a new object point set;
S2:用所述新的对象点集获取得到新的边缘点集;S2: Obtain a new edge point set by using the new object point set;
S3:重复10次步骤S1-S2。S3: Repeat steps S1-S2 10 times.
其中边缘点集的获取方法包括:此时假设对象点集为∑(xi,yi),在标签类别图中,以∑(xi,yi)每一个像素点(xi,yi)为中心,像素点(xi-1,yi),(xi+1,yi)分别为像素点(xi,yi)的左右两点;(xi,yi+1),(xi,yi-1)分别为点(xi,yi)的上下两点。所述像素点(xi,yi)如果满足以下公式:The method of obtaining the edge point set includes: assuming that the object point set is ∑( xi , y i ), in the label category map, each pixel point ( xi , y i ) with ∑ ( xi , y i ) ) as the center, pixel points ( xi -1,y i ), ( xi +1,y i ) are the left and right points of the pixel point ( xi ,y i ) respectively; ( xi ,y i+1 ) ,(x i , y i -1) are the upper and lower points of point (x i , y i ), respectively. If the pixel ( xi , y ) satisfies the following formula:
|C(xi-1,yi)-C(xi,yi)|+|C(xi,yi)-C(xi+1,yi)|≥1|C(x i -1,y i )-C(x i ,y i )|+|C(x i ,y i )-C(x i+ 1,y i )|≥1
或|C(xi,yi+1)-C(xi,yi)|+|C(xi,yi)-C(xi,yi-1)|≥1则判定所述像素点(xi,yi)为边缘点,将该边缘点集合到边缘点集中。该公式的解释为:像素点(xi,yi)从左到右或者从上到下的像素点标签类别值变化大于等于1。则判定像素点(xi,yi)为边缘点,其中函数C(x,y)指的是像素点(x,y)的标签类别值。Or |C(x i ,y i+1 )-C(x i ,y i )|+|C(x i ,y i )-C(x i ,y i-1 )|≥1, then determine the The pixel point ( xi , y i ) is an edge point, and the edge point is collected into an edge point set. The interpretation of this formula is: the change of the category value of the pixel point label of the pixel point ( xi , y i ) from left to right or from top to bottom is greater than or equal to 1. Then it is determined that the pixel point ( xi , y i ) is an edge point, where the function C(x, y) refers to the label category value of the pixel point (x, y).
参考图3,10次膨胀的方法包括步骤:Referring to Figure 3, the method of 10 expansions includes steps:
S11:将结构元的中心放到当前边缘点集的任意一点上,并且结构元的中心沿着所述边缘点集顺时针移动,找到属于结构元但不属于对象点集的像素点,并将所述像素点集合为新的边缘点集;用公式表示为:其中A为当前的边缘点集,B为结构元,z就是膨胀一次得到的边缘点集。S11: Put the center of the structure element on any point of the current edge point set, and move the center of the structure element clockwise along the edge point set, find the pixel that belongs to the structure element but not the object point set, and set The set of pixel points is a new set of edge points; expressed as: Among them, A is the current edge point set, B is the structural element, and z is the edge point set obtained by one expansion.
S12:将当前的对象点集与所述边缘点集合并成为新的对象点集;S12: Merge the current object point set and the edge point set into a new object point set;
S13:重复10次步骤S11-S12。S13: Repeat steps S11-S12 10 times.
确定边界1和边界2后,便得到了边界1和边界2之间的区域点集,该区域点集满足下面条件:After boundary 1 and boundary 2 are determined, the area point set between boundary 1 and boundary 2 is obtained, and the area point set satisfies the following conditions:
设像素点(x,y)表示区域点集上任意一点,像素点(x1,y1)表示边界1的任意一点,像素点(x2,y2)表示边界2的任意一点,则满足x1=x=x2时,y1<y<y2或者y2<y<y2。Let the pixel point (x, y) represent any point on the area point set, the pixel point (x1, y1) represent any point on the boundary 1, and the pixel point (x2, y2) represent any point on the boundary 2, then satisfy x1=x= When x2, y1<y<y2 or y2<y<y2.
对边界1和边界2之间的区域点集进行平滑滤波处理,本实施例采用3×3的滤波模板,该模板为:Perform smoothing and filtering processing on the regional point set between boundary 1 and boundary 2. This embodiment uses a 3×3 filtering template, which is:
平滑滤波过程如下:The smoothing filtering process is as follows:
假设下面是一幅图像的灰度值矩阵:Suppose the following is the gray value matrix of an image:
灰度值f(3,1)=189,f(3,2)=156,f(3,3)=162通过模板滤波后Gray value f(3,1)=189, f(3,2)=156, f(3,3)=162 after template filtering
将边界1和边界2之间的区域点集转换为灰度值矩阵,按照上述方法对每一个像素点依次进行平滑滤波处理从而得到最终的平滑后的区域点集。The area point set between boundary 1 and boundary 2 is converted into a gray value matrix, and each pixel is sequentially smoothed and filtered according to the above method to obtain the final smoothed area point set.
本发明创造的方法利用腐蚀和膨胀的方法得到边界1和边界2,并且利用边界1和边界2得到区域点集,该区域点集反映出整个对象点集的轮廓信息,对该区域点集进行平滑滤波处理,可以消除图片上的对象与对象之间、对象与背景之间的块效应,提高图片的整体质量。The method created by the present invention utilizes the method of erosion and expansion to obtain boundary 1 and boundary 2, and utilizes boundary 1 and boundary 2 to obtain an area point set, which reflects the outline information of the entire object point set, and performs a process on the area point set Smoothing filter processing can eliminate block effects between objects on the picture and between objects and the background, and improve the overall quality of the picture.
以上对本发明的较佳实施方式进行了具体说明,但本发明创造并不限于所述实施例,熟悉本领域的技术人员在不违背本发明精神的前提下还可做出种种的等同变型或替换,这些等同的变型或替换均包含在本申请权利要求所限定的范围内。The preferred embodiments of the present invention have been described in detail above, but the invention is not limited to the described embodiments, and those skilled in the art can also make various equivalent modifications or replacements without violating the spirit of the present invention. , these equivalent modifications or replacements are all included within the scope defined by the claims of the present application.
Claims (5)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710508010.XA CN107230194A (en) | 2017-06-28 | 2017-06-28 | A kind of smooth filtering method based on object point set |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710508010.XA CN107230194A (en) | 2017-06-28 | 2017-06-28 | A kind of smooth filtering method based on object point set |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107230194A true CN107230194A (en) | 2017-10-03 |
Family
ID=59935394
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710508010.XA Pending CN107230194A (en) | 2017-06-28 | 2017-06-28 | A kind of smooth filtering method based on object point set |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107230194A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111161275A (en) * | 2018-11-08 | 2020-05-15 | 腾讯科技(深圳)有限公司 | Method and device for segmenting target object in medical image and electronic equipment |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
TW200742448A (en) * | 2006-04-26 | 2007-11-01 | Quanta Comp Inc | Image processing apparatus and method of the same |
CN104835127A (en) * | 2015-05-19 | 2015-08-12 | 中国农业科学院农业信息研究所 | Adaptive smooth filtering method |
CN105787911A (en) * | 2016-03-21 | 2016-07-20 | 中国林业科学研究院资源信息研究所 | Image erosion and expansion processing method based on topology fractal algorithm |
CN105825482A (en) * | 2016-03-15 | 2016-08-03 | 四川用联信息技术有限公司 | Depth image restoration algorithm |
CN106485673A (en) * | 2016-09-19 | 2017-03-08 | 电子科技大学 | A kind of filtering method to sea SAR image |
CN106813569A (en) * | 2015-11-30 | 2017-06-09 | 中国科学院沈阳自动化研究所 | A kind of automobile tire 3-D positioning method based on line-structured light |
-
2017
- 2017-06-28 CN CN201710508010.XA patent/CN107230194A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
TW200742448A (en) * | 2006-04-26 | 2007-11-01 | Quanta Comp Inc | Image processing apparatus and method of the same |
CN104835127A (en) * | 2015-05-19 | 2015-08-12 | 中国农业科学院农业信息研究所 | Adaptive smooth filtering method |
CN106813569A (en) * | 2015-11-30 | 2017-06-09 | 中国科学院沈阳自动化研究所 | A kind of automobile tire 3-D positioning method based on line-structured light |
CN105825482A (en) * | 2016-03-15 | 2016-08-03 | 四川用联信息技术有限公司 | Depth image restoration algorithm |
CN105787911A (en) * | 2016-03-21 | 2016-07-20 | 中国林业科学研究院资源信息研究所 | Image erosion and expansion processing method based on topology fractal algorithm |
CN106485673A (en) * | 2016-09-19 | 2017-03-08 | 电子科技大学 | A kind of filtering method to sea SAR image |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111161275A (en) * | 2018-11-08 | 2020-05-15 | 腾讯科技(深圳)有限公司 | Method and device for segmenting target object in medical image and electronic equipment |
CN111161275B (en) * | 2018-11-08 | 2022-12-23 | 腾讯科技(深圳)有限公司 | Method and device for segmenting target object in medical image and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN106530237B (en) | A kind of image enchancing method | |
CN110751655B (en) | An automatic mapping method based on semantic segmentation and saliency analysis | |
WO2020107866A1 (en) | Text region obtaining method and apparatus, storage medium and terminal device | |
CN102800094A (en) | Fast color image segmentation method | |
CN106203433A (en) | In a kind of vehicle monitoring image, car plate position automatically extracts and the method for perspective correction | |
CN107808381A (en) | A kind of unicellular image partition method | |
CN107506765B (en) | License plate inclination correction method based on neural network | |
CN107292842A (en) | The image deblurring method suppressed based on prior-constrained and outlier | |
CN109544583B (en) | Method, device and equipment for extracting interested area of leather image | |
CN106504294A (en) | RGBD image vector methods based on diffusion profile | |
CN106447673A (en) | Chip pin extraction method under non-uniform illumination condition | |
CN110599509A (en) | Edge detection method based on eight-direction fractional order differential operator | |
CN110458843A (en) | Mask image segmentation method and system | |
CN111784610A (en) | A clustering-based edge window filter optimization method | |
CN107230194A (en) | A kind of smooth filtering method based on object point set | |
CN105894475B (en) | A kind of International Phonetic Symbols image character thinning method | |
CN108717699B (en) | Ultrasonic image segmentation method based on continuous minimum segmentation | |
CN107527354A (en) | A kind of region growing method based on composite diagram | |
CN108734180A (en) | A kind of SIFT feature gradient generation method based on calculation optimization | |
CN107133965A (en) | One kind is based on computer graphic image morphological image segmentation method | |
CN109242891B (en) | An Image Registration Method Based on Improved Optical Flow Model | |
CN106127674A (en) | Image white balance method based on LBP | |
CN107492073B (en) | Digital image restoration method based on weight guide filtering | |
CN112651936B (en) | Method and system for image segmentation of steel plate surface defects based on image local entropy | |
CN110264417A (en) | The automatic Detection and Extraction method in local motion blur region based on hierarchical mode |
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 |
Application publication date: 20171003 |
|
RJ01 | Rejection of invention patent application after publication |