CN104951782A - Background filtering method and system for image recognition - Google Patents
Background filtering method and system for image recognition Download PDFInfo
- Publication number
- CN104951782A CN104951782A CN201510378547.XA CN201510378547A CN104951782A CN 104951782 A CN104951782 A CN 104951782A CN 201510378547 A CN201510378547 A CN 201510378547A CN 104951782 A CN104951782 A CN 104951782A
- Authority
- CN
- China
- Prior art keywords
- gray
- image
- scale value
- original image
- threshold value
- 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
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/20—Image preprocessing
- G06V10/28—Quantising the image, e.g. histogram thresholding for discrimination between background and foreground patterns
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Theoretical Computer Science (AREA)
- Image Analysis (AREA)
- Image Processing (AREA)
Abstract
The invention discloses a background filtering method and system for image recognition. The background filtering method comprises the following steps: step 1, acquiring an original image, and adopting the Laplace operator to filter the original image to obtain a filtered image; step 2, performing binarization processing on the original image and the filtered image respectively; step 3, stacking the original image and the filtered image after binarization processing to obtain a to-be-recognized image. The background filtering method and system for image recognition can distinguish foreground and background in the images clearly and are particularly applicable to complex images, so that the image recognition accuracy can be improved, and the image recognition success rate can be increased.
Description
Technical field
The present invention relates to image recognition technology, particularly relate to a kind of filtering background method and system of image recognition.
Background technology
Image recognition is a key areas of artificial intelligence.In order to work out the computer program of simulating human image recognition activity, there has been proposed different image recognition models.Image recognition experienced by the development of three phases: Text region, Digital Image Processing and identification, object identification.The research of Text region, from nineteen fifty, is generally identification letter, and numbers and symbols, recognizes handwriting identification from printing word, and application widely.
Along with smart mobile phone rises, the behavior of mobile-phone payment is more and more universal, and wherein image recognition technology obtains as one of gordian technique and applies more widely.But when user inputs bank card number on mobile phone, speed is very slow, and need careful check and correction, Consumer's Experience is very poor.
During current prospect background in image recognition is distinguished, the more of utilization is binarization method, but existing binarization method is difficult to get appropriate threshold under image background comparatively complicated situation.Thus, in the urgent need to a kind of can the algorithm of better distinguish prospect background.
Summary of the invention
The technical problem to be solved in the present invention is to overcome filtering background difficulty in image recognition of the prior art, when complicated image, be difficult to prospect background to distinguish clear, and then limit the accuracy of image recognition and the defect of success ratio, a kind of filtering background method and system of image recognition are provided.
The present invention solves above-mentioned technical matters by following technical proposals:
A filtering background method for image recognition, its feature is, comprises the following steps:
Step one, acquisition original image, use Laplace operator to obtain filtered image to after original image filtering;
Step 2, respectively binary conversion treatment is carried out to original image and filtered image;
Step 3, by the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Preferably, the Laplace operator of step one is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8;
In formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
Preferably, step 3 comprises the following steps:
Pixel (x, y) for coordinate points each in original image judges that whether its gray-scale value f (x, y) is higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment;
For the pixel (x of coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment;
By the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Those skilled in the art are to be understood that, (the x occurred in present specification, y), (i, j) be all coordinate points for representing in image, and (i, j+2), (i-1, j) is then for representing that position relative to coordinate points (i, j) is moved the coordinate points of 2 pixels towards longitudinal axis augment direction and reduces direction towards transverse axis and move the coordinate points of 1 pixel.
Preferably, this first gray-scale value threshold value and this second gray-scale value threshold value adopt kitty algorithm or OTSU algorithm to calculate.
Preferably, this first gray-scale value threshold value and this second gray-scale value threshold value adopt 2/3 of the maximin of the gray-scale value of original image respectively.
Present invention also offers a kind of filtering background system of image recognition, its feature is, comprising:
One filtration module, for obtaining original image, uses Laplace operator to obtain filtered image to after original image filtering;
One binary conversion treatment module, for carrying out binary conversion treatment to original image and filtered image respectively;
One imaging importing module, for by the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Preferably, the Laplace operator adopted in this filtration module is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8;
In formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
Preferably, this imaging importing module comprises one first gray scale judging unit, one second gray scale judging unit and an image generation unit to be identified;
This first gray scale judging unit is used for the pixel (x for coordinate points each in original image, y) its gray-scale value f (x is judged, whether y) higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment;
This second gray scale judging unit is used for the pixel (x for coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment;
This image generation unit to be identified is used for the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Preferably, this first gray-scale value threshold value and this second gray-scale value threshold value adopt kitty algorithm or OTSU algorithm to calculate.
Preferably, this first gray-scale value threshold value and this second gray-scale value threshold value adopt 2/3 of the maximin of the gray-scale value of original image respectively.
On the basis meeting this area general knowledge, above-mentioned each optimum condition, can combination in any, obtains the preferred embodiments of the invention.
Positive progressive effect of the present invention is: the filtering background method and system of image recognition of the present invention, can distinguish clear by the prospect background in image, especially be applicable to complicated image, thus can improve accuracy and the success ratio of image recognition.
Accompanying drawing explanation
Fig. 1 is the process flow diagram of the embodiment of the present invention 1.
Embodiment
Mode below by embodiment further illustrates the present invention, but does not therefore limit the present invention among described scope of embodiments.
Embodiment 1
As shown in Figure 1, the filtering background method of the image recognition of the present embodiment, comprises the following steps:
Step one, acquisition original image, use Laplace operator to obtain filtered image to after original image filtering;
Step 2, respectively binary conversion treatment is carried out to original image and filtered image;
Step 3, by the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Wherein, the Laplace operator of step one is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8;
In formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
Step 3 comprises the following steps specifically:
Pixel (x, y) for coordinate points each in original image judges that whether its gray-scale value f (x, y) is higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment;
For the pixel (x of coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment;
By the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Wherein, this first gray-scale value threshold value and this second gray-scale value threshold value adopt OTSU algorithm to calculate.
Embodiment 2
The filtering background system of the image recognition of the present embodiment comprises a filtration module, a binary conversion treatment module and an imaging importing module.This imaging importing module comprises one first gray scale judging unit, one second gray scale judging unit and an image generation unit to be identified.
This filtration module, for obtaining original image, uses Laplace operator to obtain filtered image to after original image filtering.The Laplace operator adopted in this filtration module is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8。
In above formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
This binary conversion treatment module is used for carrying out binary conversion treatment to original image and filtered image respectively.
This first gray scale judging unit is used for the pixel (x for coordinate points each in original image, y) its gray-scale value f (x is judged, whether y) higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment.This second gray scale judging unit is used for the pixel (x for coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment.This image generation unit to be identified is used for the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
Wherein, this first gray-scale value threshold value and this second gray-scale value threshold value adopt 2/3 of the maximin of the gray-scale value of original image respectively.
Although the foregoing describe the specific embodiment of the present invention, it will be understood by those of skill in the art that these only illustrate, protection scope of the present invention is defined by the appended claims.Those skilled in the art, under the prerequisite not deviating from principle of the present invention and essence, can make various changes or modifications to these embodiments, but these change and amendment all falls into protection scope of the present invention.
Claims (10)
1. a filtering background method for image recognition, is characterized in that, comprise the following steps:
Step one, acquisition original image, use Laplace operator to obtain filtered image to after original image filtering;
Step 2, respectively binary conversion treatment is carried out to original image and filtered image;
Step 3, by the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
2. filtering background method as claimed in claim 1, it is characterized in that, the Laplace operator of step one is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8;
In formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
3. filtering background method as claimed in claim 1, it is characterized in that, step 3 comprises the following steps:
Pixel (x, y) for coordinate points each in original image judges that whether its gray-scale value f (x, y) is higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment;
For the pixel (x of coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment;
By the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
4. filtering background method as claimed in claim 3, is characterized in that, this first gray-scale value threshold value and this second gray-scale value threshold value adopt kitty algorithm or OTSU algorithm to calculate.
5. filtering background method as claimed in claim 3, is characterized in that, this first gray-scale value threshold value and this second gray-scale value threshold value adopt 2/3 of the maximin of the gray-scale value of original image respectively.
6. a filtering background system for image recognition, is characterized in that, comprising:
One filtration module, for obtaining original image, uses Laplace operator to obtain filtered image to after original image filtering;
One binary conversion treatment module, for carrying out binary conversion treatment to original image and filtered image respectively;
One imaging importing module, for by the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
7. filtering background system as claimed in claim 6, it is characterized in that, the Laplace operator adopted in this filtration module is defined by following formula:
P(i,j)=[f(i-2,j)+f(i+2,j)+f(i,j-2)+f(i,j+2)+f(i-1,j)+f(i+1,j)+f(i,j-1)+f(i,j+1)–8×f(i,j)]/8;
In formula, f (i, j) represents that in original image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j), and P (i, j) represents that in filtered image, coordinate is the gray-scale value of the pixel of the coordinate points of (i, j).
8. filtering background system as claimed in claim 6, it is characterized in that, this imaging importing module comprises one first gray scale judging unit, one second gray scale judging unit and an image generation unit to be identified;
This first gray scale judging unit is used for the pixel (x for coordinate points each in original image, y) its gray-scale value f (x is judged, whether y) higher than one first gray-scale value threshold value, and the pixel retained higher than this first gray-scale value threshold value is using as the original image after binary conversion treatment;
This second gray scale judging unit is used for the pixel (x for coordinate points each in filtered image, y) its gray-scale value P (x is judged, whether y) higher than one second gray-scale value threshold value, and the pixel retained higher than this second gray-scale value threshold value is using as the filtered image after binary conversion treatment;
This image generation unit to be identified is used for the original image after binary conversion treatment and filtered image superposition, to obtain image to be identified.
9. filtering background system as claimed in claim 8, is characterized in that, this first gray-scale value threshold value and this second gray-scale value threshold value adopt kitty algorithm or OTSU algorithm to calculate.
10. filtering background system as claimed in claim 8, is characterized in that, this first gray-scale value threshold value and this second gray-scale value threshold value adopt 2/3 of the maximin of the gray-scale value of original image respectively.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510378547.XA CN104951782A (en) | 2015-07-01 | 2015-07-01 | Background filtering method and system for image recognition |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510378547.XA CN104951782A (en) | 2015-07-01 | 2015-07-01 | Background filtering method and system for image recognition |
Publications (1)
Publication Number | Publication Date |
---|---|
CN104951782A true CN104951782A (en) | 2015-09-30 |
Family
ID=54166423
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510378547.XA Pending CN104951782A (en) | 2015-07-01 | 2015-07-01 | Background filtering method and system for image recognition |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104951782A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107622481A (en) * | 2017-10-25 | 2018-01-23 | 沈阳东软医疗***有限公司 | Reduce the method, apparatus and computer equipment of CT picture noises |
CN109822564A (en) * | 2019-01-14 | 2019-05-31 | 巨轮(广州)机器人与智能制造有限公司 | A kind of construction method of vision system |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2003023571A2 (en) * | 2001-09-12 | 2003-03-20 | Burstein Technologies, Inc. | Methods for differential cell counts including related apparatus and software for performing same |
CN101794380A (en) * | 2010-02-11 | 2010-08-04 | 上海点佰趣信息科技有限公司 | Enhancement method of fingerprint image |
CN102063704A (en) * | 2010-11-19 | 2011-05-18 | 中国航空无线电电子研究所 | Airborne vision enhancement method and device |
CN102737246A (en) * | 2012-06-14 | 2012-10-17 | 公安部天津消防研究所 | Canny operator-based foam boundary recognition and grain size analysis method |
-
2015
- 2015-07-01 CN CN201510378547.XA patent/CN104951782A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2003023571A2 (en) * | 2001-09-12 | 2003-03-20 | Burstein Technologies, Inc. | Methods for differential cell counts including related apparatus and software for performing same |
CN101794380A (en) * | 2010-02-11 | 2010-08-04 | 上海点佰趣信息科技有限公司 | Enhancement method of fingerprint image |
CN102063704A (en) * | 2010-11-19 | 2011-05-18 | 中国航空无线电电子研究所 | Airborne vision enhancement method and device |
CN102737246A (en) * | 2012-06-14 | 2012-10-17 | 公安部天津消防研究所 | Canny operator-based foam boundary recognition and grain size analysis method |
Non-Patent Citations (4)
Title |
---|
NIKOLAOS MITIANOUDIS.ETC: "Local Co-occurrence and Contrast Mapping for Document Image Binarization", 《FRONTIERS IN HANDWRITING RECOGNITION (ICFHR)》 * |
吴涛: "《图像分割的认知物理学方法》", 30 April 2015, 中国水利水电出版社 * |
王福杰等: "苹果图像的背景分割与目标提取", 《苹果图像的背景分割与目标提取》 * |
陈天华: "《数字图像处理》", 30 September 2014, 清华大学出版社 * |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107622481A (en) * | 2017-10-25 | 2018-01-23 | 沈阳东软医疗***有限公司 | Reduce the method, apparatus and computer equipment of CT picture noises |
US10783614B2 (en) | 2017-10-25 | 2020-09-22 | Beijing Neusoft Medical Equipment Co., Ltd. | Denoising CT image |
CN107622481B (en) * | 2017-10-25 | 2022-09-30 | 东软医疗***股份有限公司 | Method and device for reducing CT image noise and computer equipment |
CN109822564A (en) * | 2019-01-14 | 2019-05-31 | 巨轮(广州)机器人与智能制造有限公司 | A kind of construction method of vision system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108010031B (en) | Portrait segmentation method and mobile terminal | |
CN104252620B (en) | The graphical verification code recognition methods of Characters Stuck | |
US9239948B2 (en) | Feature descriptor for robust facial expression recognition | |
CN108108731B (en) | Text detection method and device based on synthetic data | |
CN103514459A (en) | Method and system for identifying crop diseases and pests based on Android mobile phone platform | |
CN105631449B (en) | A kind of picture segmentation method, device and equipment | |
CN107909571A (en) | A kind of weld beam shape method, system, equipment and computer-readable storage medium | |
CN109447117B (en) | Double-layer license plate recognition method and device, computer equipment and storage medium | |
CN105023256A (en) | Image defogging method and system | |
CN106504225A (en) | A kind of recognition methodss of regular polygon and device | |
CN108009536A (en) | Scan method to go over files and system | |
BJ et al. | Ancient horoscopic palm leaf binarization using A deep binarization model-RESNET | |
CN104050472B (en) | A kind of adaptive global threshold method of Binary Sketch of Grey Scale Image | |
CN113706464A (en) | Printed matter appearance quality detection method and system | |
CN102663706A (en) | Adaptive weighted mean value filtering method based on diamond template | |
CN108921111A (en) | Object detection post-processing approach and corresponding intrument | |
CN110782385A (en) | Image watermark removing method based on deep learning | |
CN101908205A (en) | Magic square coding-based median filter method | |
CN106384071A (en) | Two-dimensional code scanning recognition processing method and device | |
CN104951782A (en) | Background filtering method and system for image recognition | |
CN107886093B (en) | Character detection method, system, equipment and computer storage medium | |
CN105989377A (en) | Character identification method and apparatus | |
CN103500323A (en) | Template matching method based on self-adaptive gray-scale image filtering | |
CN109299743B (en) | Gesture recognition method and device and terminal | |
CN114626118A (en) | Building indoor model generation 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 | ||
C41 | Transfer of patent application or patent right or utility model | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20160302 Address after: 200335 Shanghai city Changning District Admiralty Road No. 968 Building No. 16 10 floor Applicant after: SHANGHAI XIECHENG BUSINESS CO., LTD. Address before: 200335 Shanghai City, Changning District Fuquan Road No. 99, Ctrip network technology building Applicant before: Ctrip computer technology (Shanghai) Co., Ltd. |
|
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20150930 |