CN110427948A - The generation method and its system of character sample - Google Patents

The generation method and its system of character sample Download PDF

Info

Publication number
CN110427948A
CN110427948A CN201910691368.XA CN201910691368A CN110427948A CN 110427948 A CN110427948 A CN 110427948A CN 201910691368 A CN201910691368 A CN 201910691368A CN 110427948 A CN110427948 A CN 110427948A
Authority
CN
China
Prior art keywords
character
image
style
targets
sample
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
Application number
CN201910691368.XA
Other languages
Chinese (zh)
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.)
Hangzhou Yunshen Hongshi Intelligent Technology Co Ltd
Original Assignee
Hangzhou Yunshen Hongshi Intelligent Technology 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 Hangzhou Yunshen Hongshi Intelligent Technology Co Ltd filed Critical Hangzhou Yunshen Hongshi Intelligent Technology Co Ltd
Priority to CN201910691368.XA priority Critical patent/CN110427948A/en
Publication of CN110427948A publication Critical patent/CN110427948A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/40Extraction of image or video features
    • G06V10/46Descriptors for shape, contour or point-related descriptors, e.g. scale invariant feature transform [SIFT] or bags of words [BoW]; Salient regional features
    • G06V10/462Salient features, e.g. scale invariant feature transforms [SIFT]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/14Image acquisition
    • G06V30/148Segmentation of character regions
    • G06V30/153Segmentation of character regions using recognition of characters or words

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • General Physics & Mathematics (AREA)
  • Data Mining & Analysis (AREA)
  • Multimedia (AREA)
  • Artificial Intelligence (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Evolutionary Biology (AREA)
  • Evolutionary Computation (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • Character Discrimination (AREA)

Abstract

This application involves character recognition fields, disclose the generation method and its system of a kind of character sample.The character targets image with natural lighting texture and default twist distortion feature is obtained according to character original image, character style image is generated by the migration of illumination texture according to the character original image and the character targets image, and the character sample image with the predetermined inclination distortion character is generated according to the character style image and the character targets image.Output character sample image not only realistic illumination texture but also had had preset torsional deformation feature in the application embodiment, it can obtain close to true and various character samples, escape character sample database, keep training sample more abundant, the problem of avoiding training pattern over-fitting simultaneously, improves character identification rate.

Description

The generation method and its system of character sample
Technical field
This application involves character recognition fields, the in particular to generation technique of character sample.
Background technique
Need to provide large-scale character sample data using the character identifying method of deep learning, and sample data is good It is bad to directly affect character identification rate, so establishing a closing to reality, abundant and representative character sample library is to carry out The premise and basis of character recognition research.
Summary of the invention
A kind of generation method and its system for being designed to provide character sample of the application, can obtain close to true and It is more abundant to make training sample, while avoiding training pattern over-fitting for various character samples, escape character sample database The problem of, improve character identification rate.
This application discloses a kind of generation methods of character sample, comprising:
The character targets image with natural lighting texture and default twist distortion feature is obtained according to character original image;
Character style image is generated by the migration of illumination texture according to the character original image and the character targets image;
Being generated according to the character style image and the character targets image has the predetermined inclination distortion character Character sample image.
In a preferred embodiment, described to obtain that there is predetermined inclination distortion character under natural lighting according to character original image Character targets image, further comprise:
The text conversion of text type is obtained into character original image for image by Unicode code;
The character original image is printed as paper document;
By the character on the paper document under the natural scene of shooting simulation, obtain with natural lighting texture and The character targets intermediate image of default twist distortion feature;
By the character targets intermediate image be set as with the same pixel of character original image, obtain character targets image.
In a preferred embodiment, described to be moved according to the character original image and the character targets image by illumination texture Innidiation further comprises at character style image:
It is character original image M content characteristic block of extraction by convolutional neural networks, and is the character targets figure Picture extracts K style and features block, wherein K > M > 1;
Most matched style and features block is determined using normalized crosscorrelation matching method for each content characteristic block;
Each content characteristic block and corresponding most matched style and features block are swapped;
Complete content images are rebuild according to the style and features block after the exchange, obtain the character style image.
In a preferred embodiment, the number of the M content characteristic block and the lap in the K style and features block It greater than preset threshold, and include all channels of correspondence image.
In a preferred embodiment, described to be generated according to the character style image and the character targets image with described The character sample image of predetermined inclination distortion character further comprises:
The character style image and the character targets image are subjected to SIFT feature matching, obtained based on two figures The N of picture is to characteristic point;
According to basic function U (r)=r2logr2And deformation functionIt will The coordinate points of the character style image characteristic point are deflected into the coordinate points of the character targets image characteristic point correspondingly On, wherein r is coordinate points (x, y) at a distance from Descartes's origin and Δ2U=0, DkIt is the coordinate of four datum marks, four bases A square is constituted on schedule;
Based on the deformation according to difference functions Φ1(A)=C+DTA+WTS (A) interpolation has provided the predetermined inclination distortion The character sample image of feature, wherein C is scalar, vector D ∈ R2×1, vector W ∈ RN×1, R is real number field, S (A)=(U (A- A1) ..., U (A-AN))T, Ai(i=1,2 ..., N) is the coordinate points of N number of characteristic point of the character style image.
A kind of generation system disclosed herein as well is character sample includes:
Acquisition module, for obtaining the word with natural lighting texture and default twist distortion feature according to character original image Accord with target image;
Processing module, for according to the character original image and the character targets image inputted from the acquisition module It is migrated by illumination texture and generates character style image, and is raw according to the character style image and the character targets image At the character sample image with the predetermined inclination distortion character.
In a preferred embodiment, the acquisition module be also used to be by the text conversion of text type by Unicode code Image obtains character original image, and character original image is printed as paper document, described under the natural scene of shooting simulation Character on paper document obtains the character targets intermediate image with natural lighting texture and default twist distortion feature, and The character targets intermediate image is set to obtain character targets image with pixel with the character original image;
In a preferred embodiment, the processing module is also used to through convolutional neural networks be character original image extraction M content characteristic block and be K style and features block of the character targets image zooming-out, wherein K > M > 1, for each content spy Levy block and most matched style and features block determined using normalized crosscorrelation matching method, by each content characteristic block and with Its corresponding most matched style and features block swaps, and is rebuild in complete according to the style and features block after the exchange Hold image, obtains the character style image.
A kind of generation system disclosed herein as well is character sample includes:
Memory, for storing computer executable instructions;And
Processor, for realizing the step in method as previously described when executing the computer executable instructions.
Disclosed herein as well is be stored with meter in computer readable storage medium described in a kind of computer readable storage medium Calculation machine executable instruction, the computer executable instructions realize the step in method as previously described when being executed by processor Suddenly.
Compared with the synthesis of existing character picture and transform method, in presently filed embodiment, acquires and have under natural lighting There is illumination texture and tilt the character picture of distortion character, is migrated, ultimately generated realistic by Style Transfer and deformation Illumination texture and the character sample with different inclinations and/or torsional deformation, so that character sample generated is more close to true The character of real illumination and true deformation makes to instruct to achieve the purpose that the various modifications character sample expanded under natural lighting environment The problem of it is more abundant to practice sample, while also avoiding training pattern over-fitting.
Further, the word of the different inclinations and distortion under natural lighting can be quickly and effectively generated in present embodiment Symbol sample has saved a large amount of artificial and time cost.
A large amount of technical characteristic is described in the description of the present application, is distributed in each technical solution, if to enumerate Out if the combination (i.e. technical solution) of all possible technical characteristic of the application, specification can be made excessively tediously long.In order to keep away Exempt from this problem, each technical characteristic disclosed in the application foregoing invention content, below in each embodiment and example Each technical characteristic disclosed in disclosed each technical characteristic and attached drawing, can freely be combined with each other, to constitute each The new technical solution (these technical solutions have been recorded because being considered as in the present specification) of kind, unless the group of this technical characteristic Conjunction is technically infeasible.For example, disclosing feature A+B+C in one example, spy is disclosed in another example A+B+D+E is levied, and feature C and D are the equivalent technologies means for playing phase same-action, it, can not as long as technically selecting a use Can use simultaneously, feature E can be technically combined with feature C, then, and the scheme of A+B+C+D because technology is infeasible should not It is considered as having recorded, and the scheme of A+B+C+E should be considered as being described.
Detailed description of the invention
Fig. 1 is the generation method flow diagram according to the character sample of the application first embodiment
Fig. 2 is the generation system structure diagram according to the character sample of the application second embodiment
Specific embodiment
In the following description, in order to make the reader understand this application better, many technical details are proposed.But this The those of ordinary skill in field is appreciated that even if without these technical details and many variations based on the following respective embodiments And modification, the application technical solution claimed also may be implemented.
Term is explained:
Unicode code: Unicode is a character set, and Unicode is the office in order to solve traditional character coding method Limit and generate, it is the unified and unique binary coding of each character setting in every kind of language, to meet across language Speech, the cross-platform requirement for carrying out text conversion, processing.Unicode coding indicates a character using two bytes, is one 16 coding modes of kind.Unicode code is extended from ASCII character set.
SIFT, i.e. Scale invariant features transform (Scale-invariant feature transform, SIFT) are to use In a kind of description of field of image processing.This description has scale invariability, can detect key point in the picture, is a kind of Local feature description's.
Sigmoid function is a common S type function in biology, also referred to as S sigmoid growth curve.In Information Center It, will since singly properties, the Sigmoid function such as increasing and the increasing of inverse function list are often used as the threshold function table of neural network for it in Variable mappings are between 0 and 1.
Implementation to keep the purposes, technical schemes and advantages of the application clearer, below in conjunction with attached drawing to the application Mode is described in further detail.
The method of existing escape character sample, which has, to be synthesized based on image or based on image transformation realization, is not able to satisfy base It is that background image and character picture are directly weighted synthesis in image synthetic method, generates symphysis character picture, it can Quick symphysis Chinese printable character image achievees the effect that expand Chinese print character sample to a certain extent, such as discloses It number is exactly to use this for the Chinese patent of CN107274345A entitled " a kind of Chinese printable character image composition method and device " Kind method, but the Chinese print character sample image synthesized by this method is not true enough.And the side based on image transformation Method is to obtain the numeric word of different rotary angle at random by the random digit between ± 8 ° of bianry image rotation using image rotation Image is accorded with, the random sample of a large amount of different scales can be generated, realizes the effect that sample expands, such as Publication No. The Chinese patent of CN106682629A entitled " a kind of complex background under identification card number recognizer " be exactly in this way, but It is to set in the numeral sample generated by this method there are different rotation angles, is not able to satisfy number training to sample-rich The requirement of degree.
Based on the above circumstances, the first embodiment of the application proposes a kind of generation method of character sample, process As shown in Figure 1, method includes the following steps:
Step 101 is initially entered, is obtained according to character original image with natural lighting texture and default twist distortion feature Character targets image.
Optionally, which further comprises the steps I), II), III) and IV), specifically include:
I) by Unicode code by the text conversion of text type be image obtain character original image;
II) the character original image is printed as paper document;
III) by the character on the paper document under the natural scene of shooting simulation, it obtains with natural lighting texture With the character targets intermediate image of default twist distortion feature;
IV) by the character targets intermediate image be set as with the same pixel of character original image, obtain character targets image.
Later, 102 are entered step, is generated according to the character original image and the character targets image by the migration of illumination texture Character style image.It should be noted that this step is adopted based on the character original image and character targets image in step 101 The character sample for generating realistic illumination texture can be simulated by textures synthesis with the method for Style Transfer, reaches expansion The effect of character sample under natural lighting environment has saved a large amount of artificial and time cost.
Optionally, which further comprises the steps I '), II '), III ') and IV '), specifically include:
I ') pass through convolutional neural networks as character original image M content characteristic block of extraction, and be the character targets image K style and features block is extracted, wherein K > M > 1;
II ') it is each content characteristic block using the determining most matched style and features block of normalized crosscorrelation matching method;
III ') each content characteristic block and corresponding most matched style and features block are swapped;
IV ') according to the complete content images of style and features block reconstruction after the exchange, obtain the character style image.It is excellent The number of lap in selection of land, the M content characteristic block and the K style and features block is greater than preset threshold, and includes pair Answer all channels of image.
Specifically, extracting the feature vector of two images by convolutional neural networks, feature is carried out using the method for NCC Match, most matched style and features block is swapped with content characteristic block, finally rebuilds content images and obtain final character style figure Picture.In the formula of Style Transfer module, C and S respectively indicate the rgb value of content images and style image, and Φ () represents pre-training Input picture can be mapped in some activation space by the function of conventional part in convolutional neural networks, the function.In order to enable The Feature Mapping arrived has shift invariant, and Feature Mapping structure uses activation of the sigmoid function as convolutional neural networks Function.Φ (C) and Φ (S) are obtained after calculating sigmoid activation primitive, the realization process of Style Transfer is as follows: it is preferred, it is content Image and style image extract one group of characteristic block, use respectivelyWithIt indicates, wherein NcAnd NsIt is special The number of block is levied, optimal Style Transfer effect, the content characteristic block and style and features block of extraction should have enough in order to obtain Lap, and include all channels of image;Then, it for each content characteristic block, is determined most using based on the method for NCC Matched style and features block, calculation formula are as follows: Then, by each content characteristic block Φi(C) with its most matched style and features block Φi ss(C, S) is swapped;Finally, rebuilding Complete content images, use Φ heress(C, S) indicates that there are different Φ for lapi ssIt the case where (C, S) value, needs First the value different to these is averaged, and is then swapped again.The spy of style image and content images is extracted by operating above Vector is levied, characteristic matching is carried out using the method based on normalization crosscorrelation, finally rebuilds content images and obtain one by interior Hold the Style Transfer effect picture of the textures synthesis of the structure and style image of image.
103 are entered step later, and generating according to the character style image and the character targets image has the predetermined inclination The character sample image of distortion character.
Optionally, step 103 further comprises the steps i "), ii ") and iii "), it specifically includes:
I ") by the character style image and character targets image progress SIFT feature matching, it obtains based on two figures The N of picture is to characteristic point;
Ii ") according to basic function U (r)=r2logr2And deformation functionIt will The coordinate points of N number of characteristic point of the character style image are accordingly deflected into the coordinate of N characteristic point of the character targets image On point, wherein r is coordinate points (x, y) at a distance from Descartes's origin and Δ2U=0, DkIt is the coordinate of four datum marks, this four Datum mark constitutes a square;
Iii ") be based on step ii ") in deformation, according to difference functions Φ1(A)=C+DTA+WTS (A) interpolation has been provided The character sample image of the predetermined inclination distortion character, wherein C is scalar, vector D ∈ R2×1, vector W ∈ RN×1, R is real Number field, S (A)=(U (A-A1) ..., U (A-AN))T, Ai(i=1,2 ..., N) is N number of characteristic point of the character style image Coordinate points.
Optionally, step ii ") it can further include: the word of above-mentioned 2D coordinate system is simulated by the deformation to a plate Accord with the deformation of style image.For example, it is assumed that putting a square on the plate, two points of the plate are fixed on the square Two diagonal tops, and plate other two point is fixed on the diagonal lower section of another two of the square, plate can generate at this time Deformation and bending in vertical direction, the smallest deformation function of bending energy are used It indicates, wherein DkIt is the coordinate at four angles of square, since the deformation function is bending energy functionMinimum value, and function phi1It (A) is so that curved The smallest interpolating function of Qu Nengliang, therefore select Φ1It (A) is the interpolating function of plate.Further, we imagine this shape Change is embedded into two dimensional image, for example deformation function z (x, y) is regarded as the variation of the x coordinate of coordinate points (x, y), by image In any two angular coordinate is moved up, other two moves down angular coordinate, since the deformation in slab to be put into On x coordinate, therefore obtained all y-coordinates all remain unchanged;Similarly, if carrying out deformation to y-coordinate, so that it may obtain The interpolation of whole two dimensional image.
Optionally, step iii ") may include: based on step ii ") in deformation, according to difference functions Φ1(A)=C +DTA+WTS (A) interpolation provides the character sample image of the predetermined inclination distortion character, and wherein C is scalar, vector D ∈ R2×1, Vector W ∈ RN×1, R is real number field, S (A)=(U (A- A1) ..., U (A-AN))T, Ai(i=1,2 ..., N) is the character style The coordinate points of N number of characteristic point of image.Interpolating function Φ1(A) there is N+3 parameter, and formula Bi=Φ (Ai) in only give N number of, interpolating function could be solved by needing to add three constraint conditions again.Constraint condition are as follows:WhereinWithIndicates coordinate point AiX-axis coordinate and y-axis coordinate, then interpolating function and constraint condition can be write as are as follows:In formula (S)i=U (A-Ai), 1NWhat is represented is the N-dimensional column vector that value is all 1,It therefore, can be in the hope of the parameter in the interpolating function: Interpolating function is finally obtained, and provides the interpolation of whole image.
More than, present embodiment may finally obtain both realistic illumination textures according to above each step and embodiment There is the character sample image of default twist distortion feature again, obtained character sample image is true and reliable, makes training sample more Add abundant, the problem of avoiding training pattern over-fitting.
The second embodiment of the application proposes a kind of generation system of character sample, and structure, should as shown in Fig. 2 The generation system of character sample includes acquisition module and processing module;Wherein, acquisition module according to character original image for obtaining Character targets image with natural lighting texture and default twist distortion feature;Processing module is used for basis from the acquisition module Character original image and the character targets image of input generate character style image by the migration of illumination texture, and according to this Character style image and the character targets image generate the character sample image with the predetermined inclination distortion character.
Optionally, which is also used to through Unicode be that image obtains character original by the text conversion of text type Character original image is printed as paper document by image, passes through the character on the paper document under the natural scene of shooting simulation The character targets intermediate image with natural lighting texture and default twist distortion feature is obtained, and will be among the character targets Image is set as obtaining character targets image with pixel with the character original image.
Optionally, which is also used to be that the character original image extracts M content characteristic by convolutional neural networks Block and be K style and features block of the character targets image zooming-out, wherein K > M > 1 is each content characteristic block using normalizing Matching by cross correlation determines most matched style and features block, by each content characteristic block and corresponding most matched wind Lattice characteristic block swaps, and rebuilds complete content images according to the style and features block after the exchange, obtains the character wind Table images.Preferably, the number of the M content characteristic block and the lap in the K style and features block is greater than preset threshold, It and include all channels of correspondence image.
Specifically, the processing module extracts the feature vector of two images by convolutional neural networks, using the side of NCC Method carries out characteristic matching, and most matched style and features block is swapped with content characteristic block, finally rebuilds content images and obtains Final character style image.In the formula of Style Transfer module, C and S respectively indicate content images and style image Rgb value, Φ () represent the function of conventional part in pre-training convolutional neural networks, which can be mapped to input picture In some activation space.In order to enable the Feature Mapping arrived has shift invariant, Feature Mapping structure uses sigmoid letter Activation primitive of the number as convolutional neural networks.Φ (C) and Φ (S), Style Transfer are obtained after calculating sigmoid activation primitive Realization process it is as follows: firstly, extracting one group of characteristic block for content images and style image, use respectivelyWithIt indicates, wherein NcAnd NsThe number of characteristic block, optimal Style Transfer effect in order to obtain, extraction it is interior Enough laps should be had by holding characteristic block and style and features block, and include all channels of image;Then, for each interior Hold characteristic block, using determining most matched style and features block, calculation formula based on the method for NCC are as follows:Then, by each content characteristic block Φi(C) with Its most matched style and features block Φi ss(C, S) is swapped;Finally, rebuilding complete content images, Φ is used heress(C, S) It indicates, for lap, there are different Φi ssThe case where (C, S) value, value first different to these is needed to average, then again It swaps.The feature vector that style image and content images are extracted by operating above, using based on normalization crosscorrelation Method carry out characteristic matching, finally rebuild content images obtain a structure and style image by content images texture close At Style Transfer effect picture.
Optionally, which is also used to, and the character style image and the character targets image are carried out SIFT feature Point matching, obtains the N based on two images to characteristic point;According to basic function U (r)=r2logr2And deformation functionThe coordinate points of N number of characteristic point of the character style image are corresponded into crust deformation Onto the coordinate points of N number of characteristic point of the character targets image, wherein r be coordinate points (x, y) at a distance from Descartes's origin and Δ2U=0, DkIt is the coordinate of four datum marks, which constitutes a square;And according to difference functions Φ1(A) =C+DTA+WTS (A) interpolation provides the character sample image of the predetermined inclination distortion character, and wherein C is scalar, vector D ∈R2×1, vector W ∈ RN×1, R is real number field, S (A)=(U (A-A1) ..., U (A-AN))T, Ai(i=1,2 ..., N) is described The coordinate points of N number of characteristic point of character style image.
Optionally, which is also used to, and the character style figure of above-mentioned 2D coordinate system is simulated by the deformation to a plate The deformation of picture, specifically, two points of the plate are fixed on the square for example, it is assumed that put a square on the plate Two diagonal tops, and plate other two point is fixed on the diagonal lower section of another two of the square;Plate can generate vertical at this time Histogram upward deformation and bending, the smallest deformation function of bending energy are usedTable Show, wherein DkIt is the coordinate at four angles of square, since the deformation function is bending energy functionMinimum value, and function phi1It (A) is so that bending energy is minimum Interpolating function, therefore select Φ1It (A) is the interpolating function of plate.Further, we, which imagine, is embedded into two this deformation It ties up in image, for example deformation function z (x, y) is regarded as the variation of the x coordinate of coordinate points (x, y), by any two in image A to move up to angular coordinate, other two moves down angular coordinate, since the deformation in slab being put on x coordinate, Therefore all y-coordinates obtained all remain unchanged;Similarly, if carrying out deformation to y-coordinate, so that it may obtain whole two dimension The interpolation of image.
Optionally, which is also used to, based on the deformation of above-mentioned character style image, according to difference functions Φ1(A) =C+DTA+WTS (A) interpolation provides the character sample image of the predetermined inclination distortion character, and wherein C is scalar, vector D ∈ R2 ×1, vector W ∈ RN×1, R is real number field, S (A)=(U (A- A1) ..., U (A-AN))T, Ai(i=1,2 ..., N) is the character wind The coordinate points of N number of characteristic point of table images, R are real number field.Interpolating function Φ1(A) there is N+3 parameter, and formula Bi=Φ (Ai) in only give N number of, interpolating function could be solved by needing to add three constraint conditions again.Constraint condition are as follows:WhereinWithIndicates coordinate point AiX-axis coordinate and y-axis coordinate, then interpolating function and constraint condition It can be write as are as follows:In formula (S)i=U (A-Ai), 1NWhat is represented is the N-dimensional that value is all 1 Column vector,It therefore, can be in the hope of the parameter in the interpolating function:Interpolating function is finally obtained, and provides the interpolation of whole image.
In the application embodiment, finally obtains not only realistic illumination texture but also there is default twist distortion feature Character sample image, obtained character sample image is true and reliable, keeps training sample more abundant, it is excessively quasi- to avoid training pattern The problem of conjunction.
Optionally, which further includes output module, for exporting the character sample image.
First embodiment is method implementation corresponding with present embodiment, and the technology in first embodiment is thin Section can be applied to present embodiment, and the technical detail in present embodiment also can be applied to first embodiment.
It should be noted that it will be appreciated by those skilled in the art that the embodiment of the generation system of above-mentioned character sample Shown in each module realization function can refer to aforementioned character sample generation method associated description and understand.Above-mentioned character The function of each module shown in the embodiment of the generation system of sample can be (executable by running on the program on processor Instruction) and realize, it can also be realized by specific logic circuit.The generation system of the above-mentioned character sample of the embodiment of the present application is such as Fruit is realized and when sold or used as an independent product in the form of software function module, also can store in a computer In read/write memory medium.Based on this understanding, the technical solution of the embodiment of the present application is substantially in other words to the prior art The part to contribute can be embodied in the form of software products, which is stored in a storage medium In, including some instructions use is so that a computer equipment (can be personal computer, server or network equipment etc.) Execute all or part of each embodiment the method for the application.And storage medium above-mentioned include: USB flash disk, mobile hard disk, only Read the various media that can store program code such as memory (ROM, Read Only Memory), magnetic or disk.In this way, The embodiment of the present application is not limited to any specific hardware and software and combines.
Correspondingly, the application embodiment also provides a kind of computer readable storage medium, wherein being stored with computer can It executes instruction, which realizes each method embodiment of the application when being executed by processor.Computer can Reading storage medium includes that permanent and non-permanent, removable and non-removable media can be accomplished by any method or technique Information storage.Information can be computer readable instructions, data structure, the module of program or other data.The storage of computer The example of medium includes but is not limited to that phase change memory (PRAM), static random access memory (SRAM), dynamic randon access are deposited Reservoir (DRAM), other kinds of random access memory (RAM), read-only memory (ROM), electrically erasable is read-only deposits Reservoir (EEPROM), flash memory or other memory techniques, read-only disc read only memory (CD-ROM) (CD-ROM), digital multi light Disk (DVD) or other optical storage, magnetic cassettes, tape magnetic disk storage or other magnetic storage devices or any other is non- Transmission medium, can be used for storage can be accessed by a computing device information.As defined in this article, computer-readable storage medium Matter does not include temporary computer readable media (transitory media), such as the data-signal and carrier wave of modulation.
In addition, the application embodiment also provides a kind of generation system of character sample, calculated including for storing The memory of machine executable instruction, and, processor;The processor is used to execute the executable finger of the computer in the memory The step in above-mentioned each method embodiment is realized when enabling.Wherein, which can be central processing unit (Central Processing Unit, referred to as " CPU "), it can also be other general processors, digital signal processor (Digital Signal Processor, referred to as " DSP "), specific integrated circuit (Application Specific Integrated Circuit, referred to as " ASIC ") etc..Memory above-mentioned can be read-only memory (read-only memory, abbreviation " ROM "), random access memory (random access memory, referred to as " RAM "), flash memory (Flash), hard disk Or solid state hard disk etc..The step of method disclosed in each embodiment of the present invention, can be embodied directly in hardware processor execution Complete, or in processor hardware and software module combine execute completion.
It should be noted that relational terms such as first and second and the like are only in the application documents of this patent For distinguishing one entity or operation from another entity or operation, without necessarily requiring or implying these entities Or there are any actual relationship or orders between operation.Moreover, the terms "include", "comprise" or its any other Variant is intended to non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only It including those elements, but also including other elements that are not explicitly listed, or further include for this process, method, object Product or the intrinsic element of equipment.In the absence of more restrictions, the element limited by sentence " including one ", not There is also other identical elements in the process, method, article or apparatus that includes the element for exclusion.The application of this patent In file, if it is mentioned that certain behavior is executed according to certain element, then refers to the meaning for executing the behavior according at least to the element, wherein Include two kinds of situations: executing the behavior according only to the element and the behavior is executed according to the element and other elements.Multiple, Repeatedly, the expression such as a variety of include 2,2 times, 2 kinds and 2 or more, 2 times or more, two or more.
It is included in disclosure of this application with being considered as globality in all documents that the application refers to, so as to It can be used as the foundation of modification if necessary.In addition, it should also be understood that, the foregoing is merely the preferred embodiments of this specification, and The non-protection scope for being used to limit this specification.It is all this specification one or more embodiment spirit and principle within, institute Any modification, equivalent substitution, improvement and etc. of work, should be included in this specification one or more embodiment protection scope it It is interior.

