CN115631219A - Interpretation method and system for processing data image in image matching mode - Google Patents
Interpretation method and system for processing data image in image matching mode Download PDFInfo
- Publication number
- CN115631219A CN115631219A CN202211188625.6A CN202211188625A CN115631219A CN 115631219 A CN115631219 A CN 115631219A CN 202211188625 A CN202211188625 A CN 202211188625A CN 115631219 A CN115631219 A CN 115631219A
- Authority
- CN
- China
- Prior art keywords
- image
- actuator
- data
- matching
- action
- 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
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/30—Determination of transform parameters for the alignment of images, i.e. image registration
- G06T7/32—Determination of transform parameters for the alignment of images, i.e. image registration using correlation-based methods
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/30—Determination of transform parameters for the alignment of images, i.e. image registration
- G06T7/35—Determination of transform parameters for the alignment of images, i.e. image registration using statistical methods
Abstract
The invention discloses an interpretation method and system for processing data images in an image matching mode, which comprises the steps of automatically segmenting actuator data to obtain actuator displacement angle data and actuator action angle data; respectively drawing a displacement angle scatter diagram and an action angle scatter diagram; respectively converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve; graying the displacement servo curve and the action servo curve to obtain a grayscale map; binarizing the gray level image, performing normalized correlation matching on the binarized image, and determining a correlation peak threshold value according to a plurality of normalized matching results; if the normalized matching result is larger than the correlation peak threshold value, successfully registering the actuator displacement angle data and the actuator action angle data, and drawing a composite image; if the correlation peak value is smaller than the correlation peak threshold value, the registration is unsuccessful, and a composite image is drawn to eliminate faults. The manpower and time consumption during mass production is avoided, and the interpretation correctness is ensured.
Description
Technical Field
The invention relates to a method and a system for processing data interpretation in an image matching mode, and belongs to the technical field of data analysis.
Background
When a product is produced in batch, the traditional manual data analysis mode cannot meet the batch production requirement. Traditional manual data analysis, whether the judgement to actuator displacement (angle) and actuator action angle accord mainly is through drawing by hand, and the people carries out the analysis according to relevant information, reachs the judgement that the angle accords at last. The workload is large, the experience requirement of personnel is high, and the progress requirement can not be met under the background of model mass production. Erroneous judgment and misjudgment are easily caused in continuous work. It is therefore desirable to introduce methods for automatic interpretation.
In the development process of automatic interpretation, interpretation of the action angle of the actuator needs to be solved, the instruction and the response of the actuator are compared, and since the instruction is fixed data and the response is actually fed back data, correct results cannot be obtained by comparing the data. Therefore, people generally draw pictures manually, and people judge the pictures by naked eyes to draw a conclusion. However, the manual drawing tool cannot be embedded into the automatic interpretation software, so it is necessary to find an automatic interpretation method that can be implemented by programming.
Disclosure of Invention
The technical problem to be solved by the invention is as follows: the defects of the prior art are overcome, and the method and the system for processing data interpretation in an image matching mode are provided, so that the manpower and time consumption during mass production can be avoided, the interpretation correctness is ensured, and the efficiency is improved.
The technical solution of the invention is as follows:
the invention discloses an interpretation method for processing data in an image matching mode, which comprises the following steps:
step 1: automatically segmenting the actuator data to obtain actuator displacement angle data and actuator action angle data;
step 2: respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the displacement angle data and the action angle data of the actuator;
and 3, step 3: respectively converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve;
and 4, step 4: graying the displacement servo curve and the action servo curve to obtain a gray scale image of the servo actuator;
and 5: carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator;
step 6: carrying out normalized correlation matching on the binary image of the servo actuator to obtain a normalized matching result;
and 7: determining a correlation peak threshold value according to a plurality of normalization matching results;
and 8: judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak value is smaller than the correlation peak threshold value, the registration is unsuccessful, and a composite image is drawn for troubleshooting.
In the interpretation method, the actuator data analyzed by the software is automatically segmented to obtain the actuator displacement angle data and the actuator action angle data, and the specific method comprises the following steps: and intercepting effective data from the ignition moment to the power-off moment of the flight ending.
In the interpretation method, the angle scattergram is an image with a coordinate axis removed.
In the interpretation method, the displacement angle scattergram and the motion angle scattergram are enlarged in the same scale, and the BGR mode of the displacement angle scattergram and the motion angle scattergram is converted into the RGB mode.
In the interpretation method, normalized correlation coefficient matching is performed on the binarized image of the servo actuator to obtain a normalized correlation coefficient matching result, and the specific method comprises the following steps:
wherein, T is a template image, I is an image to be matched, (x, y) is the distance between the upper left corner point of the template and the upper left corner point of the image in the x direction and the distance in the y direction, and x 'and y' are coordinates of the template moving by taking (x, y) as an origin.
In the interpretation method, a correlation peak threshold is determined according to a plurality of normalized matching results, and the specific method is as follows:
obtaining a matching mean value and a standard deviation through the normalized matching results of a plurality of test images;
and taking the difference value between the average value and n times of standard deviation as a threshold value, wherein n is an integer larger than 1.
In the interpretation method, the matching mean and the standard deviation are obtained by normalizing the matching results of the plurality of test images, and the specific method comprises the following steps:
wherein, X i Is a correlation peak value, n is the number of the correlation peak values;
wherein S is the standard deviation, X i Is the correlation peak value, n is the number of correlation peak values,is the mean value.
In the interpretation method, the difference between the average value and the n-fold standard deviation is used as a threshold, and the specific method is as follows:
In the interpretation method, the composite image is drawn, and the specific method comprises the following steps:
and aligning the initial position and the end position of the image drawn by the actuator displacement angle data and the image drawn by the actuator action angle data according to the time point to generate a composite image.
In the above interpretation method, n =2 or 3.
The invention discloses an interpretation system for processing data in an image matching mode, which comprises: data acquisition module, image preprocessing module and image matching module, wherein:
a data acquisition module: automatically segmenting the actuator data to obtain actuator displacement angle data and actuator action angle data; sending the displacement angle data of the actuator and the action angle data of the actuator to an image preprocessing module;
an image preprocessing module: respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the actuator displacement angle data and the actuator action angle data sent by the data acquisition module; converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve respectively; graying the displacement servo curve and the action servo curve to obtain a gray scale image of the servo actuator; carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator; sending the binaryzation image of the servo actuator to an image matching module;
an image matching module: carrying out normalized correlation matching on the binarized image of the servo actuator sent by the image preprocessing module to obtain a normalized matching result; determining a correlation peak threshold value according to a plurality of normalization matching results; judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak value is smaller than the correlation peak threshold value, the registration is unsuccessful, and a composite image is drawn for troubleshooting.
The beneficial effects of the invention and the prior art are as follows:
(1) According to the invention, by means of automatically interpreting servo actuation data, the problem that the batch production task is large in quantity and the conventional manual data analysis mode cannot meet the batch production requirement is solved, the problem of great labor and time consumption during mass production is avoided, and the interpretation correctness is ensured to a certain extent.
(2) The invention pre-processes the servo actuation data, draws the data into a curve image, and then converts the coordinate axis drawing, the proportional amplification, the BGR mode into a series of image processing modes such as RGB mode, graying, binaryzation and the like, thereby solving the image preparation work before the servo actuation curve registration and improving the efficiency.
(3) According to the method, the correlation coefficient matching of normalization is carried out on the image data, and then the correlation peak threshold is determined through the statistic Chebyshev rule, so that the problem of the image threshold in automatic registration is solved, and the best registration effect is guaranteed to be achieved without distortion.
(4) The invention can dynamically adjust the matching mode of the image, thereby achieving the best registration effect aiming at different requirements and solving the problem of ductility of the invention.
Drawings
FIG. 1 is a flowchart of an interpretation method for processing data images in an image matching manner according to the present invention;
FIG. 2 is a graph image of actuator displacement angle data prior to registration in accordance with the present invention;
fig. 3 is a graph image of the actuator motion angle data prior to registration in accordance with the present invention.
Detailed Description
The invention is further described in detail with reference to the drawings and the detailed description.
The invention provides an interpretation method for processing data in an image matching mode, which comprises the following steps:
automatically segmenting the actuator data analyzed by the software to obtain actuator displacement angle data and actuator action angle data; and intercepting effective data from the ignition moment to the power-off moment of the flight ending.
Respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the displacement angle data and the action angle data of the actuator; the angle scatter diagram is an image with coordinate axes removed. And amplifying the system displacement angle scatter diagram and the action angle scatter diagram according to the same proportion, and converting the BGR mode of the system displacement angle scatter diagram and the action angle scatter diagram into an RGB mode.
Converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve respectively;
graying the displacement servo curve and the action servo curve to obtain a gray scale image of the servo actuator;
carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator;
carrying out normalized correlation matching on the binarized image of the servo actuator to obtain a normalized matching result, wherein the specific method comprises the following steps:
wherein, T is a template image, I is an image to be matched, (x, y) is the distance between the upper left corner point of the template and the upper left corner point of the image in the x direction and the distance in the y direction, and x 'and y' are coordinates of the template moving by taking (x, y) as an origin.
Determining a correlation peak threshold according to a plurality of normalized matching results;
judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak value is smaller than the correlation peak threshold value, the registration is unsuccessful, and a composite image is drawn to eliminate faults. And aligning the initial position and the end position of the image drawn by the actuator displacement angle data and the image drawn by the actuator action angle data according to the time point to generate a composite image.
Obtaining a matching mean value and a standard deviation through the normalized matching results of a plurality of test images, wherein the specific method comprises the following steps:
wherein, X i Is a correlation peak value, and n is the number of the correlation peak values;
wherein S is the standard deviation, X i Is the correlation peak value, n is the number of correlation peak values,is the mean value.
Taking the difference value between the mean value and the n-fold standard deviation as a threshold value, and the specific method comprises the following steps:
wherein X is the threshold value finally obtained,mean and standard deviation of S. Wherein n is an integer greater than 1, and n =2 or 3.
The invention discloses an interpretation system for processing data in an image matching mode, which comprises: data acquisition module, image preprocessing module and image matching module, wherein:
a data acquisition module: automatically segmenting the actuator data to obtain actuator displacement angle data and actuator action angle data; sending the displacement angle data of the actuator and the action angle data of the actuator to an image preprocessing module;
an image preprocessing module: respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the actuator displacement angle data and the actuator action angle data sent by the data acquisition module; converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve respectively; graying the displacement servo curve and the action servo curve to obtain a grayscale map of the servo actuator; carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator; sending the binaryzation image of the servo actuator to an image matching module;
an image matching module: carrying out normalized correlation matching on the binarized image of the servo actuator sent by the image preprocessing module to obtain a normalized matching result; determining a correlation peak threshold value according to a plurality of normalized matching results; judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak value is smaller than the correlation peak threshold value, the registration is unsuccessful, and a composite image is drawn to eliminate faults.
Example 1
As shown in fig. 1, the present embodiment provides an interpretation method for processing a data image in an image matching manner, which includes the following steps:
1. and automatically segmenting the actuator data analyzed by the software, and segmenting useful data from the total data.
The specific method comprises the following steps: because the data analyzed by the analysis software is total data, the total data needs to be automatically processed first, effective registration data is intercepted, and curve errors can be caused if the data interception is not standard. And intercepting the data according to the time when the flight time is 0, and intercepting the data from the ignition time, namely the time when the flight time is 0 to the power-off time of the flight ending.
2. And drawing an angle scatter diagram according to the displacement angle data of the actuator and the action angle data of the actuator.
The specific method comprises the following steps: drawing a servo actuation curve scatter diagram by a method of a mathlotlib library and a numpy library of python, wherein a coordinate axis of the scatter diagram is removed by axis function setting, otherwise, the coordinate axis has great influence on curve pattern matching.
3. The two images are scaled up (the degree of magnification remains the same).
The specific method comprises the following steps: image magnification is performed by the figure function of the matplotlib library and numpy library of python.
4. And converting the BGR mode of the two images into the RGB mode.
The specific method comprises the following steps: the BGR mode of the image is converted into the RGB mode through the cvtColor function of an opencv library of python.
5. And graying the servo curve image to obtain a grayscale image of the servo actuator.
The specific method comprises the following steps: the image gray pattern conversion is performed by the cvtColor function of python's opencv library, which is used.
6. And carrying out binarization on the gray level image to obtain an image after binarization of the servo actuator.
The specific method comprises the following steps: binarization of the gray-scale image is performed by an atrazine threshold method through a threshold function of an opencv library of python. As shown in fig. 2 and 3.
7. And carrying out normalized correlation coefficient matching on the gray-scale image of the servo actuator to obtain a normalized matching result.
The specific method comprises the following steps:
wherein, T represents a template image, I represents an image to be matched, (x, y) represents the distance between the upper left corner point of the template and the upper left corner point of the image in the x direction and the distance in the y direction, and x 'and y' are coordinates of the template moving by taking (x, y) as an origin.
8. And determining a correlation peak threshold value according to a plurality of normalized matching results.
The specific method comprises the following steps: and obtaining a registration mean value and a standard deviation through registration results of a large number of various test images, and taking a value of the difference between the mean value and the 3 times of the standard deviation as a threshold value according to a Chebyshev's rule of statistics.(wherein, X is the finally obtained threshold value,mean and standard deviation of S. Mean value ofWherein, X i Is the correlation peak value, and n is the number of correlation peak values. Standard deviation ofWherein, X i Is the correlation peak value, n is the number of correlation peak values,are mean values. )
9. Method for rendering a composite image.
The specific method comprises the following steps: the starting point and the end point of the reference time of the two images are aligned, and then the two curves are uniformly drawn according to different colors by using a matplotlib library of python in the same image.
While the present invention has been described in detail with reference to the preferred embodiments, it should be understood that the above description should not be taken as limiting the invention. Various modifications and alterations to this invention will become apparent to those skilled in the art upon reading the foregoing description. Accordingly, the scope of the invention should be determined from the following claims.
Those skilled in the art will appreciate that the invention may be practiced without these specific details.
Claims (11)
1. An interpretation method for processing data in an image matching manner is characterized by comprising the following steps of:
automatically segmenting the actuator data to obtain actuator displacement angle data and actuator action angle data;
respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the displacement angle data and the action angle data of the actuator;
converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve respectively;
graying the displacement servo curve and the action servo curve to obtain a gray scale image of the servo actuator;
carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator;
carrying out normalized correlation matching on the binary image of the servo actuator to obtain a normalized matching result;
determining a correlation peak threshold according to a plurality of normalization matching results;
judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak threshold is smaller than the correlation peak threshold, the registration is unsuccessful, and a composite image is drawn for troubleshooting.
2. The interpretation method for processing data in an image matching manner according to claim 1, characterized in that: the method comprises the following steps of automatically segmenting actuator data after software analysis to obtain actuator displacement angle data and actuator action angle data, and comprises the following specific steps: and intercepting effective data from the ignition moment to the power-off moment of the flight ending.
3. The interpretation method of image matching processing data according to claim 1, wherein: the angle scatter diagram is an image with the coordinate axis removed.
4. The interpretation method of image matching processing data according to claim 1, wherein: and amplifying the displacement angle scatter diagram and the action angle scatter diagram according to the same proportion, and converting the BGR mode of the displacement angle scatter diagram and the action angle scatter diagram into an RGB mode.
5. The interpretation method of image matching processing data according to claim 1, wherein: carrying out normalized correlation coefficient matching on the binarized image of the servo actuator to obtain a normalized correlation coefficient matching result, wherein the specific method comprises the following steps:
wherein, T is a template image, I is an image to be matched, (x, y) is the distance between the upper left corner point of the template and the upper left corner point of the image in the x direction and the y direction, and x 'and y' are coordinates of the template moving by taking (x, y) as the origin.
6. The interpretation method of image matching processing data according to claim 1, wherein: determining a correlation peak threshold according to a plurality of normalized matching results, wherein the specific method comprises the following steps:
obtaining a matching mean value and a standard deviation through the normalized matching results of a plurality of test images;
and taking the difference value between the average value and n times of standard deviation as a threshold value, wherein n is an integer greater than 1.
7. The interpretation method of the image matching processing data according to claim 6, characterized in that: the method for obtaining the matching mean value and the standard deviation through the normalized matching results of the plurality of test images comprises the following specific steps:
wherein X i Is a correlation peak value, and n is the number of the correlation peak values;
8. The interpretation method of the image matching processing data according to claim 6, characterized in that: the value of the difference between the mean value and the n times of the standard deviation is taken as a threshold value, and the specific method comprises the following steps:
9. The interpretation method of image matching processing data according to claim 1, wherein: the method for drawing the composite image comprises the following specific steps:
and aligning the initial position and the end position of the image drawn by the actuator displacement angle data and the image drawn by the actuator action angle data according to the time point to generate a composite image.
10. The interpretation method of the image matching processing data according to claim 6, characterized in that: n =2 or 3.
11. An interpretation system for processing data in an image matching manner, comprising: data acquisition module, image preprocessing module and image matching module, wherein:
a data acquisition module: automatically segmenting the actuator data to obtain actuator displacement angle data and actuator action angle data; sending the displacement angle data of the actuator and the action angle data of the actuator to an image preprocessing module;
an image preprocessing module: respectively drawing a displacement angle scatter diagram and an action angle scatter diagram according to the actuator displacement angle data and the actuator action angle data sent by the data acquisition module; converting the displacement angle scatter diagram and the action angle scatter diagram into a displacement servo curve and an action servo curve respectively; graying the displacement servo curve and the action servo curve to obtain a gray scale image of the servo actuator; carrying out binarization on the gray scale image of the servo actuator to obtain a binarized image of the servo actuator; sending the binaryzation image of the servo actuator to an image matching module;
an image matching module: carrying out normalized correlation matching on the binarized image of the servo actuator sent by the image preprocessing module to obtain a normalized matching result; determining a correlation peak threshold according to a plurality of normalization matching results; judging a threshold value of the correlation peak, if the normalized matching result is larger than the threshold value of the correlation peak, successfully registering the displacement angle data of the actuator and the action angle data of the actuator, and drawing a composite image; if the correlation peak threshold is smaller than the correlation peak threshold, the registration is unsuccessful, and a composite image is drawn for troubleshooting.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211188625.6A CN115631219A (en) | 2022-09-28 | 2022-09-28 | Interpretation method and system for processing data image in image matching mode |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211188625.6A CN115631219A (en) | 2022-09-28 | 2022-09-28 | Interpretation method and system for processing data image in image matching mode |
Publications (1)
Publication Number | Publication Date |
---|---|
CN115631219A true CN115631219A (en) | 2023-01-20 |
Family
ID=84904710
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211188625.6A Pending CN115631219A (en) | 2022-09-28 | 2022-09-28 | Interpretation method and system for processing data image in image matching mode |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN115631219A (en) |
-
2022
- 2022-09-28 CN CN202211188625.6A patent/CN115631219A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107486415B (en) | Thin bamboo strip defect online detection system and detection method based on machine vision | |
CN101576956B (en) | On-line character detection method based on machine vision and system thereof | |
CN110210477B (en) | Digital instrument reading identification method | |
CN109540925B (en) | Complex ceramic tile surface defect detection method based on difference method and local variance measurement operator | |
CN112017164A (en) | Soil and stone material grading detection method based on depth threshold convolution model | |
CN110929713B (en) | Steel seal character recognition method based on BP neural network | |
US20040247171A1 (en) | Image processing method for appearance inspection | |
CN109781737B (en) | Detection method and detection system for surface defects of hose | |
CN111652117B (en) | Method and medium for segmenting multiple document images | |
CN109946304A (en) | Surface defects of parts on-line detecting system and detection method based on characteristic matching | |
CN111161237A (en) | Fruit and vegetable surface quality detection method, storage medium and sorting device thereof | |
CN112270658A (en) | Elevator steel wire rope detection method based on machine vision | |
CN114219773B (en) | Pre-screening and calibrating method for bridge crack detection data set | |
CN114155226A (en) | Micro defect edge calculation method | |
CN107194402A (en) | A kind of parallel thinning framework extraction method | |
CN113971681A (en) | Edge detection method for belt conveyor in complex environment | |
CN113642570A (en) | Method for recognizing license plate of mine car in dark environment | |
CN113269234A (en) | Connecting piece assembly detection method and system based on target detection | |
CN115631219A (en) | Interpretation method and system for processing data image in image matching mode | |
CN114758139B (en) | Method for detecting accumulated water in foundation pit | |
CN115753791A (en) | Defect detection method, device and system based on machine vision | |
CN115457563A (en) | Zero-missing-detection and low-error-identification ship water gauge reading method | |
CN114943738A (en) | Sensor packaging curing adhesive defect identification method based on visual identification | |
CN112926694A (en) | Method for automatically identifying pigs in image based on improved neural network | |
US20220383030A1 (en) | Using few shot learning on recognition system for character image in industrial processes |
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 |