CN106778823B - Automatic identification method for reading of pointer instrument - Google Patents

Automatic identification method for reading of pointer instrument Download PDF

Info

Publication number
CN106778823B
CN106778823B CN201611055991.9A CN201611055991A CN106778823B CN 106778823 B CN106778823 B CN 106778823B CN 201611055991 A CN201611055991 A CN 201611055991A CN 106778823 B CN106778823 B CN 106778823B
Authority
CN
China
Prior art keywords
instrument
template
pointer
maximum
straight line
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.)
Expired - Fee Related
Application number
CN201611055991.9A
Other languages
Chinese (zh)
Other versions
CN106778823A (en
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.)
State Grid Corp of China SGCC
China Three Gorges University CTGU
Yichang Power Supply Co of State Grid Hubei Electric Power Co Ltd
Original Assignee
State Grid Corp of China SGCC
China Three Gorges University CTGU
Yichang Power Supply Co of State Grid Hubei Electric Power 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 State Grid Corp of China SGCC, China Three Gorges University CTGU, Yichang Power Supply Co of State Grid Hubei Electric Power Co Ltd filed Critical State Grid Corp of China SGCC
Priority to CN201611055991.9A priority Critical patent/CN106778823B/en
Publication of CN106778823A publication Critical patent/CN106778823A/en
Application granted granted Critical
Publication of CN106778823B publication Critical patent/CN106778823B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/70Arrangements for image or video recognition or understanding using pattern recognition or machine learning
    • G06V10/74Image or video pattern matching; Proximity measures in feature spaces
    • G06V10/75Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
    • G06V10/757Matching configurations of points or features

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Theoretical Computer Science (AREA)
  • Evolutionary Computation (AREA)
  • Computing Systems (AREA)
  • Databases & Information Systems (AREA)
  • Artificial Intelligence (AREA)
  • General Health & Medical Sciences (AREA)
  • Medical Informatics (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Image Analysis (AREA)

Abstract

The invention provides an automatic reading identification method for a pointer instrument, and belongs to the field of digital image processing. The method comprises the following steps: collecting and calibrating an instrument template, and storing the template drawing, the maximum and minimum measuring ranges and units of the instrument in the template drawing and the current position reading of a pointer of the template instrument in a template library; searching the maximum and minimum scale lines and the pointer straight line of the instrument in the template drawing, and storing the angle of the maximum and minimum scale lines and the position of the center of a circle of the instrument in a template library; template matching, namely correcting the instrument image to be recognized into a front view angle image; and searching a pointer straight line in the instrument diagram to be recognized by adopting a pointer searching method, and calculating the reading of the instrument. The method adopts a template calibration method, the template library is established simply at the early stage, the maximum and minimum scale mark angles are searched for only once, the circle center position is determined and stored in the template library, the angle of the pointer of each instrument to be identified is only needed to be identified at the later stage, the information amount identified by a computer is reduced, and the reliability is high.

Description

Automatic identification method for reading of pointer instrument
Technical Field
The invention belongs to the field of digital image processing, and particularly relates to an automatic reading identification method for a pointer instrument.
Background
Pointer instrument wide application in trades such as electric power, oil, traditional artifical reading is inefficient, and work load is big, receives people's subjective factor to under certain environment, if receive factors such as mounted position height, be difficult to carry out artifical reading. The image processing technology is applied to automatic identification of meter reading, efficiency can be improved, workload of personnel is reduced, and personal safety is guaranteed.
The existing pointer type instrument reading automatic identification method based on the image processing technology mainly relates to the searching of scale marks, pointer searching, scale number identification and circle center positioning. Because the actual picture is influenced by factors such as light, dirt on the dial plate and the like and is fuzzy, information identification such as tiny scale marks, numbers and the like cannot be realized, and the automatic identification of the meter reading fails. For the circle center positioning of the instrument dial, the circle center is determined by searching the instrument scale mark and fitting a circle in the prior art, but the information amount of an instrument picture is large, and the instrument scale mark, especially the searching of a small scale mark, is difficult to determine in an actual picture.
The prior patent CN101620682A, named as a pointer instrument reading method, adopts the following method: establishing scale query tables of different instruments to form a database; collecting an instrument image, inputting the instrument image and preprocessing the instrument image so as to extract an effective identification area of an instrument dial; extracting the pointer and the scale mark of the instrument by utilizing the stroke characteristics of the pointer and the scale mark from the effective identification area of the instrument dial; and matching the extracted scale marks with corresponding scale query tables in a scale query table database according to the extracted pointer and the extracted scale marks, and automatically identifying the reading. The database established in the early stage of the method is complicated and has very large workload.
Known techniques to which the present invention relates include:
1) a template picture is given, the instrument image collected in field application is subjected to tilt correction to obtain a front view of the instrument image so as to improve the accuracy of pointer reading identification, matching of image key points is achieved by adopting the existing SIFT algorithm, a perspective transformation matrix is obtained through the key points obtained through matching, and then the picture similar to the template picture is subjected to tilt correction.
2) ID number identification technology of the meter. When reading automatic image recognition needs to be carried out on a plurality of meters, the meter image is required to be recognized to belong to which meter. The two-dimension code label can be pasted on each instrument in advance, so that no matter the template drawing of the instrument and the instrument drawing to be read which is collected on site all contain two-dimension code images, the two-dimension code in the image is identified by adopting mature two-dimension code identification software, and the ID number of the instrument can be obtained.
Disclosure of Invention
The invention aims to provide an automatic identification method for reading of a pointer instrument aiming at the defects of the prior art, the method can reduce the information amount required by computer identification, improve the success rate and the accuracy rate of automatic identification of the reading of the instrument, and the establishment of a template library at the early stage is simple.
The invention provides an automatic reading identification method for a pointer instrument, which comprises the following steps:
1) collecting and calibrating an instrument template drawing which is a front view angle drawing shot for an instrument, and storing the instrument template drawing, the maximum and minimum measuring ranges and units of the instrument in the instrument template drawing and the reading of the instrument in the instrument template drawing in a template library;
2) searching the maximum and minimum measuring range scale lines and the pointer straight line of the instrument in the template drawing, determining the circle center position, and storing the angle of the maximum and minimum measuring range scale line and the circle center position of the instrument dial in a template library;
3) key point matching is carried out on the instrument graph to be recognized and the instrument template graph in the template library, and after a perspective transformation matrix is obtained, the instrument graph to be recognized is corrected into a front view angle graph;
4) and searching a pointer straight line in the instrument diagram to be identified by adopting a pointer searching method of self-adaptive parameters, and calculating the reading of the instrument.
The searching method of the maximum and minimum measuring range scale mark and the determination of the circle center position in the step 2) are judged according to the following conditions, 1, the relative angle difference of the maximum and minimum measuring range scale mark and the pointer straight line is in a proportional relation with the relative reading difference; 2. the scale mark of the maximum and minimum measuring ranges and the pointer are intersected at the circle center; 3. the method for searching the straight line adopts a method with adaptive parameter searching. (for the searching method of the maximum and minimum measuring range scale mark of the instrument in the template picture and the determination of the circle center position, only one time is needed in the whole image recognition method, the recognition results such as the circle center position of the instrument dial and the angle of the maximum and minimum measuring range scale mark are stored in a template library, and only the information in the template library needs to be called in the later instrument reading recognition process.)
The searching of the maximum and minimum measuring range scale mark of the instrument in each template drawing and the determination of the circle center position specifically comprise the following steps:
21) finding out the straight line pairs which satisfy the slope relation in the instrument template graph according to the slope relation of the maximum and minimum measuring range scale straight line of the instrument, wherein n pairs are provided;
22) according to the angle of each pair of straight lines, the maximum and minimum measuring ranges of the meters in the template graph and the meter reading in the template graph, if the ith pair of straight lines is the scale mark of the maximum and minimum measuring ranges, the angle of the pointer of the template is thetai, and the intersection point coordinate (x) of the ith pair of straight lines is calculatedi,yi),i=0,1…n;
23) Find the angle in the template map of the instrument is thetai, and pass the coordinate (x)i,yi) If there is such a straight line, the ith straight line is the maximum minimum measurement range scale line and the center of the circle is (x)i,yi) And the angle theta of the scale mark of the maximum measuring range is measuredmaxAngle theta of minimum range scale markminAnd center coordinates (x)i,yi) Stored in a template library.
The pointer searching method for the adaptive parameters in the step 4) searches for a pointer straight line in the instrument diagram to be recognized, and calculates the meter reading, and specifically includes: when the reading of the meter is identified, according to the angles of the scale marks of the maximum range and the minimum range of the template picture in the template library, the maximum range and the minimum range, the pointer in the meter picture which is corrected to be the front view is searched, and the angle is calculated, namely the reading of the meter (the information quantity required to be identified is small) is obtained as follows:
Figure BDA0001159007110000031
where θ is the angle of the pointer of the instrument in the graph to be identified, and θmaxIs the angle of the maximum range scale line, θminIs the angle of the minimum range scale, SmaxIs the maximum range reading, SminAnd S is the reading of the meter in the meter diagram to be identified.
Angle theta of maximum range scale markmaxAngle theta of minimum range scale markminMaximum measuring range SmaxMinimum measuring range SminAll parameters of the instrument are stored in the template library and can be obtained in the template library, and the reading of the instrument can be obtained only by identifying the straight line of the pointer of the instrument and calculating the angle theta of the pointer.
The pointer searching method for the adaptive parameters in the step 2) and the step 4) specifically comprises the steps of enabling a linear equation y in an image space to be k · x + b, expressing r ═ x · cos β + y · sin β in a polar coordinate mode, and discretizing the parameter space into A (r · cos β + y · sin β)ii) Accumulator unit for pixel point (x) in imagei,yi) Performing Hough transform, βiR is obtained by calculating discrete values in traversal [0, pi ]iThen A (r)ii) The value of the accumulator unit represented adds 1; the method comprises the following specific steps:
(1) randomly selecting a point (x) in a set of feature pointsi,yi) If the point is not detected, the Hough transformation is carried out on the point;
(2) if there is some accumulator A (r)ii) Is greater than or equal to the threshold value N1Then the corresponding parameter r is outputiAnd βiThen clear the accumulator A (r)ii);
(3) According to the obtained straight line parameters, finding out the straight line l corresponding to the point in the original imagekMarking all the characteristic points belonging to the straight line as detected;
(4) straight line lkLength L ofkThreshold value L1If L isk≥L1If the detected straight line meets the threshold value of accumulator parameter and length parameter, recording the straight line lkIn set M;
(5) if the points which are not detected yet exist in the point set, returning to the step (1) to continue the detection;
(6) selecting a pointer straight line from the straight line set M detected in the step (4), and finding out the pointer straight line in the set M according to the angle of the straight line or the distance from the circle center to the straight line; if no pointer straight line exists, changing the accumulator threshold parameter or straight line length threshold parameter of Hough transformation, and clearing the straight line set M;
(7) if the accumulator threshold parameter N1Linear length threshold parameter L1In the case that no straight line of the pointer is found, as long as the accumulator threshold parameter N1Lower limit value N not less than threshold value2Changing the accumulator threshold N1=N1-N0And (5) repeating the steps (1) - (6) until a pointer straight line is found, and ending the iteration. Wherein N is0Is the accumulator threshold step size; if the accumulator threshold value N1Lower limit value N less than threshold value2If no pointer straight line is found, the length of the straight line is changed to be the threshold parameterCounting; if straight line length threshold L1Lower limit value L not less than threshold value2Changing the accumulator threshold parameter, L1=L1-L0And (6) repeating the steps (1) - (6) until a pointer straight line is found, and ending the iteration, wherein L0Is a straight line length threshold step.
Compared with the prior art, the invention has the advantages that:
(1) and a pointer straight line searching method adopting self-adaptive parameters. The accumulator threshold and the straight line length threshold in Hough transformation are two important parameters for judging the straight line of the pointer. Because the characteristics of each picture are different, different pictures need to be provided with different parameters to find the straight line of the pointer. The adaptive parameter algorithm can automatically adjust two important parameter values of the threshold value of the accumulator and the threshold value of the linear length according to the actual situation of each picture until the pointer linear is found.
(2) And establishing a template library comprising template pictures, maximum and minimum measuring ranges, current reading of the instrument and units. The circle center position of the template picture instrument and the angle of the maximum and minimum scale lines are determined and stored in the template library, the process is only needed to be carried out once in the whole image recognition program, information in the template library is only needed to be called in the later instrument recognition process, and the template library is simple to establish.
(3) When the template calibration method is adopted to read and identify the instrument graph to be identified, which is corrected into the front view, the angle of the maximum range scale mark, the angle of the minimum range scale mark, the maximum range and the minimum range can be obtained in the template library, only the straight line and the angle of the instrument pointer need to be searched, information such as fine scale marks, numbers and the like in a picture does not need to be identified, the information amount identified by a computer is greatly reduced, and the reliability is improved.
Drawings
Fig. 1 is a flow chart of an automatic identification method for reading of a pointer instrument according to the present invention.
Detailed Description
The invention provides an automatic reading identification method for a pointer instrument, which is further explained by combining the attached drawings and the detailed implementation mode.
The invention provides an automatic identification method for reading of a pointer instrument, which is shown in a flow chart of figure 1 and comprises the following steps:
step 1: collecting and calibrating an instrument template drawing of each instrument, wherein the instrument template drawing is a front view angle drawing shot for the instrument, and the instrument template drawing, the maximum and minimum measuring ranges and units of the instrument and the reading of the instrument in the instrument template drawing are stored in a template library;
step 2: searching the scale mark of the maximum and minimum measuring ranges and the straight line of the pointer of the instrument in the template drawing, determining the circle center position of the dial, and storing the angle of the scale mark of the maximum and minimum measuring ranges and the circle center position of the dial of the instrument in a template library;
the searching method of the maximum and minimum measuring range scale mark and the determination of the circle center position are judged according to the following conditions: 1. the relative angle difference of the maximum and minimum measuring range scale mark and the pointer straight line is in proportional relation with the relative reading difference; 2. the scale mark of the maximum and minimum measuring ranges and the straight line of the pointer intersect at the circle center of the dial; 3. the linear search method adopts a self-adaptive search method with robustness;
the searching of the maximum and minimum measuring range scale lines of the instrument in the template drawing and the determination of the circle center position are carried out only once in the whole image recognition program, and the information in the template library is only needed to be called in the later instrument recognition process, namely the angle between the circle center position of the instrument and the maximum and minimum measuring range scale lines is obtained from the template library. The method comprises the following steps of (1) searching the maximum and minimum measuring range scale mark of the instrument in each template graph and determining the circle center position:
21) according to the slope relation of the maximum and minimum measuring range scale straight line of the instrument, finding out a straight line pair (a group of maximum and minimum straight lines become a straight line pair) which meets the slope relation in the template graph;
the angle difference corresponding to the slope of the maximum and minimum scale lines is α0When actually looking up the scale mark, the range of the angle difference is [ α ]0-20,α0+20]Finding two straight lines in the template graph which satisfy the following relations:
wherein the coordinates of two end points of a straight line are (x)1,y1),(x2,y2) The coordinates of two end points of another straight line are (x)3,y3),(x4,y4). Assuming that the linear pairs meeting the condition are searched according to the constraint of the formula (1) and n pairs are in total;
22) judging according to the angle of each pair of straight lines, the maximum and minimum measuring ranges in the template drawing and the reading number of the meter in the template drawing, if the ith pair of straight lines is the scale mark of the maximum and minimum measuring ranges, the angle of the template pointer is theta0iIn this embodiment, the angle is defined by taking the center of a circle as the origin, taking the downward vertical axis as 0 ° and clockwise as positive, and the angle range is [0 °, 360 ° ]](ii) a Calculating the angle theta of the template pointer0iIs represented by formula (2):
Figure BDA0001159007110000052
wherein S ismaxIs the maximum range, SminIs the minimum range, S0Obtaining the reading of the instrument pointer in the template drawing from a template library; theta1iIs the angle theta of the scale mark with the minimum measuring range in the ith pair of scale marks2iThe angle of the maximum measuring range scale mark in the ith pair of scale marks;
calculating the coordinate (x) of the intersection point of the ith pair of straight lines according to the formula (2)i,yi),i=0,1…n;
23) Finding the angle theta in the instrument template picture0iAnd by the coordinates (x)i,yi) If there is such a straight line, the ith straight line is the maximum and minimum measurement scale line, and the center of the meter in the template diagram is (x)i,yi) And the angle theta of the scale mark of the maximum measuring range is measuredmaxAngle theta of minimum range scale markminAnd center coordinates (x)i,yi) Storing in a template library;
in the embodiment, the angle theta in the template picture of the lookup instrument is0iAnd by the coordinates (x)i,yi) Is searched as:
The linear equation y in image space is k x + b (where k is slope and b is y-axis intercept) expressed in polar coordinate form as r x cos β + y sin β r ≧ 0,0 ≦ β < π;
coordinates (x, y) of a point in a rectangular coordinate system, two parameters corresponding to the coordinate position of a point in a polar coordinate system are r and β, r represents the length from the point to the origin of coordinates and is called the radius of the pole, β is called the polar angle of the point, i.e. the angle of 0 degrees with respect to the horizontal;
to find the straight line segment of these points, the two parameters of the polar coordinate position are parameterized into a number of accumulator units A (r)ii). For the midpoint (x) of the imagei,yi) Performing Hough transform, βiR is obtained by calculating discrete values in traversal [0, pi ]iThen A (r)ii) The value of the accumulator unit represented adds 1;
in this embodiment, two important parameter values, namely an accumulator threshold value and a straight line length threshold value, are automatically adjusted according to the actual situation of each picture until the maximum and minimum scale straight line is found; the method comprises the following specific steps:
231) randomly selecting a point (x) in a set of feature pointsi,yi) If the point is not detected, the Hough transformation is carried out on the point;
232) if there is some accumulator A (r)ii) Is greater than or equal to the accumulator threshold N1(the initial value may be 50% of the target straight line length pixel value) the corresponding straight line parameter r is outputiAnd βiThen clear the accumulator A (r)ii);
233) According to the obtained straight line parameter riAnd βiFinding out the straight line l corresponding to the point in the original imagekAnd all the characteristic points (determined by the known technology) belonging to the straight line are marked as detected;
234) straight line lkLength L ofkLength parameter threshold L1(the initial value may be 50% of the pixel value of the target straight line length) if Lk≥L1Indicating that the detected line satisfies the accumulator parameterLength parameter threshold L1Then record the straight line lkIn the feature point set M;
235) if the feature point set has points which are not detected yet, returning to the step 231) to continue detecting, otherwise, turning to the step 234);
236) selecting a pointer straight line from the feature point set M of the straight lines detected in the step 234), and finding out a straight line meeting the following conditions from the feature point set M according to the angle of the straight line and the distance from the center of the circle to the straight line:
Figure BDA0001159007110000061
wherein, thetaiIs a straight line liAngle, diIs the distance from the center of the circle to the straight line, theta0The angle difference threshold (related to the image resolution, the higher the pixel, the smaller the value, which may be generally 5% by error, in this example, 5% of the maximum and minimum scale angle difference), and D is the distance threshold (related to the image resolution, the higher the pixel, the smaller the value, which may be 10 for an image with a resolution of 600 × 400 pixels).
If no pointer straight line exists, clearing the straight line set M (needing to change the accumulator threshold parameter or the straight line length threshold parameter of Hough transformation);
237) if the accumulator threshold parameter N1Lower limit value N not less than threshold value2Changing the accumulator threshold N1=N1-N0Repeating steps 231) -236) until a pointer straight line pair is found, ending the iteration, and turning to step 238); wherein N is0A threshold step size for the accumulator (related to image resolution, the higher the pixels, the smaller the value, and for 600 × 400 pixels, it can be set to 5);
if the accumulator threshold value N1Lower limit value N less than threshold value2If the pointer straight line pair is not found, changing the straight line length threshold parameter; if straight line length threshold L1Lower limit value L not less than threshold value2Changing the accumulator threshold parameter, L1=L1-L0Repeating steps 231) -236) until a pointer is foundLine pair, end iteration, where L0A threshold step length (related to image resolution, the higher the pixel, the smaller the value, and for an image with a resolution of 600 × 400 pixels, it may be set to 5), go to step 238);
238) if the i-th straight line condition is met, the pointer straight line pair l meeting the requirement in the step 233) can be foundiIf the pair of straight lines is the scale line of measuring range, the center of the meter is the intersection point P (x) of two straight lines0,y0) The minimum and maximum range straight line angles are respectively thetaminmax
x=xi,y=yi
θmin=θ1imax=θ2i
The coordinate of the center position of the meter and the scale mark angle with the maximum and minimum measuring ranges are searched and placed in a template library;
and step 3: the method comprises the following steps of collecting an instrument image to be recognized, matching the instrument image to be recognized with instrument template images in a template library, finding out the template image corresponding to the instrument image to be recognized, and correcting the instrument image to be recognized into a front view angle image, and specifically comprises the following steps:
31) and identifying the two-dimensional code of the instrument image to obtain an instrument ID value corresponding to the image, and finding the template drawing and the instrument parameters of the instrument in the template library according to the ID value of the instrument.
32) According to the instrument drawing to be recognized and the template drawing thereof, the drawing to be recognized is corrected into a front view: the method specifically comprises the following steps (because the algorithm is a conventional classical algorithm in image recognition, the following descriptions are directly cited in books, and the terms do not need to be explained in detail again):
321) scale space extremum detection
Obtaining a scale space representation L (x, y, sigma) under different scales by convolution of the two-dimensional image I (x, y) and the Gaussian kernel G (x, y, sigma); establishing a DOG (Difference-of-Gaussian) pyramid of the images, detecting extrema in 26 fields in the DOG scale space, D (x, y, sigma) being the Difference between two adjacent scale images, namely:
d (x, y, σ) (G (x, y, k σ) -G (x, y, σ)) × I (x, y) ((x, y, k σ)) × L (x, y, σ) in the formula:a two-dimensional gaussian function, where x and y represent coordinates of an image point, σ represents a variance of a gaussian normal distribution, and L (x, y, σ) ═ G (x, y, σ) × I (x, y) is defined in a scale space;
if a point is the maximum or minimum in 26 neighborhoods of the eight surrounding points and eighteen neighborhood points of the upper and lower layers, the point is a feature point of the image at the scale.
322) Accurate positioning of key points
The positions and the scales of the key points are accurately determined by fitting the feature points with a three-dimensional quadratic function, and meanwhile, the key feature points with low contrast and unstable edge response points are removed, so that the matching stability is enhanced, and the anti-noise capability is improved;
323) keypoint direction assignment
And (3) assigning a direction parameter for each key point by using the gradient direction distribution characteristic of the neighborhood pixels of the key points, so that the operator has rotation invariance.
Figure BDA0001159007110000081
Figure BDA0001159007110000082
Wherein m (x, y) is the modulus of the gradient at (x, y), the modulus theta (x, y) is the direction of the gradient at (x, y), and the scale of L is the scale of each keypoint.
324) Generating SIFT feature vectors
And rotating the coordinate axis to the direction of the characteristic point to ensure the rotation invariance. In the actual calculation process, in order to enhance the robustness of matching, 16 seed points of 4 × 4 are used for describing each keypoint, so that 128 pieces of data can be generated for one keypoint, that is, a 128-dimensional SIFT feature vector (i.e., a feature descriptor) is finally formed. The SIFT feature descriptors have good invariance to illumination, noise, rotation and scale.
325) Feature matching
After SIFT feature vectors of the images are generated, Euclidean distance of the feature vectors of key points in the two images is used as similarity judgment measurement, a certain key point in a source image (template image) is taken, the first two key points with the nearest Euclidean distance in the image to be matched are found out, and if the nearest distance divided by the next nearest distance in the two key points is smaller than a certain proportion threshold value, the pair of matching points are accepted.
326) Solving a perspective transformation matrix M according to the key points obtained by matching; 4 matched feature point locations (p) of a template graph0,q0),(p1,q1),(p2,q2),(p3,q3) Position (u) of the corresponding 4 matching feature points of the image to be recognized0,v0),u1,v1),(u2,v2),(u3,v3) And a 3 x 3 perspective transformation matrix M relation exists between the graph to be identified and the template graph:
Figure BDA0001159007110000083
wherein, aij(i 1,2, 3; j 1,2,3) is a specific value of each element in the perspective transformation matrix M.
The correspondence between the 4 feature points of the template graph and the 4 feature points of the graph to be recognized can be expressed as:
Figure BDA0001159007110000084
wherein i is 0, 1,2,3, and w is a parameter.
327) And according to the obtained transformation matrix, obtaining the coordinate position and the pixel value of the image to be recognized under the condition of the normal viewing angle according to the coordinate of each pixel point of the image to be recognized according to the transformation relation, and correcting the image to be recognized into a front view.
And 4, step 4: searching a pointer straight line in the instrument diagram to be identified by adopting a pointer searching method of self-adaptive parameters, and calculating the reading of the instrument; the algorithm for searching the straight line in the image in the step 4 is the same as that for searching the straight line in the image in the step 2, the difference is that the straight line pair needs to be found in the step 2, namely the maximum and minimum scale lines are found at the same time, and the step 4 only needs to find the straight line of the instrument pointer, so that the selection of the calculation parameters in the step 4 can be carried out by referring to the selection specification of the parameters in the step 2.
According to the angles of the scale lines of the maximum range and the minimum range of the existing template pictures in the template library, the maximum range and the minimum range, the reading of the instrument can be obtained only by searching the pointer in the instrument picture which is corrected to be the front view and calculating the straight line angle of the pointer. The method for searching the pointer straight line in the instrument diagram through Hough transformation specifically comprises the following steps:
41) randomly selecting a point (x) of a set of image pointsi,yi) If the point is not detected, the hough transformation is carried out on the point;
42) accumulator A (r)ii) Has a value of NiThreshold value N1If N is presenti≥N1Then the corresponding parameter r is outputiAnd βiThen clear the accumulator A (r)ii);
43) According to the obtained straight line parameters, finding out the straight line l corresponding to the point in the original imagekMarking all the characteristic points belonging to the straight line as detected;
44) straight line lkLength L ofkThreshold value L1If L isk≥L1If the detected straight line meets the threshold value of accumulator parameter and length parameter, recording the straight line lkIn set M;
45) if the points which are not detected yet exist in the point set, returning to the step 41) to continue the detection;
46) selecting a pointer straight line from the straight line set M detected in the step 44), and satisfying d according to the distance from the circle center to the straight lineiAnd finding out the straight line of the pointer in the set M when the number of the pointer in the set M is less than or equal to D. Wherein d isiIs from the center of a circle to a straight lineD is a distance threshold.
If no pointer straight line exists, the threshold parameter of the accumulator of Hough transformation or the threshold parameter of the straight line length needs to be changed, and the straight line set M is cleared.
47) If the accumulator threshold parameter N1Linear length threshold parameter L1In the case that no straight line of the pointer is found, as long as the accumulator threshold parameter N1Lower limit value N not less than threshold value2Changing the accumulator threshold N1=N1-N0And repeating the steps 41) -46) until a pointer straight line is found, and ending the iteration. Wherein N is0Is the accumulator threshold step size; if the accumulator threshold value N1Lower limit value N less than threshold value2If the pointer straight line is not found, changing the length threshold parameter of the straight line; if straight line length threshold L1Lower limit value L not less than threshold value2Changing the accumulator threshold parameter, L1=L1-L0Repeating steps 41) -46) until a pointer line is found, ending the iteration, wherein L0Is a straight line length threshold step.
48) The reading S of the meter is identified,
Figure BDA0001159007110000091
where θ is the angle of the pointer of the instrument in the graph to be identified, θmaxIs the angle of the maximum range scale line, θminIs the angle of the minimum range scale, SmaxIs the maximum range, SminIs the minimum range.