Claims (10)

1. a kind of generation method of character sample characterized by comprising
The character targets image with natural lighting texture and default twist distortion feature is obtained according to character original image;
Character style image is generated by the migration of illumination texture according to the character original image and the character targets image;
The character with the predetermined inclination distortion character is generated according to the character style image and the character targets image Sample image.
2. the method as described in claim 1, which is characterized in that described to obtain having under natural lighting according to character original image The character targets image of predetermined inclination distortion character further comprises:
The text conversion of text type is obtained into character original image for image by Unicode code;
The character original image is printed as paper document;
By the character on the paper document under the natural scene of shooting simulation, obtains with natural lighting texture and preset The character targets intermediate image of twist distortion feature;
By the character targets intermediate image be set as with the same pixel of character original image, obtain character targets image.
3. method according to claim 1 or 2, which is characterized in that described according to the character original image and the character mesh Logo image generates character style image by the migration of illumination texture, further comprises:
It is character original image M content characteristic block of extraction by convolutional neural networks, and is the character targets image K style and features block is extracted, wherein K > M > 1;
Most matched style and features block is determined using normalized crosscorrelation matching method for each content characteristic block;
Each content characteristic block and corresponding most matched style and features block are swapped;
Complete content images are rebuild according to the style and features block after the exchange, obtain the character style image.
4. method as claimed in claim 3, which is characterized in that in the M content characteristic block and the K style and features block The number of lap be greater than preset threshold, and include all channels of correspondence image.
5. method according to claim 1 or 2, which is characterized in that described according to the character style image and the character Target image generates the character sample image with the predetermined inclination distortion character, further comprises:
The character style image and the character targets image are subjected to SIFT feature matching, obtained based on two images N is to characteristic point;
According to basic function U (r)=r2logr2And deformation functionIt will be described The coordinate points of N number of characteristic point of character style image are accordingly deflected into the coordinate of N number of characteristic point of the character targets image On point, wherein r is coordinate points (x, y) at a distance from Descartes's origin and Δ2U=0, DkIt is the coordinate of four datum marks, this four Datum mark constitutes a square;
Based on the deformation, according to difference functions Φ1(A)=C+DTA+WTIt is special that S (A) interpolation has provided the predetermined inclination distortion The character sample image of sign, wherein C is scalar, vector D ∈ R2×1, vector W ∈ RN×1, R is real number field, S (A)=(U (A- A1),…,U(A-AN))T, Ai(i=1,2 ..., N) is the coordinate points of N number of characteristic point of the character style image.
6. a kind of generation system of character sample characterized by comprising
Acquisition module, for obtaining the character mesh with natural lighting texture and default twist distortion feature according to character original image Logo image;
Processing module, for being passed through according to the character original image and the character targets image that are inputted from the acquisition module The migration of illumination texture generates character style image, and generates tool according to the character style image and the character targets image There is the character sample image of the predetermined inclination distortion character.
7. system as claimed in claim 6, which is characterized in that the acquisition module is also used to text type through Unicode Text conversion be image obtain character original image, character original image is printed as paper document, pass through shooting simulation nature The character on the paper document under scene obtains the character targets with natural lighting texture and default twist distortion feature Intermediate image, and set the character targets intermediate image to obtain character targets figure with pixel with the character original image Picture.
8. system as claimed in claim 6, which is characterized in that the processing module is also used to through convolutional neural networks be institute It states character original image to extract M content characteristic block and be K style and features block of the character targets image zooming-out, wherein K > M > 1, Most matched style and features block is determined using normalized crosscorrelation matching method for each content characteristic block, it will be described each described interior Hold characteristic block and corresponding most matched style and features block swaps, and according to the style and features block after the exchange Complete content images are rebuild, the character style image is obtained.
9. a kind of generation system of character sample characterized by comprising
Memory, for storing computer executable instructions;And
Processor, for being realized as described in any one of claim 1 to 5 when executing the computer executable instructions Step in method.
10. a kind of computer readable storage medium, which is characterized in that be stored with computer in the computer readable storage medium Executable instruction is realized as described in any one of claim 1 to 5 when the computer executable instructions are executed by processor Method in step.
CN201910691368.XA 2019-07-29 2019-07-29 The generation method and its system of character sample Pending CN110427948A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910691368.XA CN110427948A (en) 2019-07-29 2019-07-29 The generation method and its system of character sample

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910691368.XA CN110427948A (en) 2019-07-29 2019-07-29 The generation method and its system of character sample

