CN108876851A - A kind of foil gauge image position method - Google Patents
A kind of foil gauge image position method Download PDFInfo
- Publication number
- CN108876851A CN108876851A CN201810777570.XA CN201810777570A CN108876851A CN 108876851 A CN108876851 A CN 108876851A CN 201810777570 A CN201810777570 A CN 201810777570A CN 108876851 A CN108876851 A CN 108876851A
- Authority
- CN
- China
- Prior art keywords
- image
- foil gauge
- strain gauges
- strain gauge
- strain
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/70—Determining position or orientation of objects or cameras
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T3/00—Geometric image transformations in the plane of the image
- G06T3/60—Rotation of whole images or parts thereof
- G06T3/608—Rotation of whole images or parts thereof by skew deformation, e.g. two-pass or three-pass rotation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T5/00—Image enhancement or restoration
- G06T5/90—Dynamic range modification of images or parts thereof
- G06T5/92—Dynamic range modification of images or parts thereof based on global image properties
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/12—Edge-based segmentation
-
- G—PHYSICS
- G06—COMPUTING OR CALCULATING; COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/136—Segmentation; Edge detection involving thresholding
Landscapes
- Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Image Processing (AREA)
Abstract
本发明为一种为应变片样板中方形应变片定位的方法,步骤入下:(1)图像预处理;(2)应变片初步定位;(3)个别应变片所在区域提取(包含非应变片部分);(4)个别应变片分散处理并提取个别应变片区域;经过以上几步,得到个别应变片区域,定位此应变片(一般为应变片样板角落应变片)后,根据此区域位置以及加工时各应变片间标准距离,得出应变片样板中所有应变片的位置。本发明的有益效果在于:本发明能够实现应变片机器定位代替人工,而且速度比人工更快,精度满足工程实际打磨应变片时的定位需求。The invention is a method for positioning square strain gauges in a strain gauge template, the steps are as follows: (1) image preprocessing; (2) preliminary positioning of strain gauges; (3) extraction of the area where individual strain gauges are located (including non-strain gauges) part); (4) Individual strain gauges are distributed and extracted individual strain gauge areas; after the above steps, the individual strain gauge areas are obtained, and after positioning the strain gauges (usually the corner strain gauges of the strain gauge template), according to the position of the area and The standard distance between each strain gauge during processing is used to obtain the positions of all strain gauges in the strain gauge template. The beneficial effect of the present invention is that: the present invention can realize machine positioning of strain gauges instead of manual labor, and the speed is faster than that of manual labor, and the precision meets the positioning requirements of engineering actual grinding strain gauges.
Description
技术领域technical field
本发明属于机器视觉、工业自动化领域,特别涉及一种应变片图像定位方法。The invention belongs to the fields of machine vision and industrial automation, and in particular relates to a strain gauge image positioning method.
背景技术Background technique
电阻应变片是利用电阻效应原理制成的、应用广泛的电阻式传感器,主要用于机械量的检查中,如重力、压力等物理量的检测,并且对阻值精度要求较高。常规的电阻应变片均通过化学腐蚀方法制得,生产出来的电阻应变片阻值较低,达不到使用要求。因此,半成品的电阻应变片在使用前必须进行自动调阻。Resistance strain gauge is a widely used resistive sensor made of the principle of resistance effect. It is mainly used in the inspection of mechanical quantities, such as the detection of physical quantities such as gravity and pressure, and has high requirements for resistance accuracy. Conventional resistance strain gauges are all made by chemical corrosion, and the resistance value of the produced resistance strain gauges is low, which cannot meet the requirements for use. Therefore, the resistance strain gauge of the semi-finished product must be automatically adjusted before use.
目前,电阻应变片的自动调阻主要是通过人工操作进行。操作者手持一微型直流电机,直流电机输出轴端缠绕着脱脂棉,脱脂棉上涂研磨膏。修整阻值时,脱脂棉压持电阻应变片的栅丝部位,直流电机带动脱脂棉旋转产生磨削力。在磨削力的作用下,栅丝厚度变薄,从而达到阻值修整的目的。At present, the automatic resistance adjustment of the resistance strain gauge is mainly carried out by manual operation. The operator holds a miniature DC motor, the output shaft end of the DC motor is wrapped with absorbent cotton, and the absorbent cotton is coated with abrasive paste. When trimming the resistance value, the absorbent cotton presses the grid wire part of the resistance strain gauge, and the DC motor drives the absorbent cotton to rotate to generate grinding force. Under the action of grinding force, the thickness of grid wire becomes thinner, so as to achieve the purpose of resistance trimming.
很明显,这种方式存在如下缺点:劳动强度大耗;工时,进度慢,效率低,影响产能;存在不同程度的误差,影响阻值的精确度。因此,开发一款能够自动定位并修正电阻应变片电阻值的设备显得尤为迫切。Obviously, this method has the following disadvantages: high labor intensity consumption; working hours, slow progress, low efficiency, which affects production capacity; there are different degrees of error, which affects the accuracy of the resistance value. Therefore, it is particularly urgent to develop a device that can automatically locate and correct the resistance value of the resistance strain gauge.
发明内容Contents of the invention
本发明所要解决的技术问题是克服人工打磨慢而且有时精度不够的技术缺陷,提供一种应变片图像定位方法。The technical problem to be solved by the present invention is to overcome the technical defects of slow manual grinding and sometimes insufficient precision, and provide a strain gauge image positioning method.
本发明的技术方案是,一种在样板上的应变片定位方法,所述方法包括如下步骤:The technical solution of the present invention is, a kind of strain gage positioning method on template, described method comprises the following steps:
(1)图像预处理,对采集来的应变片图片进行预处理,具体包括,(1) Image preprocessing, preprocessing the collected strain gauge images, specifically including,
a.图像灰度化:加权平均法处理图像,得到原图的灰度图;a. Image grayscale: the weighted average method processes the image to obtain the grayscale image of the original image;
b.图像二值化:采用1.25倍大律法得到的阈值俩进行图像二值化;b. Image binarization: use the threshold value obtained by the 1.25 times larger law to perform image binarization;
(2)应变片初定位,进行连通域提取并根据面积判断哪里是包含应变片的连通区域;(2) Initial positioning of the strain gauges, extracting the connected domain and judging where is the connected area containing the strain gauges according to the area;
(3)个别应变片所在区域提取(包含非应变片部分),一般截图边缘角落应变片所在区域;(3) Extraction of the area where individual strain gauges are located (including non-strain gauge parts), and the area where strain gauges are located at the edge corners of general screenshots;
(4)个别应变片分散处理并提取个别应变片区域,截取完成后,根据行列像素数,把像素数少的部分行列灰度全部置0;(4) Individual strain gauges are processed separately and individual strain gauge areas are extracted. After the interception is completed, according to the number of pixels in the rows and columns, the gray levels of the rows and columns with a small number of pixels are all set to 0;
经过上述步骤,再根据面积选出应变片区域。After the above steps, the strain gauge area is selected according to the area.
本发明的有益效果在于:本发明能够实现应变片机器定位代替人工,而且速度比人工更快,精度足够,满足工程实际打磨应变片时的定位需求。The beneficial effect of the present invention is that: the present invention can realize the machine positioning of the strain gauge instead of manual labor, and the speed is faster than that of manual labor, and the precision is sufficient, which meets the positioning requirements of engineering actual grinding strain gauges.
附图说明Description of drawings
图1为本发明应变片定位流程图。Fig. 1 is a flow chart of strain gauge positioning in the present invention.
具体实施方式Detailed ways
下面,结合附图对本发明进行如下详细说明:Below, the present invention is described in detail as follows in conjunction with accompanying drawing:
应变片种类很多,其中有很多方形的应变片,方形应变片可以在图像定位中通过最小外接旋转矩形圈定。因为存在应变片以外区域的部分与应变片相连,所以难以直接提取应变片区域,所以,我们在二值化基础上,提出分散处理的连通域提取办法,来提取应变片区域并进行定位。There are many types of strain gauges, among which there are many square strain gauges, which can be delineated by the minimum circumscribed rotation rectangle in the image positioning. Because the parts outside the strain gauge are connected to the strain gauge, it is difficult to directly extract the strain gauge area. Therefore, on the basis of binarization, we propose a connected domain extraction method of decentralized processing to extract the strain gauge area and locate it.
图像预处理。Image preprocessing.
图像灰度化:图像灰度化采取OPENCV工具包中自带函数来把RGB图像转为灰度图。图像二值化:为了适应一定范围的光照环境变化,最终结果用大律法阈值的一到二倍之间的倍数作为最终的动态阈值,用二分法计算大律阈值与255之间的假设阈值,并且经过反复进行实验对比,最终得出1.25倍大律阈值为本发明实验环境的最佳阈值。Image grayscale: image grayscale adopts the built-in function in the OPENCV toolkit to convert the RGB image into a grayscale image. Image binarization: In order to adapt to a certain range of lighting environment changes, the final result uses a multiple of one to two times the Dalaw threshold as the final dynamic threshold, and uses the dichotomy to calculate the hypothetical threshold between the Dalaw threshold and 255 , and after repeated experiments and comparisons, it is finally concluded that the threshold of 1.25 times the law is the best threshold for the experimental environment of the present invention.
应变片初定位。Initial positioning of strain gauges.
进行连通域提取并根据面积判断哪里是包含应变片的连通区域。Extract the connected domain and judge where is the connected area containing the strain gauge according to the area.
个别应变片所在区域提取(包含非应变片部分)。Extract the area where individual strain gauges are located (including non-strain gauge parts).
一般截图边缘角落应变片所在区域。Generally, the screenshot shows the area where the strain gauges are located at the edge corners.
个别应变片分散处理并提取个别应变片区域。Individual strain gauges are dispersed and extracted for individual strain gauge regions.
(1)依据面积,顺序每次提取一块应变片对;(1) According to the area, a strain gauge pair is sequentially extracted each time;
(2)进行旋转矫正(为了分散处理方便);(2) Perform rotation correction (for the convenience of decentralized processing);
(3)根据每行每列像素数进行分散处理(主要去除应变片焊点引线与应变片块的连接部分,即非应变片部分与应变片部分的分离),某行或某列像素数过少则此行或此列像素的灰度值均置0;(3) Scatter processing according to the number of pixels in each row and column (mainly remove the connection part of the strain gauge solder joint lead and the strain gauge block, that is, the separation of the non-strain gauge part and the strain gauge part), the number of pixels in a certain row or column is too large At least the gray value of the pixel in this row or column is set to 0;
(4)根据连通域面积筛选出应变片连通域,然后根据第一步旋转的角度旋转回原位,并利用旋转后的应变片连通域的最小外接旋转矩形定位应变片中心位置。(4) Select the connected domain of the strain gauge according to the area of the connected domain, and then rotate back to the original position according to the angle of the first step of rotation, and use the minimum circumscribed rotation rectangle of the connected domain of the strain gauge after rotation to locate the center position of the strain gauge.
至此,应变片中心位置和应变片姿态可用长边与水平轴夹角表示,这两种参数均可由应变片连通域的最小外接旋转矩形求出,中心坐标代表其位置,角度即其姿态。So far, the central position of the strain gauge and the attitude of the strain gauge can be expressed by the angle between the long side and the horizontal axis. These two parameters can be obtained from the minimum circumscribed rotation rectangle of the connected domain of the strain gauge. The center coordinate represents its position, and the angle is its attitude.
所述仅是本发明的具体实例,任何基于本发明方法基础的等效变换,均属于本发明保护范围之内。The above are only specific examples of the present invention, and any equivalent transformation based on the method of the present invention falls within the protection scope of the present invention.
Claims (1)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810777570.XA CN108876851A (en) | 2018-07-16 | 2018-07-16 | A kind of foil gauge image position method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201810777570.XA CN108876851A (en) | 2018-07-16 | 2018-07-16 | A kind of foil gauge image position method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN108876851A true CN108876851A (en) | 2018-11-23 |
Family
ID=64302338
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201810777570.XA Pending CN108876851A (en) | 2018-07-16 | 2018-07-16 | A kind of foil gauge image position method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108876851A (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20090066641A1 (en) * | 2005-03-10 | 2009-03-12 | Motus Corporation | Methods and Systems for Interpretation and Processing of Data Streams |
CN102589431A (en) * | 2012-02-07 | 2012-07-18 | 中国地震局地质研究所 | Automatic detection method for accurate positions and directions of multiple strain foils |
CN107423651A (en) * | 2016-06-01 | 2017-12-01 | 国家计算机网络与信息安全管理中心 | A kind of QR codes image position method |
CN107644417A (en) * | 2017-09-22 | 2018-01-30 | 西北工业大学 | Foil gauge outward appearance defect detection method |
-
2018
- 2018-07-16 CN CN201810777570.XA patent/CN108876851A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20090066641A1 (en) * | 2005-03-10 | 2009-03-12 | Motus Corporation | Methods and Systems for Interpretation and Processing of Data Streams |
CN102589431A (en) * | 2012-02-07 | 2012-07-18 | 中国地震局地质研究所 | Automatic detection method for accurate positions and directions of multiple strain foils |
CN107423651A (en) * | 2016-06-01 | 2017-12-01 | 国家计算机网络与信息安全管理中心 | A kind of QR codes image position method |
CN107644417A (en) * | 2017-09-22 | 2018-01-30 | 西北工业大学 | Foil gauge outward appearance defect detection method |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107941808B (en) | 3D printing forming quality detection system and method based on machine vision | |
CN106780623B (en) | A fast calibration method for robot vision system | |
CN108107837B (en) | Glass processing device and method based on visual guidance | |
CN109978940B (en) | Visual measurement method for SAB safety airbag size | |
WO2016201947A1 (en) | Method for automated detection of defects in cast wheel products | |
CN112419291B (en) | Training method of bottle embryo defect detection model, storage medium and terminal equipment | |
CN104976959B (en) | A kind of spring sizes on-line measurement system and its method based on machine vision | |
CN103363893B (en) | A kind of red fuji apple size detection method | |
CN111681222A (en) | Automatic detection and judgment method for edge breakage of tool mark and scribing machine applied by same | |
JP2010139317A (en) | Method and device for inspecting defect on surface of shaft-like tool | |
CN102284887B (en) | Service life monitor of cutting tool for rough mill of large cast and forged component | |
CN117132655A (en) | Filling barrel opening position measuring method based on machine vision | |
CN1835547A (en) | Image processing device and registration data generation method in image processing | |
CN107490582A (en) | A kind of streamline Work Piece Verification System Based | |
CN112729112A (en) | Engine cylinder bore diameter and hole site detection method based on robot vision | |
CN111639538B (en) | Casting positioning method based on vision | |
CN108876851A (en) | A kind of foil gauge image position method | |
CN105006000B (en) | A kind of image automatic calibration method applied to Intelligent Laser cutting | |
CN111178296A (en) | Multi-workpiece visual positioning and identification method | |
CN111062937A (en) | A virtual reality verification method of numerical control NC code based on RGB-D camera | |
CN111539951B (en) | A visual detection method for the contour size of ceramic grinding wheel head | |
CN107492093B (en) | Bearing anomaly detection method based on image processing | |
CN106413280A (en) | Automatic surface mounting machine feeder element position correction device and automatic correction method based on image processing | |
CN204009938U (en) | The recognition system of wheel hub type | |
CN117830597A (en) | Processing parameter detection method and device, electronic equipment and storage 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 | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20181123 |
|
WD01 | Invention patent application deemed withdrawn after publication |