Claims (2)

1. A pointer instrument reading automatic identification method is characterized by comprising the following steps:
1) collecting and calibrating an instrument template drawing, wherein the instrument template drawing is a front view angle drawing of an instrument, and reading the instrument template drawing, the maximum and minimum measuring ranges and units of the instrument in the instrument template drawing and the current position of an instrument pointer in the instrument template in a template library;
2) searching the maximum and minimum measuring range scale lines and the pointer straight line of the instrument in the template drawing, and storing the calculated angle of the maximum and minimum measuring range scale line and the circle center position of the instrument dial in a template library; the searching method of the maximum and minimum measuring range scale mark and the determination of the circle center position are judged according to the following conditions, 1, the relative angle difference of the maximum and minimum measuring range scale mark and the pointer straight line is in proportional relation with the relative reading difference; 2. the scale mark of the maximum and minimum measuring ranges and the pointer are intersected at the circle center; 3. the line searching method adopts a self-adaptive parameter searching method; the method comprises the following steps of (1) searching the maximum and minimum measuring range scale mark of the instrument in each template graph and determining the circle center position:
21) finding out the straight line pairs which satisfy the slope relation in the instrument template graph according to the slope relation of the maximum and minimum measuring range scale straight line of the instrument, wherein n pairs are provided;
22) according to the angle of each pair of straight lines, the maximum and minimum measuring ranges of the meters in the template drawing and the meter reading in the template drawing, if the ith pair of straight lines is the scale mark of the maximum and minimum measuring ranges, the angle of the pointer of the template is calculated to be theta0iAnd coordinates (x) of intersection of ith pair of straight linesi,yi),i=0,1…n;
23) Finding out the angle theta in the template diagram of the instrument0iAnd by the coordinates (x)i,yi) The ith straight line is the scale line with the maximum and minimum measuring ranges, and the circle center is (x)i,yi) And the angle theta of the scale mark of the maximum measuring range is measuredmaxAngle theta of minimum range scale markminAnd center coordinates (x)i,yi) Storing in a template library;
3) key point matching is carried out on the instrument graph to be recognized and the instrument template graph in the template library, and after a perspective transformation matrix is obtained, the instrument graph to be recognized is corrected into a front view angle graph;
4) and searching a pointer straight line in the instrument diagram to be identified by adopting a pointer searching method of self-adaptive parameters, and calculating the reading of the instrument.
2. The automatic identification method of the reading of the pointer instrument as claimed in claim 1, characterized in that: the pointer searching method of the self-adaptive parameters in the step 4) searches for a pointer straight line in the instrument diagram to be identified, and calculates the reading of the instrument, and specifically comprises the following steps: when the reading of the meter is identified, according to the angles of the scale marks of the maximum range and the minimum range of the template picture in the template library, the maximum range and the minimum range, the pointer in the meter picture which is corrected to be the front view is searched, and the angle is calculated, namely the reading of the meter is obtained as follows:
Figure FDA0002271074180000011
where θ is the angle of the pointer of the instrument in the graph to be identified, and θmaxIs the angle of the maximum range scale line, θminIs the angle of the minimum range scale, SmaxIs the maximum range reading, SminThe reading is the minimum measuring range reading, and S is the reading of the meter in the meter diagram to be identified;
angle theta of maximum range scale markmaxAngle theta of minimum range scale markminMaximum measuring range SmaxMinimum measuring range SminAll parameters are parameters of the instrument stored in the template library, and the reading of the instrument can be obtained only by identifying the straight line of the pointer of the instrument and calculating the angle theta of the straight line.
CN201611055991.9A 2016-11-22 2016-11-22 Automatic identification method for reading of pointer instrument Expired - Fee Related CN106778823B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201611055991.9A CN106778823B (en) 2016-11-22 2016-11-22 Automatic identification method for reading of pointer instrument

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201611055991.9A CN106778823B (en) 2016-11-22 2016-11-22 Automatic identification method for reading of pointer instrument

