CN107563386A - Component verification method, device, equipment and computer-readable storage medium - Google Patents
Component verification method, device, equipment and computer-readable storage medium Download PDFInfo
- Publication number
- CN107563386A CN107563386A CN201710793182.6A CN201710793182A CN107563386A CN 107563386 A CN107563386 A CN 107563386A CN 201710793182 A CN201710793182 A CN 201710793182A CN 107563386 A CN107563386 A CN 107563386A
- Authority
- CN
- China
- Prior art keywords
- component
- character
- verified
- model
- image
- 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
- 238000000034 method Methods 0.000 title claims abstract description 64
- 238000012795 verification Methods 0.000 title claims abstract description 30
- 238000003860 storage Methods 0.000 title claims abstract description 17
- 238000012545 processing Methods 0.000 claims abstract description 50
- 230000011218 segmentation Effects 0.000 claims description 32
- 238000004590 computer program Methods 0.000 claims description 19
- 238000007781 pre-processing Methods 0.000 claims description 13
- 238000006243 chemical reaction Methods 0.000 claims description 12
- 238000003672 processing method Methods 0.000 claims 1
- 238000005516 engineering process Methods 0.000 abstract description 7
- 230000003247 decreasing effect Effects 0.000 description 6
- 230000001174 ascending effect Effects 0.000 description 4
- 239000003990 capacitor Substances 0.000 description 4
- 238000001514 detection method Methods 0.000 description 4
- 230000009286 beneficial effect Effects 0.000 description 3
- 230000000694 effects Effects 0.000 description 3
- 230000006870 function Effects 0.000 description 3
- 238000004891 communication Methods 0.000 description 2
- 238000012937 correction Methods 0.000 description 2
- 238000004519 manufacturing process Methods 0.000 description 2
- 238000012706 support-vector machine Methods 0.000 description 2
- 238000004458 analytical method Methods 0.000 description 1
- 238000003491 array Methods 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 238000005260 corrosion Methods 0.000 description 1
- 230000007797 corrosion Effects 0.000 description 1
- 238000009826 distribution Methods 0.000 description 1
- 238000003708 edge detection Methods 0.000 description 1
- 230000003628 erosive effect Effects 0.000 description 1
- 238000005530 etching Methods 0.000 description 1
- 239000000945 filler Substances 0.000 description 1
- 238000003709 image segmentation Methods 0.000 description 1
- 238000002360 preparation method Methods 0.000 description 1
- 238000004549 pulsed laser deposition Methods 0.000 description 1
Landscapes
- Image Analysis (AREA)
Abstract
The embodiment of the invention provides a component verification method, a device, equipment and a computer readable storage medium, wherein the method comprises the steps of obtaining an image of a component to be verified; performing character cutting processing on an image of a component to be verified to obtain a character image corresponding to each character in the model of the component to be verified; identifying the component model of the component to be verified according to the character image corresponding to each character in the component model of the component to be verified; and judging whether the component to be verified and the standard component are the same component or not according to the component model of the component to be verified. The invention realizes the automatic identification of the components through the image identification technology, the whole process from the input of the image of the component to be verified to the output of the final verification result is executed by the computer without manual participation, the efficiency of identifying the components is greatly improved, the error caused by manual misreading is reduced, and the method can be effectively applied to the component correctness verification of the PCB.
Description
Technical field
The present invention relates to PCB production technical fields, more particularly to a kind of component verification method, device, equipment and calculating
Machine readable storage medium storing program for executing.
Background technology
, it is necessary to ensure that each component on pcb board is to have used correctly during pcb board is produced in batches
Model.For example, need to lay 500uf electric capacity for a certain position on pcb board, but due to artificial, this position
What is actually laid is 200uf electric capacity, and this does not meet actual circuit requirements, or even brings danger, it is therefore necessary to
Each component on pcb board is verified whether to employ the component of correct model.
For at present, the mode of checking be all by manually going to verify one by one, it is low using the method efficiency of manual verification
And it is very easy to error.
The content of the invention
The embodiments of the invention provide a kind of component verification method, device, equipment and computer-readable recording medium, energy
The efficiency of checking component is enough greatly improved, and improves accuracy.
First aspect of the embodiment of the present invention provides a kind of component verification method, including:
Obtain the image of component to be verified;
Character segmentation processing is carried out to the image of the component to be verified, obtains the component of the component to be verified
Character picture in model corresponding to each character;
Described in character picture according to corresponding to each character in the component model of the component to be verified identifies
The component model of component to be verified;
Judge whether are the component to be verified and standard component according to the component model of the component to be verified
For identical component.
Preferably, the character picture according to corresponding to each character in the component model of the component to be verified
The component model of the component to be verified is identified, including:
By the character picture corresponding to each character in the component model of the component to be verified in sequence one by one
Ground is input to the character classifier trained using SVM, to identify each word in the component model of the component to be verified
Symbol;
First device of the component to be verified is obtained according to each character in the component model of the component to be verified
Part model.
Preferably, methods described also includes:
Before the image of component to be verified is obtained, the template image of the standard component is obtained and to the template
Image carries out gray processing processing and binary conversion treatment;
Character segmentation processing is carried out to the template image, obtains each word in the component model of the standard component
The corresponding character picture of symbol;
Each character in the component model of standard component described in the character definition information definition inputted according to user.
Preferably, the component model according to the component to be verified judges the component to be verified and standard
Whether component is identical component, including:
By each character in the component model of the component to be verified correspondingly with the standard component
Component model in each character be compared;
When the component type of i-th of character and the standard component in the component model of the component to be verified
When i-th of character in number belongs to identical characters, judge i-th of character in the component model of the component to be verified with
I-th of character in the component model of the standard component matches;
When the component type of i-th of character and the standard component in the component model of the component to be verified
When i-th of character in number is not belonging to identical characters, by i-th of character institute in the component model of the component to be verified
Corresponding character picture carries out mould with the character picture corresponding to i-th of character in the component model of the standard component
Plate matches;
When the similarity that template matches obtain exceedes default similarity threshold, the member of the component to be verified is judged
I-th of character in device model matches with i-th of character in the component model of the standard component;Otherwise judge
I-th of character in the component model of the component to be verified and i-th in the component model of the standard component
Individual character does not match that;
When each character in the component model of the component to be verified correspondingly with the standard component
Component model in each character when matching, judge that the component to be verified and standard component are identical member device
Part;Otherwise it is determined as the component differed.
Preferably, methods described also includes:
When j-th of character in the component model of the standard component be predefined for asterisk wildcard when, judge institute
State j-th of character in the component model of component to be verified and j-th in the component model of the standard component
Character belongs to identical characters.
Preferably, methods described also includes:
Before Character segmentation processing is carried out to the template image, pair of the template image of the standard component is calculated
Image preprocessing is carried out than degree and according to the contrast to the template image, until the contrast reaches default contrast
Threshold value is spent, and records the parameter of final image preprocessing;
Before Character segmentation processing is carried out to the image of the component to be verified, using identical with the template image
Preprocess method and the parameter image preprocessing is carried out to the image of the component to be verified.
Preferably, methods described also includes:
Before Character segmentation processing is carried out to the template image, exclusive PCR connected domain is carried out to the template image
Processing;
Before Character segmentation processing is carried out to the image of the component to be verified, to the figure of the component to be verified
As carrying out exclusive PCR Connected area disposal$;
After character picture in the component model for obtaining the standard component corresponding to each character, to described
Character picture in the component model of standard component corresponding to each character carries out exclusive PCR Connected area disposal$ respectively;
After character picture in the component model for obtaining the component to be verified corresponding to each character, to institute
The character picture in the component model of component to be verified corresponding to each character is stated to carry out at exclusive PCR connected domain respectively
Reason.
Second aspect of the embodiment of the present invention provides a kind of component checking device, including:
First image collection module, for obtaining the image of component to be verified;
First Character segmentation module, for carrying out Character segmentation processing to the image of the component to be verified, obtain institute
State the character picture corresponding to each character in the component model of component to be verified;
Device model identification module, for corresponding to each character in the component model according to the component to be verified
Character picture identify the component model of the component to be verified;
Judge module, for judging the component to be verified and mark according to the component model of the component to be verified
Whether quasi- component is identical component.
The third aspect of the embodiment of the present invention provides a kind of component checking equipment, including processor, memory and deposits
Storage is in the memory and is configured as by the computer program of the computing device, calculating described in the computing device
The component verification method described in above-mentioned first aspect is realized during machine program.
The aspect of the embodiment of the present invention four provides a kind of computer-readable recording medium, the computer-readable recording medium
Computer program including storage, wherein, the computer-readable recording medium institute is controlled when the computer program is run
The component verification method described in above-mentioned first aspect is performed in equipment.
Compared to prior art, the beneficial effect of the embodiment of the present invention is:The embodiments of the invention provide a kind of first device
Part verification method, device, equipment and computer-readable recording medium, method include obtaining the image of component to be verified;To institute
The image for stating component to be verified carries out Character segmentation processing, obtains each word in the component model of the component to be verified
The corresponding character picture of symbol;According to the character picture corresponding to each character in the component model of the component to be verified
Identify the component model of the component to be verified;Treated according to judging the component model of the component to be verified
Verify whether component and standard component are identical component.The embodiment of the present invention realizes member by image recognition technology
The automatic identification of device, held from the output overall process of the image to the final the result that input component to be verified by computer
OK, caused error is artificially misread without the artificial efficiency for participating in, greatly improving identification component, reduction, can be effectively
Apply the component verification of correctness in pcb board.
Brief description of the drawings
In order to illustrate more clearly of technical scheme, the required accompanying drawing used in embodiment will be made below
Simply introduce, it should be apparent that, drawings in the following description are only some embodiments of the present invention, general for this area
For logical technical staff, on the premise of not paying creative work, other accompanying drawings can also be obtained according to these accompanying drawings.
Fig. 1 is a kind of schematic flow sheet of component verification method provided in an embodiment of the present invention;
Fig. 2 is the template image without the circular capacitor of exclusive PCR Connected area disposal$;
Fig. 3 is the template image by the circular capacitor of exclusive PCR Connected area disposal$;
Fig. 4 is a kind of structured flowchart of component checking device provided in an embodiment of the present invention.
Embodiment
Below in conjunction with the accompanying drawing in the embodiment of the present invention, the technical scheme in the embodiment of the present invention is carried out clear, complete
Site preparation describes, it is clear that described embodiment is only part of the embodiment of the present invention, rather than whole embodiments.It is based on
Embodiment in the present invention, those of ordinary skill in the art are obtained every other under the premise of creative work is not made
Embodiment, belong to the scope of protection of the invention.
Referring to Fig. 1, it is a kind of schematic flow sheet of component verification method provided in an embodiment of the present invention.The side
Method comprises the following steps S1~S4:
S1, obtain the image of component to be verified;
S2, Character segmentation processing is carried out to the image of the component to be verified, obtains the member of the component to be verified
Character picture in device model corresponding to each character;
S3, the character picture according to corresponding to each character in the component model of the component to be verified identify institute
State the component model of component to be verified;
S4, judge that the component to be verified and standard component are according to the component model of the component to be verified
No is identical component.
In a kind of optional embodiment, step S2 includes:
The image of the component to be verified is subjected to gray processing processing and binary conversion treatment;
Rim detection is carried out to the image of the component to be verified after gray processing processing and binary conversion treatment
Handle to obtain the edge of each character in the component model of the component to be verified;
The component to be verified is obtained according to the edge of each character in the component model of the component to be verified
Component model in character picture corresponding to each character.
It by the gray value of the point on image is 0 or 255 that the binary conversion treatment of image, which is exactly, that is, whole image is presented
Go out obvious black and white effect.Being chosen i.e. by the gray level image of 256 brightness degrees by appropriate threshold value still can be with to obtain
Reflect the overall binary image with local feature of image.In Digital Image Processing, bianry image occupies very importantly
Position, particularly in the image procossing of practicality, the system realized and formed with binary Images Processing is a lot, to carry out two-value
The processing and analysis of image, first have to a Binary Sketch of Grey Scale Image, obtain binary image, so to be advantageous to do to image
When further handling, the set property of image is only relevant with the position for the point that pixel value is 0 or 255, does not further relate to the more of pixel
Level value, makes processing become simple, and the processing of data and decrement are small.Because the image of component to be verified may carry it
The image of component to be verified, first bianry image (black white image) is converted to before edge detection process is carried out by his color,
The treating capacity of data can be reduced.
So-called edge refers to the set of its surrounding pixel gray scale those pixel jumpy, and it is the most basic spy of image
Sign.Marginal existence between target, background and region, so, it is the most important foundation that is relied on of image segmentation.In image
In processing and computer vision, rim detection is widely used.It is obvious its object is to identify bright spot change in digital picture
Point, and then extract useful information.Digital image representation can be two bit arrays by we under normal circumstances, and this two
The value of each element then correspond to the gray value of each pixel of image in array.And the cardinal principle of rim detection is to pass through calculation
Method is by the big data element of numerical value change is highlighted in each data neighborhood in the array, and change is little in neighborhood
Neighboring data elements data element is shielded or reduced its gray scale and shown.Because edge detecting technology belongs to people in the art
Member's conventional technology, thus repeat no more in embodiments of the present invention.
The embodiment of the present invention realizes the automatic identification of component by image recognition technology, from input first device to be verified
The image of part is performed to the output overall process of final judged result by computer, is participated in without artificial, greatly improves identification member
The efficiency of device, reduction artificially misread caused error, can effectively apply the component verification of correctness in pcb board.
In a kind of optional embodiment, step S3 includes:
By the character picture corresponding to each character in the component model of the component to be verified in sequence one by one
Ground is input to the character classifier trained using SVM, to identify each word in the component model of the component to be verified
Symbol;The order is specifically the coordinate bit according to the character picture corresponding to each character inside the image of component to be verified
Put and be ranked up;
First device of the component to be verified is obtained according to each character in the component model of the component to be verified
Part model.
SVM (Support Vector Machine, SVMs) character classifier is conventional character recognition tools,
Corresponding character effectively can be identified according to character picture.No longer SVM character classifiers are made in embodiments of the present invention
Excessive introduction.
In a kind of optional embodiment, methods described also includes:
Before the image of component to be verified is obtained, the template image of the standard component is obtained and to the template
Image carries out gray processing processing and binary conversion treatment;
Character segmentation processing is carried out to the template image, obtains each word in the component model of the standard component
The corresponding character picture of symbol;
Each character in the component model of standard component described in the character definition information definition inputted according to user.
In a kind of optional embodiment, step S4 includes:
By each character in the component model of the component to be verified correspondingly with the standard component
Component model in each character be compared;
When the component type of i-th of character and the standard component in the component model of the component to be verified
When i-th of character in number belongs to identical characters, judge i-th of character in the component model of the component to be verified with
I-th of character in the component model of the standard component matches;
When the component type of i-th of character and the standard component in the component model of the component to be verified
When i-th of character in number is not belonging to identical characters, by i-th of character institute in the component model of the component to be verified
Corresponding character picture carries out mould with the character picture corresponding to i-th of character in the component model of the standard component
Plate matches;
When the similarity that template matches obtain exceedes default similarity threshold, the member of the component to be verified is judged
I-th of character in device model matches with i-th of character in the component model of the standard component;Otherwise judge
I-th of character in the component model of the component to be verified and i-th in the component model of the standard component
Individual character does not match that;
When each character in the component model of the component to be verified correspondingly with the standard component
Component model in each character when matching, judge that the component to be verified and standard component are identical member device
Part;Otherwise it is determined as the component differed.
Because single knowledge is otherwise it is possible that mistake, for example, above-mentioned SVM character classifiers identify mistake or
The character picture lack of resolution of SVM character classifiers itself is input to, the component to be verified identified can be caused
Component model from it is actual different so that finally there is mistake in judged result.For example, the component of the component to be verified
Model is actually " C27016V ", and the component model of the standard component is also " C27016V ", but the institute identified
State the component model " C21016V " of component to be verified, then may result in and be finally judged as the component to be verified
It is not consistent with the standard component, the judged result of mistake occurs.In order to avoid such case, the embodiment of the present invention uses
Be mode that character recognition is combined with template matches, when a certain word of the component model of the component to be verified recognized
When symbol character corresponding with the component model of standard component differs, further matched by image template, if similar
Spend sufficiently high, then two characters to match are still considered, so as to be effectively improved the accuracy rate of detection.
In a kind of optional embodiment, methods described also includes:
When j-th of character in the component model of the standard component be predefined for asterisk wildcard when, judge institute
State j-th of character in the component model of component to be verified and j-th in the component model of the standard component
Character belongs to identical characters.
That is any one character definition in the component model of the standard component can be asterisk wildcard by user, example
The first character in the component model of standard component is defined as asterisk wildcard as will be described.When being compared, by institute
The first character stated in the component model of standard component is defined as asterisk wildcard, then no matter the member of the component to be verified
First character in device model is identified as any character, can all be determined as the component model with the standard component
In first character belong to identical characters.In this way user a certain character can be ignored as desired and without
Actual contrast.For example, asterisk wildcard can use " * " to represent.
In a kind of optional embodiment, methods described also includes:
Before Character segmentation processing is carried out to the template image, pair of the template image of the standard component is calculated
Image preprocessing is carried out than degree and according to the contrast to the template image, until the contrast reaches default contrast
Threshold value is spent, and records the parameter of final image preprocessing;
Before Character segmentation processing is carried out to the image of the component to be verified, using identical with the template image
Preprocess method and the parameter image preprocessing is carried out to the image of the component to be verified.
When the image definition of component to be verified is inadequate, the component model of component to be verified can be seriously affected
In each character recognition.In order to avoid such case, the embodiment of the present invention carries out the image of closed loop to template image first
Pretreatment, when the contrast meet demand of template image, the parameter of now image preprocessing is recorded with by subsequently to be verified
The pretreatment of the image of component.In the pretreatment of the image to component to be verified, to the figure of template image before calling
The parameter of picture pretreatment carries out image preprocessing to the image of component to be verified, so as to improve member to be verified in a short time
The image definition of device, recognition accuracy is improved in the case where not influenceing efficiency.
In a kind of optional embodiment, described image pretreatment is included in gamma conversion process and log conversion process
It is at least one.Gamma converts the correction for being mainly used in image, and the picture that gray scale is too high or gray scale is too low is modified,
Strengthen contrast;Log conversion can extend the low gray scale value part of image, show the low more details of gray portion, will
Its high gray value Partial shrinkage, the details of high gray scale value part is reduced, so as to reach the purpose for emphasizing the low gray portion of image.
Preferably, described image pretreatment also includes corrosion expansion process and anglec of rotation correction process.Wherein, it is first rotten
The process expanded after erosion is referred to as opening operation, and it, which has, eliminates small objects, in very thin place's separating objects and smooth larger object side
The effect on boundary;The process for first expanding post-etching is referred to as closed operation.It has a minuscule hole in filler body, connection adjacent object and
The effect of smooth boundary.
In a kind of optional embodiment, methods described also includes:
Before Character segmentation processing is carried out to the template image, exclusive PCR connected domain is carried out to the template image
Processing;
Before Character segmentation processing is carried out to the image of the component to be verified, to the figure of the component to be verified
As carrying out exclusive PCR Connected area disposal$;
After character picture in the component model for obtaining the standard component corresponding to each character, to described
Character picture in the component model of standard component corresponding to each character carries out exclusive PCR Connected area disposal$ respectively;
After character picture in the component model for obtaining the component to be verified corresponding to each character, to institute
The character picture in the component model of component to be verified corresponding to each character is stated to carry out at exclusive PCR connected domain respectively
Reason.
Exclusive PCR connected domain is actually the connected domain of non-character in rejection image, retains the connected domain of core character,
So as to improve the accuracy rate of character recognition or template matches.
In a kind of optional embodiment, the exclusive PCR Connected area disposal$ is specially any one below meeting
The connected domain of condition excludes:
(1) the continuous ascending series of maximum of the abscissa of the outline of the connected domain or the length ratio of decreasing sequence of numbers
More than the first preset ratio, while the continuous ascending series of maximum or decreasing sequence of numbers of the ordinate of the outline of the connected domain
Length ratio be more than first preset ratio;In the present embodiment, first preset ratio is 60%;
(2) abscissa of the outline of the connected domain exist length ratio more than the second preset ratio it is continuous be incremented by or
Length ratio be present more than second preset ratio in the subsequence to successively decrease, or the ordinate of the outline of the connected domain
The subsequence of continuous increasing or decreasing;Wherein, second preset ratio is more than first preset ratio;In the present embodiment
In, first preset ratio is 85%;
(3) the prospect ratio of the connected domain is more than the 3rd preset ratio;In the present embodiment, the 3rd preset ratio
For 80%;
(4) area of the connected domain is more than preset area threshold value;
(5) ratio of the height and the width of the connected domain is more than the 4th preset ratio and is less than the 5th preset ratio;
Wherein described 4th preset ratio is less than the 5th preset ratio;In the present embodiment, the 4th preset ratio is 1.5,
5th preset ratio is 3.2.
Illustrate the operation principle of above-mentioned exclusive PCR Connected area disposal$ below in conjunction with Fig. 2 and Fig. 3, wherein Fig. 2 be without
The template image of the circular capacitor of exclusive PCR Connected area disposal$, Fig. 3 are the circular capacitors by exclusive PCR Connected area disposal$
Template image.In fig. 2 it can be found that the bar shaped connected domain on the left side is not character connected domain, the triangle in the lower right corner connects
Logical domain is nor character connected domain, it is therefore desirable to excludes the two regions, retains core character connected domain.
For above-mentioned bar shaped connected domain, the transverse and longitudinal coordinate of its outline is distributed as:
Ordinate:[1,125,125,124,123,71,70,32,31,26,25,10,9,8,7,1]
Abscissa:[1,1,7,7,6,6,7,7,6,6,7,7,8,7,8,8]
Therefore, the transverse and longitudinal coordinate distribution of the outline of bar shaped connected domain does not meet above-mentioned (1) or (2) point, but bar shaped connects
The foreground pixel point in logical domain shares 824, and it is 1000 that the bar shaped connected domain, which shares pixel, then prospect ratio reaches
82.4%, meet (3) point, therefore above-mentioned bar shaped connected domain belongs to interference connected domain.
For above-mentioned triangle connected domain, the transverse and longitudinal coordinate of its outline is distributed as:
Ordinate:[89,90,91,92,95,96,99,100,101,102,106,107,109,110,111,111,112,
116,116,123,123,124,124,125,125,89], continuously it is incremented by the length ratio of subsequence more than 60%;
Abscissa:[139,139,138,138,135,135,132,132,131,131,127,127,125,125,124,
123123,119,118,111,110,109,108,108,140,140], continuously successively decrease subsequence length ratio more than 60%;
It can be seen that the outline transverse and longitudinal coordinate of above-mentioned triangle connected domain meets (1) point, above-mentioned triangle connected domain belongs to
Disturb connected domain.
Correspondingly, in order to perform above-mentioned component verification method, the embodiment of the present invention additionally provides a kind of component and tested
Card device.As shown in figure 4, it is a kind of structured flowchart of component checking device provided in an embodiment of the present invention, including:
First image collection module 1, for obtaining the image of component to be verified;
First Character segmentation module 2, for carrying out Character segmentation processing to the image of the component to be verified, obtain institute
State the character picture corresponding to each character in the component model of component to be verified;
Device model identification module 3, it is right for each character institute in the component model according to the component to be verified
The character picture answered identifies the component model of the component to be verified;
Judge module 4, for according to the component model of the component to be verified judge the component to be verified with
Whether standard component is identical component.
In a kind of optional embodiment, the device model identification module 3 includes:
Recognition unit, for the character picture corresponding to by each character in the component model of the component to be verified
The character classifier trained using SVM is seriatim input in sequence, to identify the component of the component to be verified
Each character in model;
Device model acquiring unit, institute is obtained for each character in the component model according to the component to be verified
State the component model of component to be verified.
In a kind of optional embodiment, described device also includes:
Second image collection module, for before the image of component to be verified is obtained, obtaining the standard component
Template image and gray processing processing and binary conversion treatment are carried out to the template image;
Second Character segmentation module, for carrying out Character segmentation processing to the template image, obtain the standard member device
Character picture in the component model of part corresponding to each character;
Character definition module, the component for standard component described in the character definition information definition that is inputted according to user
Each character in model.
In a kind of optional embodiment, the judge module 4 includes:
Comparing unit, for by each character in the component model of the component to be verified correspondingly with institute
Each character in the component model of standard component is stated to be compared;
First matching identifying unit, for when i-th of character in the component model of the component to be verified and institute
When stating i-th of character in the component model of standard component and belonging to identical characters, the member of the component to be verified is judged
I-th of character in device model matches with i-th of character in the component model of the standard component;
Template matches unit, for when i-th of character in the component model of the component to be verified and the mark
When i-th of character in the component model of quasi- component is not belonging to identical characters, by the component of the component to be verified
The character picture corresponding to i-th of character in model and i-th of character institute in the component model of the standard component
Corresponding character picture carries out template matches;
Second matching identifying unit, when the similarity for being obtained when template matches exceedes default similarity threshold, sentences
I-th of character in the component model of the fixed component to be verified and the in the component model of the standard component
I character matches;Otherwise i-th of character in the component model of the component to be verified and the standard member device are judged
I-th of character in the component model of part does not match that;
Matching components identifying unit, for when each character in the component model of the component to be verified one by one
Accordingly with when each character matches in the component model of the standard component, judging the component to be verified and mark
Quasi- component is identical component;Otherwise it is determined as the component differed.
In a kind of optional embodiment, described device also includes:
Identical characters determination module, for when j-th of character in the component model of the standard component it is advance
When being defined as asterisk wildcard, j-th of character in the component model of the component to be verified and the standard component are judged
Component model in j-th of character belong to identical characters.
In a kind of optional embodiment, described device also includes:
First pretreatment module, for before Character segmentation processing is carried out to the template image, calculating the standard
The contrast of the template image of component simultaneously carries out image preprocessing according to the contrast to the template image, until described
Contrast reaches default contrast threshold, and records the parameter of final image preprocessing;
Second pretreatment module, for before Character segmentation processing is carried out to the image of the component to be verified, adopting
Image is carried out to the image of the component to be verified with the template image identical preprocess method and the parameter
Pretreatment.
In a kind of optional embodiment, described image pretreatment is included in gamma conversion process and log conversion process
It is at least one.
In a kind of optional embodiment, described device also includes:
First interference Connected area disposal$ module, for the template image carry out Character segmentation processing before, to institute
State template image and carry out exclusive PCR Connected area disposal$;
Second interference Connected area disposal$ module, for carrying out Character segmentation processing in the image to the component to be verified
Before, exclusive PCR Connected area disposal$ is carried out to the image of the component to be verified;
3rd interference Connected area disposal$ module, for each character in the component model for obtaining the standard component
After corresponding character picture, to the character picture corresponding to each character in the component model of the standard component point
Carry out not exclusive PCR Connected area disposal$;
4th interference Connected area disposal$ module, for each word in the component model for obtaining the component to be verified
After the corresponding character picture of symbol, to the character figure corresponding to each character in the component model of the component to be verified
As carrying out exclusive PCR Connected area disposal$ respectively.
In a kind of optional embodiment, the exclusive PCR Connected area disposal$ is specially any one below meeting
The connected domain of condition excludes:
(1) the continuous ascending series of maximum of the abscissa of the outline of the connected domain or the length ratio of decreasing sequence of numbers
More than the first preset ratio, while the continuous ascending series of maximum or decreasing sequence of numbers of the ordinate of the outline of the connected domain
Length ratio be more than first preset ratio;
(2) abscissa of the outline of the connected domain exist length ratio more than the second preset ratio it is continuous be incremented by or
Length ratio be present more than second preset ratio in the subsequence to successively decrease, or the ordinate of the outline of the connected domain
The subsequence of continuous increasing or decreasing;Wherein, second preset ratio is more than first preset ratio;
(3) the prospect ratio of the connected domain is more than the 3rd preset ratio;
(4) area of the connected domain is more than preset area threshold value;
(5) ratio of the height and the width of the connected domain is more than the 4th preset ratio and is less than the 5th preset ratio;
Wherein described 4th preset ratio is less than the 5th preset ratio.
It should be noted that component checking device provided in an embodiment of the present invention is used to perform above-mentioned component checking
All method and steps of method, both operation principles and beneficial effect correspond, thus repeat no more.
Device embodiment described above is only schematical, wherein the unit illustrated as separating component can
To be or may not be physically separate, it can be as the part that unit is shown or may not be physics list
Member, you can with positioned at a place, or can also be distributed on multiple NEs.It can be selected according to the actual needs
In some or all of module realize the purpose of this embodiment scheme.In addition, device embodiment accompanying drawing provided by the invention
In, the annexation between module represents there is communication connection between them, and it is total specifically to can be implemented as one or more communication
Line or signal wire.Those of ordinary skill in the art are without creative efforts, you can to understand and implement.
Correspondingly, the embodiment of the present invention additionally provides a kind of component checking equipment, including processor, memory and deposits
Storage is in the memory and is configured as by the computer program of the computing device, calculating described in the computing device
Above-mentioned component verification method is realized during machine program.
Correspondingly, the embodiment of the present invention additionally provides a kind of computer-readable recording medium, the computer-readable storage
Medium includes the computer program of storage, wherein, control the computer-readable storage medium when the computer program is run
Equipment performs above-mentioned component verification method where matter.
Alleged processor can be CPU (Central Processing Unit, CPU), can also be it
His general processor, digital signal processor (Digital Signal Processor, DSP), application specific integrated circuit
(Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-
Programmable Gate Array, FPGA) either other PLDs, discrete gate or transistor logic,
Discrete hardware components etc..General processor can be microprocessor or the processor can also be any conventional processor
Deng.
The memory can be used for storing the computer program and/or module, and the processor is by running or performing
The computer program and/or module being stored in the memory, and call the data being stored in memory.The storage
Device can mainly include storing program area and storage data field, wherein, storing program area can storage program area, at least one function
Required application program (such as sound-playing function, image player function etc.) etc.;Storage data field can be stored according to mobile phone
Use created data (such as voice data, phone directory etc.) etc..Stored in addition, memory can include high random access
Device, nonvolatile memory, such as hard disk, internal memory, plug-in type hard disk, intelligent memory card (Smart Media can also be included
Card, SMC), secure digital (Secure Digital, SD) card, flash card (Flash Card), at least one magnetic disk storage
Part, flush memory device or other volatile solid-state parts.
Wherein, if module/unit that component checking device integrates is realized simultaneously in the form of SFU software functional unit
As independent production marketing or in use, can be stored in a computer read/write memory medium.Based on such reason
Solution, the present invention realize all or part of flow in above-described embodiment method, can also instruct correlation by computer program
Hardware complete, described computer program can be stored in a computer-readable recording medium, the computer program is in quilt
During computing device, can be achieved above-mentioned each embodiment of the method the step of.Wherein, the computer program includes computer program
Code, the computer program code can be source code form, object identification code form, executable file or some intermediate forms
Deng.The computer-readable medium can include:Any entity or device, the record of the computer program code can be carried
Medium, USB flash disk, mobile hard disk, magnetic disc, CD, computer storage, read-only storage (ROM, Read-Only Memory), with
Machine access memory (RAM, Random Access Memory), electric carrier signal, telecommunication signal and software distribution medium etc..
It should be noted that the content that the computer-readable medium includes can be according to legislation in jurisdiction and patent practice
It is required that carry out appropriate increase and decrease, such as in some jurisdictions, do not wrapped according to legislation and patent practice, computer-readable medium
Include electric carrier signal and telecommunication signal.
Compared to prior art, the beneficial effect of the embodiment of the present invention is:The embodiments of the invention provide a kind of first device
Part verification method, device, equipment and computer-readable recording medium, method include obtaining the image of component to be verified;To institute
The image for stating component to be verified carries out Character segmentation processing, obtains each word in the component model of the component to be verified
The corresponding character picture of symbol;According to the character picture corresponding to each character in the component model of the component to be verified
Identify the component model of the component to be verified;Treated according to judging the component model of the component to be verified
Verify whether component and standard component are identical component.The embodiment of the present invention realizes member by image recognition technology
The automatic identification of device, held from the output overall process of the image to the final the result that input component to be verified by computer
OK, caused error is artificially misread without the artificial efficiency for participating in, greatly improving identification component, reduction, can be effectively
Apply the component verification of correctness in pcb board.
The above disclosed power for being only a kind of preferred embodiment of the present invention, the present invention can not being limited with this certainly
Sharp scope, one of ordinary skill in the art will appreciate that realizing all or part of flow of above-described embodiment, and weighed according to the present invention
Profit requires made equivalent variations, still falls within and invents covered scope.
One of ordinary skill in the art will appreciate that realize all or part of flow in above-described embodiment method, being can be with
The hardware of correlation is instructed to complete by computer program, described program can be stored in a computer read/write memory medium
In, the program is upon execution, it may include such as the flow of the embodiment of above-mentioned each method.Wherein, described storage medium can be magnetic
Dish, CD, read-only memory (Read-Only Memory, ROM) or random access memory (Random Access
Memory, RAM) etc..
Claims (10)
- A kind of 1. component verification method, it is characterised in that including:Obtain the image of component to be verified;Character segmentation processing is carried out to the image of the component to be verified, obtains the component model of the component to be verified In character picture corresponding to each character;Character picture according to corresponding to each character in the component model of the component to be verified identifies described to be tested Demonstrate,prove the component model of component;Judge whether the component to be verified with standard component is phase according to the component model of the component to be verified Same component.
- 2. component verification method as claimed in claim 1, it is characterised in that the member according to the component to be verified Character picture in device model corresponding to each character identifies the component model of the component to be verified, including:Character picture corresponding to each character in the component model of the component to be verified is seriatim defeated in sequence Enter to the character classifier using SVM training, to identify each character in the component model of the component to be verified;The component type of the component to be verified is obtained according to each character in the component model of the component to be verified Number.
- 3. component verification method as claimed in claim 1, it is characterised in that methods described also includes:Before the image of component to be verified is obtained, the template image of the standard component is obtained and to the template image Carry out gray processing processing and binary conversion treatment;Character segmentation processing is carried out to the template image, obtains each character institute in the component model of the standard component Corresponding character picture;Each character in the component model of standard component described in the character definition information definition inputted according to user.
- 4. component verification method as claimed in claim 3, it is characterised in that the member according to the component to be verified Device model judges whether the component to be verified and standard component are identical component, including:By the member with the standard component correspondingly of each character in the component model of the component to be verified Each character is compared in device model;When in component model of i-th of character with the standard component in the component model of the component to be verified I-th of character when belonging to identical characters, judge i-th of character in the component model of the component to be verified with it is described I-th of character in the component model of standard component matches;When in component model of i-th of character with the standard component in the component model of the component to be verified I-th of character when being not belonging to identical characters, by corresponding to i-th of character in the component model of the component to be verified Character picture and the standard component component model in i-th of character corresponding to character picture carry out template Match somebody with somebody;When the similarity that template matches obtain exceedes default similarity threshold, the component of the component to be verified is judged I-th of character in model matches with i-th of character in the component model of the standard component;Otherwise described in judging I-th of character in the component model of component to be verified and i-th of word in the component model of the standard component Symbol does not match that;When the member with the standard component correspondingly of each character in the component model of the component to be verified When each character matches in device model, judge that the component to be verified and standard component are identical component;It is no Then it is determined as the component differed.
- 5. component verification method as claimed in claim 4, it is characterised in that methods described also includes:When j-th of character in the component model of the standard component be predefined for asterisk wildcard when, treat described in judgement Verify j-th of character in the component model of component and j-th of character in the component model of the standard component Belong to identical characters.
- 6. component verification method as claimed in claim 3, it is characterised in that methods described also includes:Before Character segmentation processing is carried out to the template image, the contrast of the template image of the standard component is calculated And image preprocessing is carried out to the template image according to the contrast, until the contrast reaches default contrast threshold Value, and record the parameter of final image preprocessing;Before Character segmentation processing is carried out to the image of the component to be verified, using pre- with the template image identical Processing method and the parameter carry out image preprocessing to the image of the component to be verified.
- 7. component verification method as claimed in claim 3, it is characterised in that methods described also includes:Before Character segmentation processing is carried out to the template image, the template image is carried out at exclusive PCR connected domain Reason;Before Character segmentation processing is carried out to the image of the component to be verified, the image of the component to be verified is entered Row exclusive PCR Connected area disposal$;After character picture in the component model for obtaining the standard component corresponding to each character, to the standard Character picture in the component model of component corresponding to each character carries out exclusive PCR Connected area disposal$ respectively;After character picture in the component model for obtaining the component to be verified corresponding to each character, treated to described Verify that the character picture in the component model of component corresponding to each character carries out exclusive PCR Connected area disposal$ respectively.
- 8. a kind of component verifies device, it is characterised in that including:First image collection module, for obtaining the image of component to be verified;First Character segmentation module, for carrying out Character segmentation processing to the image of the component to be verified, obtain described treat Verify the character picture corresponding to each character in the component model of component;Device model identification module, for the word corresponding to each character in the component model according to the component to be verified Symbol image recognition goes out the component model of the component to be verified;Judge module, for judging the component to be verified and standard member according to the component model of the component to be verified Whether device is identical component.
- 9. a kind of component verifies equipment, it is characterised in that including processor, memory and be stored in the memory and It is configured as, by the computer program of the computing device, realizing such as right described in the computing device during computer program It is required that the component verification method in 1 to 7 described in any one.
- 10. a kind of computer-readable recording medium, it is characterised in that the computer-readable recording medium includes the calculating of storage Machine program, wherein, equipment where controlling the computer-readable recording medium when the computer program is run is performed as weighed Profit requires the component verification method described in any one in 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710793182.6A CN107563386A (en) | 2017-09-04 | 2017-09-04 | Component verification method, device, equipment and computer-readable storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710793182.6A CN107563386A (en) | 2017-09-04 | 2017-09-04 | Component verification method, device, equipment and computer-readable storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN107563386A true CN107563386A (en) | 2018-01-09 |
Family
ID=60978049
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710793182.6A Pending CN107563386A (en) | 2017-09-04 | 2017-09-04 | Component verification method, device, equipment and computer-readable storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107563386A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109446885A (en) * | 2018-09-07 | 2019-03-08 | 广州算易软件科技有限公司 | A kind of text based Identify chip method, system, device and storage medium |
CN110609912A (en) * | 2019-08-29 | 2019-12-24 | 百度在线网络技术(北京)有限公司 | Component information recording method, device, equipment and readable storage medium |
CN111160144A (en) * | 2019-12-16 | 2020-05-15 | 广东施富电气实业有限公司 | Method and system for identifying components by combining electric drawing with pictures and texts and storage medium |
CN112435222A (en) * | 2020-11-11 | 2021-03-02 | 深圳技术大学 | Circuit board detection method and device and computer readable storage medium |
CN112560836A (en) * | 2020-11-09 | 2021-03-26 | 联想(北京)有限公司 | Component identification method and device and computer readable storage medium |
CN113011125A (en) * | 2019-12-18 | 2021-06-22 | 海信视像科技股份有限公司 | Printed circuit board checking method, device, equipment and computer storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN105184793A (en) * | 2015-09-02 | 2015-12-23 | 广东电网有限责任公司汕尾供电局 | Electric energy meter sample appearance and PCB element detection method |
CN106650721A (en) * | 2016-12-28 | 2017-05-10 | 吴晓军 | Industrial character identification method based on convolution neural network |
CN106709490A (en) * | 2015-07-31 | 2017-05-24 | 腾讯科技(深圳)有限公司 | Character recognition method and device |
-
2017
- 2017-09-04 CN CN201710793182.6A patent/CN107563386A/en active Pending
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106709490A (en) * | 2015-07-31 | 2017-05-24 | 腾讯科技(深圳)有限公司 | Character recognition method and device |
CN105184793A (en) * | 2015-09-02 | 2015-12-23 | 广东电网有限责任公司汕尾供电局 | Electric energy meter sample appearance and PCB element detection method |
CN106650721A (en) * | 2016-12-28 | 2017-05-10 | 吴晓军 | Industrial character identification method based on convolution neural network |
Non-Patent Citations (2)
Title |
---|
柯一剑: "PCB元器件定位与识别技术研究", 《中国优秀硕士学位论文全文数据库 信息科技辑》 * |
陈孝玉等: "基于连通域的图像文本自动定位", 《微计算机信息》 * |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109446885A (en) * | 2018-09-07 | 2019-03-08 | 广州算易软件科技有限公司 | A kind of text based Identify chip method, system, device and storage medium |
CN109446885B (en) * | 2018-09-07 | 2022-03-15 | 广州算易软件科技有限公司 | Text-based component identification method, system, device and storage medium |
CN110609912A (en) * | 2019-08-29 | 2019-12-24 | 百度在线网络技术(北京)有限公司 | Component information recording method, device, equipment and readable storage medium |
CN111160144A (en) * | 2019-12-16 | 2020-05-15 | 广东施富电气实业有限公司 | Method and system for identifying components by combining electric drawing with pictures and texts and storage medium |
CN111160144B (en) * | 2019-12-16 | 2023-04-07 | 广东施富电气实业有限公司 | Method and system for identifying components by combining electric drawing with pictures and texts and storage medium |
CN113011125A (en) * | 2019-12-18 | 2021-06-22 | 海信视像科技股份有限公司 | Printed circuit board checking method, device, equipment and computer storage medium |
CN113011125B (en) * | 2019-12-18 | 2023-01-10 | 海信视像科技股份有限公司 | Printed circuit board checking method, device, equipment and computer storage medium |
CN112560836A (en) * | 2020-11-09 | 2021-03-26 | 联想(北京)有限公司 | Component identification method and device and computer readable storage medium |
CN112435222A (en) * | 2020-11-11 | 2021-03-02 | 深圳技术大学 | Circuit board detection method and device and computer readable storage medium |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107563386A (en) | Component verification method, device, equipment and computer-readable storage medium | |
CN107229932B (en) | Image text recognition method and device | |
CN103026384B (en) | Feature deriving means, feature extracting method and image processing apparatus | |
CN104809452A (en) | Fingerprint identification method | |
CN106951832B (en) | Verification method and device based on handwritten character recognition | |
CN104809464A (en) | Fingerprint information processing method | |
CN104809453A (en) | Authentication method based on fingerprints | |
CN111860525B (en) | Bottom-up optical character recognition method suitable for terminal block | |
CN108427874A (en) | Identity identifying method, server and computer readable storage medium | |
CN104867225A (en) | Banknote face orientation identification method and apparatus | |
CN109784342A (en) | A kind of OCR recognition methods and terminal based on deep learning model | |
CN110807402B (en) | Facial feature positioning method, system and terminal equipment based on skin color detection | |
CN110503682A (en) | The recognition methods of rectangle control, device, terminal and storage medium | |
CN110046617A (en) | A kind of digital electric meter reading self-adaptive identification method based on deep learning | |
CN112966685B (en) | Attack network training method and device for scene text recognition and related equipment | |
CN107358148B (en) | Anti-cheating network investigation method and device based on handwriting recognition | |
CN116258861B (en) | Semi-supervised semantic segmentation method and segmentation device based on multi-label learning | |
WO2021232670A1 (en) | Pcb component identification method and device | |
CN107786867A (en) | Image identification method and system based on deep learning architecture | |
CN109409227A (en) | A kind of finger vena plot quality appraisal procedure and its device based on multichannel CNN | |
CN113221601A (en) | Character recognition method, device and computer readable storage medium | |
CN111462388A (en) | Bill inspection method and device, terminal equipment and storage medium | |
CN111199240A (en) | Training method of bank card identification model, and bank card identification method and device | |
CN109299744A (en) | Training method, system and the recognition methods of contract official seal disaggregated model, system | |
CN109034166B (en) | Confusable character recognition model training method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20180109 |