CN106503712A - One kind is based on stroke density feature character recognition method - Google Patents
One kind is based on stroke density feature character recognition method Download PDFInfo
- Publication number
- CN106503712A CN106503712A CN201611008154.0A CN201611008154A CN106503712A CN 106503712 A CN106503712 A CN 106503712A CN 201611008154 A CN201611008154 A CN 201611008154A CN 106503712 A CN106503712 A CN 106503712A
- Authority
- CN
- China
- Prior art keywords
- image
- word
- character recognition
- text
- recognition method
- 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 OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V20/00—Scenes; Scene-specific elements
- G06V20/60—Type of objects
- G06V20/62—Text, e.g. of license plates, overlay texts or captions on TV images
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/20—Image preprocessing
- G06V10/24—Aligning, centring, orientation detection or correction of the image
- G06V10/243—Aligning, centring, orientation detection or correction of the image by compensating for image skew or non-uniform image deformations
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/10—Character recognition
- G06V30/14—Image acquisition
- G06V30/148—Segmentation of character regions
- G06V30/153—Segmentation of character regions using recognition of characters or words
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V30/00—Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
- G06V30/10—Character recognition
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Multimedia (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Character Input (AREA)
Abstract
Description
【技术领域】【Technical field】
本发明涉及图像识别技术领域,尤其是涉及一种计算机故障检测系统及方法一种基于笔划密度特征文字识别方法。The invention relates to the technical field of image recognition, in particular to a computer fault detection system and method, and a character recognition method based on stroke density features.
【背景技术】【Background technique】
随着数码相机、摄像头、超高速扫描仪等图像获取设备的广泛应用,图像中信息越来越引起人们的关注。其中嵌入在图像中的文字是图像语义内容的一种重要表达方式,能够提供一些人们所需要的重要信息。例如图像中的文字可以是该图像的内容概述,如果能够自动提取和识别图像中的文字,就可以让计算机自动理解图像内容。让计算机像人类一样识别图像中的文字,对于图像和视频的存储、分类、理解及检索等来说具有极其重要的意义,它主要应用在中文信息处理、办公室自动化、及其翻译、人工智能等高技术领域,有着广泛的应用前景和商业价值。目前对图像中的文字一般只是通过简单的图像分割处理来进行识别,无法根据图像中的文字特征来进行自适应调节,导致现有的图像文字识别方法精度较低,无法满足实际应用的需求。With the widespread application of image acquisition equipment such as digital cameras, video cameras, and ultra-high-speed scanners, information in images has attracted more and more attention. The text embedded in the image is an important way of expressing the semantic content of the image, which can provide some important information that people need. For example, the text in an image can be an overview of the content of the image. If the text in the image can be automatically extracted and recognized, the computer can automatically understand the content of the image. Let the computer recognize the text in the image like a human being, which is of great significance for the storage, classification, understanding and retrieval of images and videos. It is mainly used in Chinese information processing, office automation, and its translation, artificial intelligence, etc. In the high-tech field, it has broad application prospects and commercial value. At present, the text in the image is generally only recognized through simple image segmentation processing, and cannot be adaptively adjusted according to the text features in the image, resulting in the low accuracy of the existing image text recognition method, which cannot meet the needs of practical applications.
【发明内容】【Content of invention】
鉴于以上内容,有必要提供一种计算机故障检测系统及方法一种基于笔划密度特征文字识别方法,目的在于解决现有的图像文字识别方法对文字的识别精度较低的技术问题。In view of the above, it is necessary to provide a computer fault detection system and method, a text recognition method based on stroke density features, and the purpose is to solve the technical problem that the existing image text recognition methods have low recognition accuracy for text.
本发明的目的通过以下技术方案实现:The object of the present invention is achieved through the following technical solutions:
一种基于笔划密度特征文字识别方法,包括以下步骤:A character recognition method based on stroke density features, comprising the following steps:
获取待识别图像;Obtain the image to be recognized;
对已获取图像预处理:图像倾斜校正以校正图像和阈值化处理获得前景信息及背景信息单一的图像;Preprocessing of the acquired image: image tilt correction to correct the image and thresholding to obtain an image with single foreground information and background information;
分析处理图像:分析图像的行间纹理特征,获取图像的文字矩阵参数;Analyze and process images: analyze the interline texture features of the image, and obtain the text matrix parameters of the image;
分割图像:基于所述文字矩阵参数对图像进行切割,形成若干个子图像,获取图像的文字字块;Segmenting the image: cutting the image based on the text matrix parameters to form several sub-images, and obtaining text blocks of the image;
识别:对文字字块进行单独处理,获取文字字块的图像特征,并对所述图像特征进行识别;所述图像特征获取方法为:计算出文字字块边框,在加框的文字字块p×q点阵中,分别向水平、垂直、45度和135度方向投影,每个方向取n个值作为特征,形成4n维特征向量。Recognition: process the text block separately, obtain the image feature of the text block, and identify the image feature; the image feature acquisition method is: calculate the text block frame, and add the framed text block p In the ×q lattice, project to the horizontal, vertical, 45-degree and 135-degree directions respectively, and each direction takes n values as features to form a 4n-dimensional feature vector.
进一步的,所述对已获取图像预处理还包括对已识别图像进行图像降噪以提升识别处理的精确度。Further, the preprocessing of the acquired image also includes performing image noise reduction on the recognized image to improve the accuracy of the recognition process.
进一步的,所述图像降噪处理可以采用小波去噪法、形态学噪声滤除器法、中值滤波器法、自适应维纳滤波器法及均值滤波器法等方法。Further, the image denoising process may adopt methods such as wavelet denoising method, morphological noise filter method, median filter method, adaptive Wiener filter method and mean filter method.
进一步的,所述阈值化处理包括固定阈值化方法、自适应阈值化方法、大津法或迭代法。Further, the thresholding process includes a fixed thresholding method, an adaptive thresholding method, an Otsu method or an iterative method.
进一步的,将图像矩阵中图像分为将图像的矩阵坐标中的字体用第一像素值表示,背景用第二像素值表示,统计图像的矩阵坐标中每行第二像素值的个数,获取一数组;统计对若干行高参数,参数取平均值统计,获取字体大小参数。Further, the image in the image matrix is divided into the font in the matrix coordinates of the image is represented by the first pixel value, and the background is represented by the second pixel value, and the number of the second pixel value of each row in the matrix coordinates of the image is counted to obtain An array; count several line height parameters, take the average value of the parameters, and obtain the font size parameters.
进一步的,所述识别基于预设的聚类算法对切分后的文字子块进行图像分割处理,获取文字字块中的文字信息,并根据所述文字信息在预置的系统文字库中进行比对,根据比对结构确定图像中的文字。Further, the recognition is based on a preset clustering algorithm to perform image segmentation processing on the segmented text sub-blocks, obtain the text information in the text block, and perform the recognition in the preset system text library according to the text information. Compare, determine the text in the image according to the comparison structure.
进一步的,所述分析处理图像还包括对文字字块进行膨胀处理。Further, the analyzing and processing the image also includes performing dilation processing on the text block.
进一步的,所述识别步骤包括所提取文字字块进行归一化处理后再进行识别。Further, the identifying step includes performing normalization processing on the extracted text blocks before identifying them.
本发明有益效果:本发明通过识别图像的矩阵行高纹理特征进行分析,计算出图像文字的矩阵参数,再基于文字相关的矩阵参数估算出文字字体大小参数,然后在对每一个文字快进行分割,并对文字子块进行识别,提高了切分文字子块的准确性,从而提高文字识别的精度。Beneficial effects of the present invention: the present invention analyzes the matrix row height texture feature of the image, calculates the matrix parameters of the image text, and then estimates the text font size parameter based on the text-related matrix parameters, and then quickly divides each text , and identify the text sub-blocks, which improves the accuracy of segmenting the text sub-blocks, thereby improving the accuracy of text recognition.
【具体实施方式】【detailed description】
一种基于笔划密度特征文字识别方法,其特征在于,包括以下步骤:A character recognition method based on stroke density features, characterized in that, comprising the following steps:
获取待识别图像;待识别图像可以是任何需要进行文字识别的图像,待识别图像可以来自外部设备。待识别图像可以是原始图像,也可以是对原始图像进行预处理后得到的图像,待识别的图像可以是jpg、bmp、png等图像格式。Obtain the image to be recognized; the image to be recognized can be any image that requires text recognition, and the image to be recognized can come from an external device. The image to be recognized may be an original image, or an image obtained by preprocessing the original image, and the image to be recognized may be in image formats such as jpg, bmp, png, etc.
对已获取图像预处理,包括阈值化处理、阈值化处理和倾斜校正。阈值化处理:所述阈值化处理包括固定阈值化方法、自适应阈值化方法、大津法或迭代法。图像的阈值化有利于图像的进一步处理,获得前景信息及背景信息单一的图像,使图像变得简单,而且数据量减小,能凸显出感兴趣的目标的轮廓。阈值化处理:由于待识别图像的品质受限于输入设备、环境、以及文档的印刷质量,在对图像中印刷体字符进行识别处理前,需要根据噪声的特征对待识别图像进行去噪处理,提升识别处理的精确度,图像降噪处理可以采用小波去噪法、形态学噪声滤除器法、中值滤波器法、自适应维纳滤波器法及均值滤波器法等方法。倾斜校正:由于扫描和拍摄过程涉及人工操作,输入计算机的待识别图像或多或少都会存在一些倾斜,在对图像中印刷体字符进行识别处理前,就需要进行图像方向检测,并校正图像方向。Preprocessing of acquired images, including thresholding, thresholding, and skew correction. Thresholding: the thresholding includes a fixed thresholding method, an adaptive thresholding method, an Otsu method or an iterative method. The thresholding of the image is conducive to the further processing of the image, and the image with single foreground information and background information is obtained, which makes the image simple, and the amount of data is reduced, and the outline of the target of interest can be highlighted. Thresholding processing: Since the quality of the image to be recognized is limited by the input device, the environment, and the printing quality of the document, before the printed characters in the image are recognized, it is necessary to denoise the image to be recognized according to the characteristics of the noise to improve The accuracy of recognition processing, image noise reduction processing can use wavelet denoising method, morphological noise filter method, median filter method, adaptive Wiener filter method and mean filter method and other methods. Tilt correction: Since the scanning and shooting process involves manual operations, the image to be recognized input into the computer will have some tilt more or less. Before the printed characters in the image are recognized and processed, it is necessary to detect the image orientation and correct the image orientation .
分析处理图像,分析图像的行间纹理特征,获取图像的文字矩阵参数;将图像矩阵中图像分为将图像的矩阵坐标中的字体用第一像素值表示,背景用第二像素值表示,统计图像的矩阵坐标中每行第二像素值的个数,获取一数组;统计对若干行高参数,参数取平均值统计,获取字体大小参数。Analyze and process the image, analyze the interline texture features of the image, and obtain the text matrix parameters of the image; divide the image in the image matrix into the first pixel value for the font in the image matrix coordinates, and the second pixel value for the background, and count Obtain an array of the number of second pixel values in each row in the matrix coordinates of the image; count several row height parameters, average the parameters and obtain font size parameters.
分割图像:基于所述文字矩阵参数对图像进行切割,形成若干个子图像,获取图像的文字字块;在进行图像切割前还包括对图像中文字区域中的文字进行判断排列方向,可以对文字字块逐行逐列扫描像素,得到文字字块中文字的行间距和列间距,并计算文字行的高度方差及文字列的宽度方差。该文字行的高度方差用于反映文字行高度的一致性,而该文字列的宽度方差用于反映文字列宽度的一致性。然后综合该文字间距和文字行的高度或文字列的宽度的一致性等因素来判断该文字是横向排列还是纵向排列。例如,若行间距大于列间距,并且文字行高度一致,则判定文字区域中文字是横向排列。若列间距大于行间距,并且文字列宽度一致,则判定文字区域中文字是纵向排列。对文字字块的切分结果进行修正,例如包括将错误切分后的文字行或列合并,或对英文首字母与第二字母的错误切分进行修正Segmenting the image: cutting the image based on the text matrix parameters to form several sub-images, and obtaining the text block of the image; before cutting the image, it also includes judging the arrangement direction of the text in the text area in the image, and the text text can be The block scans the pixels row by row and column by row to obtain the row spacing and column spacing of the text in the text block, and calculate the height variance of the text row and the width variance of the text column. The variance of the height of the text row is used to reflect the consistency of the height of the text row, and the variance of the width of the text column is used to reflect the consistency of the width of the text row. Then, it is judged whether the characters are arranged horizontally or vertically based on factors such as the consistency between the character spacing and the height of the character row or the width of the character column. For example, if the line spacing is greater than the column spacing, and the text row heights are the same, it is determined that the text in the text area is arranged horizontally. If the column spacing is greater than the row spacing, and the width of the text columns is the same, it is determined that the text in the text area is arranged vertically. Correct the segmentation results of text blocks, such as merging incorrectly segmented text rows or columns, or correcting the incorrect segmentation of the first letter and the second letter of the English language
识别:对文字字块进行单独处理,获取文字字块的图像特征,并对所述图像特征进行识别;使用经过版面分析及单字切分操作后的该文字字块从文字区域中提取文字之前,还可以对该文字字块进行膨胀处理,然后使用该文字字块保留文字边缘梯度,去除局部背景梯度的干扰,从而从该文字区域中将每一个文字提取出来,并对所提取文字进行归一化处理,即将所有文字缩放到统一大小,最后提取每个文字的特征进行识别。所述图像特征获取方法为:计算出文字字块边框,在加框的文字字块p×q点阵中,分别向水平、垂直、45度和135度方向投影,每个方向取n个值作为特征,形成4n维特征向量。Recognition: process the text block separately, obtain the image features of the text block, and identify the image features; use the text block after the layout analysis and single character segmentation operation to extract the text from the text area, It is also possible to expand the text block, and then use the text block to retain the text edge gradient and remove the interference of the local background gradient, thereby extracting each text from the text area and normalizing the extracted text The processing is to scale all the characters to a uniform size, and finally extract the features of each character for recognition. The image feature acquisition method is as follows: calculate the frame of the text block, and project it in the horizontal, vertical, 45 degree and 135 degree directions respectively in the framed text block p×q dot matrix, and take n values in each direction As features, a 4n-dimensional feature vector is formed.
上所述,仅是本发明的较佳实施例而已,并非对本发明作任何形式上的限制,虽然本发明已以较佳实施例揭示如上,然而并非用以限定本发明,任何本领域技术人员,在不脱离本发明技术方案范围内,当可利用上述揭示的技术内容做出些许更动或修饰为等同变化的等效实施例,但凡是未脱离本发明技术方案内容,依据本发明的技术实质对以上实施例所作的任何简介修改、等同变化与修饰,均仍属于本发明技术方案的范围。The above is only a preferred embodiment of the present invention, and does not limit the present invention in any form. Although the present invention has been disclosed as above with preferred embodiments, it is not intended to limit the present invention. Anyone skilled in the art , without departing from the scope of the technical solution of the present invention, when the technical content disclosed above can be used to make some changes or be modified into equivalent embodiments with equivalent changes, but as long as it does not depart from the technical solution of the present invention, the technical content of the present invention In essence, any modifications, equivalent changes and modifications made to the above embodiments still belong to the scope of the technical solution of the present invention.
Claims (8)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201611008154.0A CN106503712A (en) | 2016-11-16 | 2016-11-16 | One kind is based on stroke density feature character recognition method |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201611008154.0A CN106503712A (en) | 2016-11-16 | 2016-11-16 | One kind is based on stroke density feature character recognition method |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN106503712A true CN106503712A (en) | 2017-03-15 |
Family
ID=58324746
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201611008154.0A Pending CN106503712A (en) | 2016-11-16 | 2016-11-16 | One kind is based on stroke density feature character recognition method |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN106503712A (en) |
Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101038626A (en) * | 2007-04-25 | 2007-09-19 | 上海大学 | Method and device for recognizing test paper score |
| CN103902981A (en) * | 2014-04-02 | 2014-07-02 | 浙江师范大学 | Method and system for identifying license plate characters based on character fusion features |
| CN104050450A (en) * | 2014-06-16 | 2014-09-17 | 西安通瑞新材料开发有限公司 | Vehicle license plate recognition method based on video |
| CN104298982A (en) * | 2013-07-16 | 2015-01-21 | 深圳市腾讯计算机系统有限公司 | Text recognition method and device |
| CN105631486A (en) * | 2014-10-27 | 2016-06-01 | 深圳Tcl数字技术有限公司 | image character recognition method and device |
-
2016
- 2016-11-16 CN CN201611008154.0A patent/CN106503712A/en active Pending
Patent Citations (5)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN101038626A (en) * | 2007-04-25 | 2007-09-19 | 上海大学 | Method and device for recognizing test paper score |
| CN104298982A (en) * | 2013-07-16 | 2015-01-21 | 深圳市腾讯计算机系统有限公司 | Text recognition method and device |
| CN103902981A (en) * | 2014-04-02 | 2014-07-02 | 浙江师范大学 | Method and system for identifying license plate characters based on character fusion features |
| CN104050450A (en) * | 2014-06-16 | 2014-09-17 | 西安通瑞新材料开发有限公司 | Vehicle license plate recognition method based on video |
| CN105631486A (en) * | 2014-10-27 | 2016-06-01 | 深圳Tcl数字技术有限公司 | image character recognition method and device |
Non-Patent Citations (1)
| Title |
|---|
| 宁博: "手写体汉字识别实验平台及笔划网格特征提取方法的研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》 * |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN106503711A (en) | A kind of character recognition method | |
| CN108171104B (en) | Character detection method and device | |
| CN110033471B (en) | Frame line detection method based on connected domain analysis and morphological operation | |
| CN103258198B (en) | Character extracting method in a kind of form document image | |
| Sharma et al. | Recent advances in video based document processing: a review | |
| WO2019072233A1 (en) | Text line detection method and text line detection apparatus | |
| CN110335233B (en) | Highway guardrail plate defect detection system and method based on image processing technology | |
| CN113139535A (en) | OCR document recognition method | |
| CN103488986B (en) | Self-adaptation character cutting and extracting method | |
| CN106778752A (en) | A kind of character recognition method | |
| CN107085726A (en) | Single character location method in oracle bone rubbings based on multi-method denoising and connected region analysis | |
| CN112364862B (en) | Histogram similarity-based disturbance deformation Chinese character picture matching method | |
| CN114494318B (en) | A method for extracting corneal contour from corneal dynamic deformation video based on Otsu algorithm | |
| CN113642380A (en) | Identification technology for wireless form | |
| WO2022121021A1 (en) | Identity card number detection method and apparatus, and readable storage medium and terminal | |
| CN102136074B (en) | Man-machine interface (MMI) based wood image texture analyzing and identifying method | |
| JP2006067585A (en) | Method and apparatus for locating and extracting captions in digital images | |
| Moradi et al. | Farsi/Arabic text extraction from video images by corner detection | |
| Gui et al. | A fast caption detection method for low quality video images | |
| CN115588208A (en) | A recognition method of full-line table structure based on digital image processing technology | |
| CN117291208B (en) | Two-dimensional code extraction method and system | |
| CN106503713A (en) | One kind is based on thick periphery feature character recognition method | |
| CN110276260B (en) | A product detection method based on depth camera | |
| Liu et al. | Detection and segmentation text from natural scene images based on graph model | |
| CN116563170A (en) | Image data processing method, system and electronic device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| C06 | Publication | ||
| PB01 | Publication | ||
| SE01 | Entry into force of request for substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| WD01 | Invention patent application deemed withdrawn after publication | ||
| WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20170315 |