Publications (2)

Publication Number Publication Date
CN106778823A CN106778823A (en) 2017-05-31
CN106778823B true CN106778823B (en) 2020-02-07

Family

ID=58912991

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201611055991.9A Expired - Fee Related CN106778823B (en) 2016-11-22 2016-11-22 Automatic identification method for reading of pointer instrument

Country Status (1)

Country Link
CN (1) CN106778823B (en)

Families Citing this family (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107292871A (en) * 2017-06-08 2017-10-24 国网青海省电力公司检修公司 A kind of real-time correction algorithm of transformer station's round meter
CN107729906B (en) * 2017-10-24 2021-11-02 国网江苏省电力公司南京供电公司 Intelligent robot-based inspection point ammeter numerical value identification method
CN107766836A (en) * 2017-11-07 2018-03-06 国网黑龙江省电力有限公司检修公司 A kind of circular deflection readings of pointer type meters antidote
CN108009535A (en) * 2017-11-21 2018-05-08 武汉中元华电科技股份有限公司 A kind of simple pointer meter reading method based on machine vision
CN108491838B (en) * 2018-03-08 2021-08-03 南京邮电大学 Pointer type instrument indicating number reading method based on SIFT and HOUGH
CN109145699A (en) * 2018-06-04 2019-01-04 浙江立石机器人技术有限公司 Instrument image recognition methods and device
CN108960226B (en) * 2018-07-12 2021-12-17 南方电网电力科技股份有限公司 Pointer instrument type representation value reading method and device
CN109508709B (en) * 2018-09-29 2021-09-21 中国南方电网有限责任公司超高压输电公司检修试验中心 Single pointer instrument reading method based on machine vision
CN109409385B (en) * 2018-10-16 2021-02-19 南京鑫和汇通电子科技有限公司 Automatic identification method for pointer instrument
CN110188746A (en) * 2019-04-19 2019-08-30 南京大学 A kind of segmentation and recognition methods towards digital lcd
CN110111387B (en) * 2019-04-19 2021-07-27 南京大学 Dial plate characteristic-based pointer meter positioning and reading method
CN110245597B (en) * 2019-06-06 2021-07-16 重庆邮电大学 Pointer instrument universality identification method
CN110378326B (en) * 2019-07-08 2021-10-08 宁波大学科学技术学院 Mechanical pointer pressure gauge reading identification method
CN110503144A (en) * 2019-08-15 2019-11-26 南京天创电子技术有限公司 A kind of pointer instrument recognition methods for crusing robot
CN110796095B (en) * 2019-10-30 2022-08-09 浙江大华技术股份有限公司 Instrument template establishing method, terminal equipment and computer storage medium
CN110864881B (en) * 2019-11-27 2021-03-16 航天科技控股集团股份有限公司 Indicator lamp correctness detection method based on visual system
CN111027531A (en) * 2019-12-10 2020-04-17 联想(北京)有限公司 Pointer instrument information identification method and device and electronic equipment
CN111860464B (en) * 2020-08-07 2021-12-07 成都交大光芒科技股份有限公司 Substation auxiliary monitoring system pointer reading identification compensation method and device
CN112001318A (en) * 2020-08-25 2020-11-27 广东光速智能设备有限公司 Identity document information acquisition method and system
CN112418222B (en) * 2020-12-07 2023-07-25 安徽江淮汽车集团股份有限公司 Vehicle-mounted liquid crystal combination meter identification method, device, equipment and storage medium
CN112488030A (en) * 2020-12-11 2021-03-12 华能华家岭风力发电有限公司 Pointer instrument meter reading method based on machine vision
CN113361461A (en) * 2021-06-29 2021-09-07 浙江中控技术股份有限公司 Pointer instrument identification method and system based on intelligent terminal

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4092584A (en) * 1977-04-21 1978-05-30 Sun Electric Corporation Dwell measuring apparatus
CN101620682A (en) * 2008-06-30 2010-01-06 汉王科技股份有限公司 Method and system for automatically identifying readings of pointer type meters
CN101650198A (en) * 2009-08-25 2010-02-17 广州粤能电力科技开发有限公司 Image processing method for reading pointer type instrument indication value
CN103134546A (en) * 2012-12-14 2013-06-05 中国人民解放军63963部队 Semi-automatic examination method for special vehicle pointer instrument
CN103164692A (en) * 2012-12-03 2013-06-19 北京科技大学 Special vehicle instrument automatic identification system and algorithm based on computer vision
CN103310203A (en) * 2013-06-27 2013-09-18 河海大学常州校区 Pointer type instrument indicating value automatic identification device and method on basis of internet of things and machine vision
CN104392206A (en) * 2014-10-24 2015-03-04 南京航空航天大学 Image processing method for automatic pointer-type instrument reading recognition
CN104410829A (en) * 2014-11-27 2015-03-11 无锡北斗星通信息科技有限公司 Method for automatically reading meter

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9135492B2 (en) * 2011-09-20 2015-09-15 Honeywell International Inc. Image based dial gauge reading

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4092584A (en) * 1977-04-21 1978-05-30 Sun Electric Corporation Dwell measuring apparatus
CN101620682A (en) * 2008-06-30 2010-01-06 汉王科技股份有限公司 Method and system for automatically identifying readings of pointer type meters
CN101650198A (en) * 2009-08-25 2010-02-17 广州粤能电力科技开发有限公司 Image processing method for reading pointer type instrument indication value
CN103164692A (en) * 2012-12-03 2013-06-19 北京科技大学 Special vehicle instrument automatic identification system and algorithm based on computer vision
CN103134546A (en) * 2012-12-14 2013-06-05 中国人民解放军63963部队 Semi-automatic examination method for special vehicle pointer instrument
CN103310203A (en) * 2013-06-27 2013-09-18 河海大学常州校区 Pointer type instrument indicating value automatic identification device and method on basis of internet of things and machine vision
CN104392206A (en) * 2014-10-24 2015-03-04 南京航空航天大学 Image processing method for automatic pointer-type instrument reading recognition
CN104410829A (en) * 2014-11-27 2015-03-11 无锡北斗星通信息科技有限公司 Method for automatically reading meter

Non-Patent Citations (5)

* Cited by examiner, † Cited by third party
Title
"Pointer-type Meter Reading Method Research Based on Image Processing Technology";Guan Yudong等;《Second International Conference on Networks Security,Wireless Communications and Trusted Computing》;20101231;第107-110页 *
"基于图像处理的指针式仪表智能识别方法研究";杨志娟等;《计算机测量与控制》;20151231;第23卷(第5期);第1717-1720页 *
"基于彩色区域识别快速报警指针识别算法";刘薇等;《电测与仪表》;20141025;第51卷(第20期);第25-29页 *
"基于改进的Hough变换的指针识别算法";王高登等;《现代电子技术》;20160815;第39卷(第16期);第23-26页 *
"模板匹配机械指针式压力表示值智能识别方法研究";李汲峰等;《中国计量》;20131030(第10期);第73-75页 *

Also Published As

Publication number Publication date
CN106778823A (en) 2017-05-31

Similar Documents

Publication Publication Date Title
CN106778823B (en) Automatic identification method for reading of pointer instrument
CN107609557B (en) Pointer instrument reading identification method
CN112906694B (en) Reading correction system and method for transformer substation inclined pointer instrument image
CN103077512B (en) Based on the feature extracting and matching method of the digital picture that major component is analysed
CN102236794B (en) Recognition and pose determination of 3D objects in 3D scenes
US8994723B2 (en) Recognition and pose determination of 3D objects in multimodal scenes
CN103337052B (en) Automatic geometric correcting method towards wide cut remote sensing image
JP5385105B2 (en) Image search method and system
CN107392215A (en) A kind of multigraph detection method based on SIFT algorithms
CN109508709B (en) Single pointer instrument reading method based on machine vision
CN107240130B (en) Remote sensing image registration method, device and system
CN107292925A (en) Based on Kinect depth camera measuring methods
CN103177444A (en) Automatic SAR (synthetic-aperture radar) image rectification method
CN110930456A (en) Three-dimensional identification and positioning method of sheet metal part based on PCL point cloud library
CN108491838A (en) Pointer-type gauges registration read method based on SIFT and HOUGH
CN110288612B (en) Nameplate positioning and correcting method and device
Daixian SIFT algorithm analysis and optimization
CN108182705A (en) A kind of three-dimensional coordinate localization method based on machine vision
Arican et al. Scale-invariant features and polar descriptors in omnidirectional imaging
CN114358166B (en) Multi-target positioning method based on self-adaptive k-means clustering
Chen et al. Robust local feature descriptor for multisource remote sensing image registration
CN114863129A (en) Instrument numerical analysis method, device, equipment and storage medium
CN106780294B (en) Circular arc matching method based on feature descriptors
Wang et al. Optimized SIFT image matching algorithm
CN117058008A (en) Remote sensing image geometry and radiation integrated correction method, device, equipment and medium

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
GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20200207

Termination date: 20201122