Publications (1)

Publication Number Publication Date
CN110427948A true CN110427948A (en) 2019-11-08

Family

ID=68411285

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910691368.XA Pending CN110427948A (en) 2019-07-29 2019-07-29 The generation method and its system of character sample

Country Status (1)

Country Link
CN (1) CN110427948A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110807823A (en) * 2019-11-13 2020-02-18 四川大学 Image simulation generation method for dot matrix character printing effect
CN111160279A (en) * 2019-12-31 2020-05-15 武汉星巡智能科技有限公司 Method, apparatus, device and medium for generating target recognition model using small sample
CN111242114A (en) * 2020-01-08 2020-06-05 腾讯科技(深圳)有限公司 Character recognition method and device
CN112235476A (en) * 2020-09-15 2021-01-15 南京航空航天大学 Test data generation method based on fusion variation
CN113537229A (en) * 2021-08-27 2021-10-22 广州广电运通金融电子股份有限公司 Bill image generation method and device, computer equipment and storage medium
CN114897672A (en) * 2022-05-31 2022-08-12 北京外国语大学 Image cartoon style migration method based on equal deformation constraint

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101488187A (en) * 2008-01-18 2009-07-22 Mv科技软件有限责任公司 System and method for deformable object recognition
CN102054296A (en) * 2011-01-20 2011-05-11 西北大学 Grid deformation method based on local rigidity
CN102184383A (en) * 2011-04-18 2011-09-14 哈尔滨工业大学 Automatic generation method of image sample of printed character
CN102208025A (en) * 2011-05-27 2011-10-05 中国科学院自动化研究所 Method for correcting geometric distortion of text image
KR20140008686A (en) * 2012-07-11 2014-01-22 에스케이플래닛 주식회사 Character service system, method and apparatus for providing character service in the system
US20160283814A1 (en) * 2015-03-25 2016-09-29 Alibaba Group Holding Limited Method and apparatus for generating text line classifier
CN107767328A (en) * 2017-10-13 2018-03-06 上海交通大学 The moving method and system of any style and content based on the generation of a small amount of sample
CN108537776A (en) * 2018-03-12 2018-09-14 维沃移动通信有限公司 A kind of image Style Transfer model generating method and mobile terminal

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101488187A (en) * 2008-01-18 2009-07-22 Mv科技软件有限责任公司 System and method for deformable object recognition
CN102054296A (en) * 2011-01-20 2011-05-11 西北大学 Grid deformation method based on local rigidity
CN102184383A (en) * 2011-04-18 2011-09-14 哈尔滨工业大学 Automatic generation method of image sample of printed character
CN102208025A (en) * 2011-05-27 2011-10-05 中国科学院自动化研究所 Method for correcting geometric distortion of text image
KR20140008686A (en) * 2012-07-11 2014-01-22 에스케이플래닛 주식회사 Character service system, method and apparatus for providing character service in the system
US20160283814A1 (en) * 2015-03-25 2016-09-29 Alibaba Group Holding Limited Method and apparatus for generating text line classifier
CN107767328A (en) * 2017-10-13 2018-03-06 上海交通大学 The moving method and system of any style and content based on the generation of a small amount of sample
CN108537776A (en) * 2018-03-12 2018-09-14 维沃移动通信有限公司 A kind of image Style Transfer model generating method and mobile terminal

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
王亚蒙: "基于风格迁移与薄板样条变形的扩充汉字样本库的算法研究" *

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110807823A (en) * 2019-11-13 2020-02-18 四川大学 Image simulation generation method for dot matrix character printing effect
CN111160279A (en) * 2019-12-31 2020-05-15 武汉星巡智能科技有限公司 Method, apparatus, device and medium for generating target recognition model using small sample
CN111242114A (en) * 2020-01-08 2020-06-05 腾讯科技(深圳)有限公司 Character recognition method and device
CN111242114B (en) * 2020-01-08 2023-04-07 腾讯科技(深圳)有限公司 Character recognition method and device
CN112235476A (en) * 2020-09-15 2021-01-15 南京航空航天大学 Test data generation method based on fusion variation
CN113537229A (en) * 2021-08-27 2021-10-22 广州广电运通金融电子股份有限公司 Bill image generation method and device, computer equipment and storage medium
CN114897672A (en) * 2022-05-31 2022-08-12 北京外国语大学 Image cartoon style migration method based on equal deformation constraint

Similar Documents

Publication Publication Date Title
CN110427948A (en) The generation method and its system of character sample
CN108427924B (en) Text regression detection method based on rotation sensitive characteristics
Escalera et al. Blurred shape model for binary and grey-level symbol recognition
Shah et al. Leaf classification using marginalized shape context and shape+ texture dual-path deep convolutional neural network
Zafar et al. Image classification by addition of spatial information based on histograms of orthogonal vectors
Kriege et al. Recognizing cuneiform signs using graph based methods
MX2007010180A (en) Intelligent importation of information from foreign application user interface using artificial intelligence.
CN104866855A (en) Image feature extraction method and apparatus
CN113065536B (en) Method of processing table, computing device, and computer-readable storage medium
CN104809731A (en) Gradient binaryzation based rotation-invariant and scale-invariant scene matching method
Li et al. Place recognition based on deep feature and adaptive weighting of similarity matrix
Ghosh et al. Language-invariant novel feature descriptors for handwritten numeral recognition
Li et al. Braille recognition using deep learning
CN112446431B (en) Feature point extraction and matching method, network, equipment and computer storage medium
Zhu et al. Plant identification via multipath sparse coding
Manjunatha et al. Convolutional Neural Network-based image tamper detection with Error Level Analysis
Verma et al. Script identification in natural scene images: a dataset and texture-feature based performance evaluation
Pengcheng et al. Fast Chinese calligraphic character recognition with large-scale data
Qin et al. Deep Updated Subspace Networks for Few-Shot Remote Sensing Scene Classification
Arifoglu et al. Matching Islamic patterns in Kufic images
Omiecinski et al. Concurrent file reorganization for record clustering: A performance study
Wu et al. A multi-scale multi-level deep descriptor with saliency for image retrieval
Barnes et al. STRICR-FB, A novel size-translation-rotation-invariant character recognition method
Kumaresan et al. Direction-invariant binary pattern-encoded descriptor for texture classification and retrieval
Ge et al. Sparse representation based classification by using PCA-SIFT descriptors

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
WD01 Invention patent application deemed withdrawn after publication

Application publication date: 20191108

WD01 Invention patent application deemed withdrawn after publication