A positioning data processing method and device for visual camera

By installing the capture device and encoder on the glass bottle production line, calculating the outline of the glass bottle and jar conforms to the index and offset assessment index, solve the problem of not high trigger accuracy of the visual positioning camera, and realize the real -time of the trigger conditions of the glass bottle and cans. Adjustment and accuracy improvement.

CN119152041BActive Publication Date: 2025-01-24CHENGDU SANSHIHUI TECH CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411660465.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-11-20
Publication Date
2025-01-24
Estimated Expiration
2044-11-20

AI Technical Summary

Technical Problem

In the prior art, the triggering accuracy of the visual positioning camera corresponding to the glass bottle jar is not high, and bottles of different heights cannot be taken into account.

Method used

By installing a preset capture device and encoder on the glass bottle and can production line, the profile data and offset data of the glass bottle and can are obtained, the profile compliance index and offset evaluation index are calculated based on the reference data, and the comprehensive trigger index is used to determine whether to issue a trigger prompt. Or make corrections and adjustments.

Benefits of technology

It improves the accuracy of the visual positioning camera to the trigger of glass bottle and can, solves the problem of low trigger accuracy, and realizes the real -time adjustment and accuracy improvement of the trigger conditions of the glass bottle and can.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119152041B_ABST
    Figure CN119152041B_ABST
Patent Text Reader

Abstract

The present invention discloses a positioning data processing method and device for a visual camera, and relates to the technical field of electrical digital data processing. The positioning data processing method for a visual camera includes: obtaining a contour conformity index; obtaining an offset evaluation index; and obtaining a comprehensive trigger index. The present invention obtains the contour data of the glass bottle by acquiring an image of a glass bottle and performing contour extraction, obtains the contour conformity index by combining the contour data of the glass bottle and the reference contour data, then obtains the offset data of the glass bottle and obtains the offset evaluation index by combining the reference offset data, and finally obtains the comprehensive trigger index according to the contour conformity index and the offset evaluation index, and determines whether to make corrections and adjustments, thereby achieving the effect of improving the accuracy of the visual positioning camera triggering the glass bottle, and solving the problem of low triggering accuracy of the visual positioning camera corresponding to the glass bottle in the prior art.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of electronic digital data processing, and in particular to a positioning data processing method and device for a visual camera. Background Art

[0002] In the hot end mixed production process of glass bottles and cans, due to the differences in glass raw materials and process parameters of different batches and types, it is necessary to use a visual trigger system to monitor and detect the quality of products in real time. As the epitome of advanced machine vision technology, the visual trigger system can achieve real-time, non-contact monitoring of the entire process of glass bottle production with its high-speed and high-precision image acquisition and processing capabilities. The system captures every image of glass bottles and cans on the production line through a high-definition camera, and uses complex image processing algorithms and intelligent recognition technology to quickly analyze and judge the appearance quality of the product, such as surface defects, dimensional deviations, shape defects, etc. Once unqualified products are found, the system will immediately trigger an alarm and start the rejection mechanism to separate the problem products from the production line, effectively preventing defective products from flowing into subsequent processes, thereby ensuring the qualified rate and market reputation of the final product. This helps to timely discover and remove defective products and ensure the qualified rate of the final product. The production data collected by the visual trigger system can be used for subsequent analysis and optimization. These data can help companies understand the bottlenecks and problems in the production process, so as to formulate targeted improvement measures and improve the overall production level.

[0003] Existing methods use high-definition cameras and image processing technology to capture and identify the appearance of glass bottles and cans in real time. By comparing preset standard images with real-time images, product defects and anomalies can be quickly detected.

[0004] For example, the invention patent with announcement number: CN112837375B discloses a method and system for positioning a camera inside a real space, including: setting a positioning target; shooting toward the positioning target at a first position to obtain a first captured image of the positioning target; shooting toward the positioning target at multiple second positions to obtain a second captured image group of the positioning target; respectively extracting first image features and second image feature groups; determining a mapping relationship between shooting positions and image features based on the relationship between position differences and corresponding feature differences; obtaining a positioning captured image of the positioning target; extracting positioning image features; and determining the position of the camera to be positioned inside the real space based on the mapping relationship and the positioning image features.

[0005] For example, the invention patent with announcement number: CN102306160B announces an auxiliary data processing method for improving the image positioning accuracy of a stereo mapping camera, including: by increasing the original measurement data such as the pseudorange and carrier phase of the GPS receiver on the basis of the image auxiliary data commonly used by remote sensing satellites at present, and using the star sensor quaternion to replace the attitude angle estimation data to improve the measurement accuracy of the relevant data that affects the image positioning. Secondly, by adding the time information of various types of data to the auxiliary data, an accurate time relationship exists between the various types of data. Finally, by using GPS second pulses to synchronize the camera image, attitude and positioning data with GPS time, and by using a method for collecting the time information of the camera image line (frame), attitude data and GPS data, high-precision time synchronization of each auxiliary data is performed.

[0006] However, in the process of implementing the technical solution of the invention in the embodiments of the present application, the present application found that the above technology has at least the following technical problems:

[0007] In the prior art, since bottles of different heights cannot be taken into account during the mixed production process, the triggering accuracy of the visual positioning camera corresponding to the glass bottles and jars is not high. Summary of the invention

[0008] The embodiments of the present application solve the problem of low triggering accuracy of visual positioning cameras corresponding to glass bottles and jars in the prior art by providing a positioning data processing method and device for a visual positioning camera, thereby improving the triggering accuracy of the visual positioning camera for glass bottles and jars.

[0009] The embodiment of the present application provides a positioning data processing method and device for a visual camera, comprising the following steps: S1, installing a preset capture device in a preset area on a glass bottle production line to obtain a glass bottle image and perform contour extraction to obtain glass bottle contour data, combining the glass bottle contour data and reference contour data obtained from a preset database to obtain a contour conformity index, and combining a preset contour threshold range obtained from the preset database to determine whether to perform image capture adjustment, wherein the contour conformity index is used to evaluate the contour condition of the glass bottle; S2, installing a preset encoder in a preset area on the glass bottle production line to obtain glass bottle offset data, combining the glass bottle offset data and reference offset data obtained from the preset database to obtain an offset evaluation index, and combining a preset offset threshold range obtained from the preset database to determine whether to perform offset adjustment, wherein the offset evaluation index is used to evaluate the offset of the glass bottle from a preset trigger position; S3, obtaining a comprehensive trigger index based on the contour conformity index and the offset evaluation index, and a preset trigger threshold range obtained from the preset database, and when the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is performed.

[0010] Furthermore, the glass bottle and jar contour data is obtained by extracting the contour of the glass bottle and jar image; the glass bottle and jar contour data includes image height, image width, pixel distance and standard angle; the pixel distance represents the distance from the top pixel center point to the bottom pixel center point of the glass bottle and jar in the glass bottle and jar image at a preset time point; the standard angle represents the relative tilt angle of the glass bottle and the industrial camera at a preset time point; the preset capture device is installed in a preset area on the glass bottle and jar production line to obtain the glass bottle and jar image, and then the glass bottle and jar image is preprocessed; the preprocessing includes graying and filtering.

[0011] Furthermore, the contour conformity index is obtained by combining the contour data of the glass bottle and jar with the reference contour data obtained from a preset database, and the specific process is as follows: camera-related data is obtained through a laser rangefinder at a preset time point, and a first height deviation and a second height deviation are obtained by combining the contour data of the glass bottle and jar and the camera-related data, wherein the camera-related data include a camera focal length and a standard distance; the preset time points and the glass bottles and jars are numbered, and when the number of the preset time point is 1 or the number of the glass bottles and jars is 1, the corresponding first height deviation and second height deviation are recorded as 0, otherwise, the reference contour data is obtained from the preset database, and the contour conformity index is obtained by combining the first height deviation and the second height deviation; the reference contour data includes a first contour allocation weight, a second contour allocation weight, a preset first height deviation threshold, and a preset second height deviation threshold.

[0012] Furthermore, the profile conformity index is calculated using the following formula:

[0013] ;

[0014] ;

[0015] ;

[0016] In the formula, Indicates the contour conformity index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, represents the first height deviation of the rth glass bottle at the i-th preset time point, represents the second height deviation of the rth glass bottle at the i-th preset time point, represents the image height of the rth glass bottle at the i-th preset time point, represents the image width of the r-th glass bottle at the i-th preset time point, represents the pixel distance of the rth glass bottle at the i-th preset time point, represents the standard angle of the rth glass bottle at the i-th preset time point, represents the focal length of the industrial camera corresponding to the rth glass bottle at the i-th preset time point, represents the standard distance of the rth glass bottle at the i-th preset time point, represents the first contour assignment weight, represents the second contour assignment weight, Indicates the preset first height deviation threshold, represents a preset second height deviation threshold, and e represents a natural constant.

[0017] Furthermore, the specific process of determining whether to perform image capture adjustment in combination with the preset contour threshold range obtained from the preset database is as follows: Q1, obtaining the preset contour threshold range from the preset database, and determining whether the contour conformity index is within the preset contour threshold range. When the contour conformity index is within the preset contour threshold range, no image capture adjustment is performed, otherwise Q2 is executed; Q2, sending a prompt to the preset personnel to add a preset lighting device. When the monitored contour conformity index is within the preset contour threshold range, execution is stopped, otherwise Q3 is executed; Q3, obtaining the preset frequency threshold and preset multiple from the preset database, sending a prompt to the preset personnel to increase the capture frequency of the preset capture device by the preset multiple of the preset frequency threshold. When the monitored contour conformity index is within the preset contour threshold range, execution is stopped, otherwise feedback is given to the preset personnel to re-acquire the image of the glass bottle.

[0018] Furthermore, the offset evaluation index is obtained by combining the offset data of the glass bottle and the reference offset data obtained from a preset database, and the specific process is as follows: the offset data of the glass bottle is obtained by a preset offset measuring device at a preset time point, and the offset data of the glass bottle includes the coordinates of the glass bottle and the offset angle; the preset trigger position coordinates and the preset offset angle threshold are obtained from the preset database, and a first offset deviation and a second offset deviation are obtained in combination with the offset data of the glass bottle, the first offset deviation is used to evaluate the deviation of the trigger position, and the second offset deviation is used to evaluate the deviation of the offset angle; a preset first offset deviation threshold and a preset first offset deviation threshold are obtained from the preset database, and the first offset deviation and the preset first offset deviation threshold are obtained in combination with the first offset deviation and the preset first offset deviation threshold. The ratio of the second offset deviation and the preset second offset deviation threshold is combined to obtain the ratio of the second offset deviation and the preset second offset deviation threshold; the preset time points and glass bottles are numbered, when the preset time point is numbered 1 or the glass bottle is numbered 1, the corresponding first offset deviation and second offset deviation are recorded as 0, otherwise the preset first offset allocation weight and the preset first offset allocation weight are obtained from the preset database, and the offset evaluation index is obtained by combining the ratio of the first offset deviation and the preset first offset deviation threshold, and the ratio of the second offset deviation and the preset second offset deviation threshold; the reference offset data includes a preset trigger position coordinate, a preset offset angle threshold, a preset first offset deviation threshold, a preset second offset deviation threshold, a preset first offset allocation weight and a preset second offset allocation weight.

[0019] Furthermore, the specific process of determining whether to perform an offset adjustment in combination with the preset offset threshold range obtained from the preset database is as follows: P1, obtaining the preset offset threshold range from the preset database, determining whether the offset evaluation index is within the preset offset threshold range, and when the offset evaluation index is within the preset offset threshold range, no offset adjustment is performed, otherwise P2 is executed; P2, obtaining the preset speed threshold and preset multiple from the preset database, sending a prompt to the preset personnel to reduce the conveying speed of the conveyor belt by the preset multiple of the preset speed threshold, and when the monitored offset evaluation index is within the preset offset threshold range, execution is stopped, otherwise P3 is executed; P3, sending a prompt to the preset personnel to install shock pads and shock absorbers to reduce the vibration frequency of the conveyor belt, and when the offset evaluation index is within the preset offset threshold range, execution is stopped, otherwise feedback is given to the preset personnel to perform conveyor belt maintenance.

[0020] Furthermore, the specific process of obtaining the comprehensive trigger index based on the contour conformity index and the offset evaluation index is as follows: obtaining a preset comprehensive first allocation weight and a preset comprehensive second allocation weight from a preset database, and obtaining the comprehensive trigger index in combination with the obtained contour conformity index and the offset evaluation index; the specific process of combining the obtained contour conformity index and the offset evaluation index is as follows: combining the preset comprehensive first allocation weight with the contour conformity index to obtain changes in the degree of influence of the contour conformity index, combining the preset comprehensive second allocation weight with the offset evaluation index to obtain changes in the degree of influence of the offset evaluation index, and combining the changes in the degree of influence of the contour conformity index with the changes in the degree of influence of the offset evaluation index to obtain the comprehensive trigger index.

[0021] Furthermore, the specific process of the correction and adjustment is as follows: W1, obtain the preset trigger threshold range from the preset database, and determine whether the comprehensive trigger index is within the preset trigger threshold range. When the comprehensive trigger index is within the preset trigger threshold range, no correction or adjustment is performed, otherwise W2 is executed; W2, send a prompt to the preset personnel to replace the industrial camera. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise W3 is executed; W3, send a prompt to the preset personnel to replace the preset encoder. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise it is fed back to the preset personnel for system maintenance.

[0022] The embodiment of the present application provides a positioning data processing device for a visual camera, comprising: a contour conformity index acquisition module, an offset evaluation index acquisition module and a comprehensive trigger index acquisition module: wherein the contour conformity index acquisition module is used to install a preset capture device in a preset area on a glass bottle production line to acquire a glass bottle image and perform contour extraction to acquire glass bottle contour data, obtain a contour conformity index in combination with the glass bottle contour data and reference contour data acquired from a preset database, and determine whether to perform image capture adjustment in combination with a preset contour threshold range acquired from the preset database, wherein the contour conformity index is used to evaluate the contour condition of the glass bottle; the offset evaluation index acquisition module is used to obtain a preset ... The acquisition module is used to install a preset encoder in a preset area on the glass bottle production line and obtain the offset data of the glass bottles, obtain the offset evaluation index in combination with the offset data of the glass bottles and the reference offset data obtained from the preset database, and determine whether to make an offset adjustment in combination with the preset offset threshold range obtained from the preset database. The offset evaluation index is used to evaluate the offset between the glass bottles and the preset trigger position; the comprehensive trigger index acquisition module is used to obtain the comprehensive trigger index based on the contour compliance index and the offset evaluation index, and the preset trigger threshold range obtained from the preset database. When the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is made.

[0023] One or more technical solutions provided in the embodiments of the present application have at least the following technical effects or advantages:

[0024] 1. The contour data of the glass bottles and jars is obtained by acquiring the images of the glass bottles and jars and performing contour extraction, and the contour conformity index is obtained by combining the reference contour data, and then the offset data of the glass bottles and jars is obtained, and the offset evaluation index is obtained by combining the offset data of the glass bottles and jars and the reference offset data. Finally, the comprehensive trigger index is obtained according to the contour conformity index and the offset evaluation index, thereby achieving the improvement of the real-time adjustment of the trigger conditions of the glass bottles and jars, and then achieving the improvement of the triggering accuracy of the visual positioning camera for the glass bottles and jars, which effectively solves the problem of low triggering accuracy of the visual positioning camera corresponding to the glass bottles and jars in the prior art.

[0025] 2. The contour data and contour compliance index of the glass bottles and jars are obtained by extracting the contours of the glass bottles and jars images, and then the offset data and offset evaluation index of the glass bottles and jars are obtained through the preset offset measurement equipment. Finally, the comprehensive trigger index is obtained by combining the contour compliance index and the offset evaluation index, thereby achieving the improvement of the real-time performance of obtaining the trigger data of the glass bottles and jars, and then achieving the improvement of the accuracy of obtaining the trigger data of the glass bottles and jars.

[0026] 3. By combining the obtained preset contour threshold range and contour compliance index to determine whether to adjust the image capture, and then combining the obtained preset offset threshold range and offset evaluation index to determine whether to adjust the offset, and finally combining the obtained preset trigger threshold range and comprehensive trigger index to determine whether to make correction adjustments, the reliability of glass bottle triggering is improved, and then the effectiveness of glass bottle triggering is improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1 A flowchart of a positioning data processing method for a visual camera provided in an embodiment of the present application;

[0028] Figure 2 A statistical diagram of changes in the profile compliance index provided in the embodiment of the present application;

[0029] Figure 3 A schematic diagram of the structure of a positioning data processing device for a visual camera provided in an embodiment of the present application. DETAILED DESCRIPTION

[0030] The embodiment of the present application solves the problem of low triggering accuracy of visual positioning cameras corresponding to glass bottles and jars in the prior art by providing a positioning data processing method and device for a visual camera. A preset capture device is installed in a preset area on the glass bottle production line to obtain glass bottle images and perform contour extraction to obtain glass bottle contour data, and the contour data of the glass bottle and jar are combined with the reference contour data to obtain a contour compliance index. Then, a preset encoder is installed in the preset area on the glass bottle production line to obtain glass bottle offset data, and the offset evaluation index is obtained by combining the glass bottle offset data and the reference offset data. Finally, a comprehensive trigger index is obtained based on the contour compliance index and the offset evaluation index, and it is determined whether to perform correction adjustments, thereby improving the triggering accuracy of the visual positioning camera for glass bottles and jars.

[0031] The technical solution in the embodiment of the present application is to solve the problem of low triggering accuracy of the visual positioning camera corresponding to the above-mentioned glass bottles and jars, and the overall idea is as follows:

[0032] The contour conformity index is obtained through the contour data of glass bottles and cans and the reference contour data, and then the offset data of the glass bottles and cans is obtained and combined with the reference offset data to obtain the offset evaluation index. Finally, the comprehensive trigger index is obtained according to the contour conformity index and the offset evaluation index, and it is determined whether to make corrections and adjustments, thereby achieving the effect of improving the accuracy of the visual positioning camera in triggering glass bottles and cans.

[0033] In order to better understand the above technical solution, the above technical solution will be described in detail below in conjunction with the accompanying drawings and specific implementation methods.

[0034] like Figure 1As shown, it is a flow chart of a positioning data processing method for a visual camera provided by an embodiment of the present application, and the method includes the following steps: S1, installing a preset capture device in a preset area on a glass bottle production line to obtain a glass bottle image and perform contour extraction to obtain glass bottle contour data, combining the glass bottle contour data and reference contour data obtained from a preset database to obtain a contour conformity index, and combining the preset contour threshold range obtained from the preset database to determine whether to perform image capture adjustment, the image capture adjustment is used to adjust the contour conformity index to within the preset contour threshold range, the contour conformity index is used to evaluate the contour condition of the glass bottle, the glass bottle contour data is used to describe the contour features in the glass bottle image, and the contour extraction is used to extract the edge contour features in the glass bottle image; S2, installing a preset capture device in a preset area on the glass bottle production line The domain installs a preset encoder and obtains the offset data of the glass bottle, obtains the offset evaluation index by combining the offset data of the glass bottle and the reference offset data obtained from the preset database, and determines whether to perform an offset adjustment by combining the preset offset threshold range obtained from the preset database. The offset adjustment is used to adjust the offset evaluation index to within the preset offset threshold range. The offset evaluation index is used to evaluate the offset between the glass bottle and the preset trigger position. The offset data of the glass bottle is used to describe the offset between the glass bottle and the preset trigger position. S3, obtains the comprehensive trigger index according to the contour conformity index and the offset evaluation index, and obtains the preset trigger threshold range from the preset database. When the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is performed. The correction adjustment is used to adjust the comprehensive trigger index to within the preset trigger threshold range.

[0035] In this embodiment, the contour conformity index and the offset evaluation index influence each other and work together on the triggering control of the glass bottles and jars. The contour conformity index is directly related to the appearance quality of the bottles and jars, and the offset evaluation index is related to the position accuracy of the bottles and jars. By performing image capture adjustment and offset adjustment according to the contour conformity index and the offset evaluation index, it is possible to evaluate whether the height and offset degree of the glass bottles and jars are within the conformity range, that is, the contour conformity index is within the preset contour threshold range, and the offset evaluation index is within the preset offset threshold range. The preset area should ensure that the glass bottles and jars can be photographed by the preset capture device when passing through; the accuracy of triggering glass bottles and jars by the visual positioning camera is improved.

[0036] Among them, the contour data of glass bottles and jars are obtained by extracting the contours of glass bottle and jar images; the contour data of glass bottles and jars include image height, image width, pixel distance and standard angle; the pixel distance represents the distance from the center point of the top pixel of the glass bottle and jar to the center point of the bottom pixel in the glass bottle and jar image at a preset time point; the standard angle represents the relative tilt angle between the glass bottle and the industrial camera at a preset time point; a preset capture device is installed in a preset area on the glass bottle and jar production line to obtain the glass bottle and jar image, and then the glass bottle and jar image is preprocessed; the preprocessing includes graying and filtering processing, graying represents converting the color image into a grayscale image to avoid color interference, and filtering processing refers to removing high-frequency noise in the image through a low-pass filter and enhancing the contour information of the image through a high-pass filter.

[0037] It should be understood that the preset capture device includes an image sensor and a viewfinder. The basic principle of grayscale processing is to weighted average the brightness values ​​of the three RGB channels in the color image to obtain a single grayscale value. This single grayscale value reflects the brightness information of the pixel, where R, G, and B are the values ​​of the red, green, and blue channels, respectively. Filtering processing includes low-pass filtering and high-pass filtering. Common low-pass filters include Gaussian filters, which are linear smoothing filters suitable for eliminating Gaussian noise. Gaussian filtering is used to reduce the noise and detail level of glass bottle images, and high-pass filters are used to enhance the contour information of the image. It can be achieved through various edge detection operators (such as the Sobel operator). The operator can highlight the edges and contours in the image, making the contours clearer. Edge detection algorithms (such as the Canny operator) are used to identify the edges in the image, which are the key features of the contours of glass bottles. Image processing software, such as pixel positioning and distance measurement tools in OpenCV (Open Source Computer Vision Library), are used to obtain image height, image width, and pixel distance, and three-dimensional reconstruction is used to obtain the standard angle. This improves the accuracy of visual positioning cameras in triggering glass bottles and jars.

[0038] Furthermore, a contour conformity index is obtained by combining the contour data of the glass bottle and the reference contour data obtained from a preset database. The specific process is as follows: at a preset time point, camera-related data is obtained through a laser rangefinder, and a first height deviation and a second height deviation are obtained by combining the contour data of the glass bottle and the camera-related data. The camera-related data include the focal length of the camera and the standard distance. The standard distance represents the straight-line distance from a preset point of the industrial camera to a preset point of the glass bottle. The height deviation data is used to evaluate the deviation of the height of the glass bottle; the preset time point and the glass bottle are numbered, and when the number of the preset time point is 1 or the number of the glass bottle is 1, the corresponding first height deviation and second height deviation are recorded as 0, otherwise the reference contour data is obtained from the preset database, and the contour conformity index is obtained by combining the first height deviation and the second height deviation; the reference contour data includes a first contour allocation weight, a second contour allocation weight, a preset first height deviation threshold, and a preset second height deviation threshold. The first contour allocation weight is used to evaluate the influence of the first height deviation on the contour conformity index, and the second contour allocation weight is used to evaluate the influence of the second height deviation on the contour conformity index.

[0039] Specifically, the contour conformity index is calculated using the following formula:

[0040] ;

[0041] ;

[0042] ;

[0043] In the formula, Indicates the contour conformity index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, represents the first height deviation of the rth glass bottle at the i-th preset time point, represents the second height deviation of the rth glass bottle at the i-th preset time point, represents the image height of the rth glass bottle at the i-th preset time point, represents the image width of the r-th glass bottle at the i-th preset time point, represents the pixel distance of the rth glass bottle at the i-th preset time point, represents the standard angle of the rth glass bottle at the i-th preset time point, represents the focal length of the industrial camera corresponding to the rth glass bottle at the i-th preset time point, represents the standard distance of the rth glass bottle at the i-th preset time point, represents the first contour assignment weight, represents the second contour assignment weight, Indicates the preset first height deviation threshold, represents a preset second height deviation threshold, and e represents a natural constant.

[0044] In this embodiment, the preset first height deviation threshold is represented by the variance value of the glass bottle height data of the historical period in the preset database, and the preset second height deviation threshold is represented by the standard deviation value of the glass bottle height data of the historical period in the preset database. A laser rangefinder is used to obtain the straight-line distance from the industrial camera to the glass bottle at a preset time point, and the camera focal length can be directly read from the industrial camera; thereby improving the accuracy of the visual positioning camera in triggering glass bottles.

[0045] Specifically, the sum of the first contour allocation weight and the second contour allocation weight is 1, for example, the first contour allocation weight is 0.5, and the second contour allocation weight is 0.5; the first contour allocation weight is the weight corresponding to the pixel distance value preset in the preset database, which represents the influence of the pixel distance value on the contour conformity index. When used, the weight corresponding to the preset pixel distance value can be directly obtained from the preset database, and the corresponding relationship can be a pre-set mapping relationship. For example, the pixel distance of the glass bottle positioning trigger training set and the weight corresponding to the pixel distance value preset in the preset database form a mapping set, and the real-time pixel distance is input into the mapping set to obtain the corresponding weight, wherein the mapping relationship can be a one-to-one correspondence or a many-to-one relationship. In this example, its value range is [0, 1].

[0046] The algorithm of this embodiment combines the glass bottle contour data and the camera-related data for comprehensive analysis to obtain the contour conformity index. In this formula, there is a common adjustment relationship between the glass bottle contour data and the camera-related data. For example, the choice of focal length will affect the height and width measurement of the glass bottle in the image, because the focal length determines the geometric distortion and viewing angle range of the glass bottle image. The shorter the focal length, the wider the viewing angle range. The edge of the glass bottle image may have barrel distortion. The accuracy of the standard distance directly affects the height deviation of the glass bottle. The pixel distance, the camera focal length and the standard distance jointly determine the height measurement of the actual object. The tilt angle of the glass bottle relative to the industrial camera will affect the measurement of the pixel distance, because any tilt will cause an error between the height in the glass bottle image and the actual height. The camera focal length and the standard distance determine the size and shape of the field of view, which in turn affects the representation of the glass bottle in the glass bottle image. The measurement of pixel distance depends on accurate focal length and standard distance, as well as the accuracy of image processing software. The measurement of standard angles needs to take into account the relative position between the camera and the glass bottle, which may be affected by the position of the equipment on the production line; as the image height and pixel distance increase, the image width, camera focal length and standard angle decrease, the contour conformity index increases, which means that the image height and pixel distance are directly proportional to the contour conformity index, and the image width, camera focal length and standard angle are inversely proportional to the contour conformity index.

[0047] Specifically, , ,but represents the first deviation ratio of the rth glass bottle at the i-th preset time point, then represents the second deviation ratio of the rth glass bottle at the i-th preset time point, the contour conformity index can be simplified as: , assuming that the first deviation ratio ranges from 0 to 10, the second deviation ratio ranges from 0 to 10, the first contour allocation weight is 0.5, and the second contour allocation weight is 0.5, such as Figure 2 As shown, the profile conformity index variation statistics provided for the present application are shown in FIG. Figure 2 It can be seen that when the second deviation ratio is fixed at 0 or 5, as the first deviation ratio gradually increases, the contour conformity index gradually increases. When the first deviation ratio is fixed, as the second deviation ratio increases from 0 to 5, the contour conformity index gradually increases, which means that the contour conformity of the glass bottles and jars gradually improves; the accuracy of triggering the glass bottles and jars by the visual positioning camera is improved.

[0048] Furthermore, the specific process of determining whether to perform image capture adjustment in combination with the preset contour threshold range obtained from the preset database is as follows: Q1, obtaining the preset contour threshold range from the preset database, and determining whether the contour conformity index is within the preset contour threshold range. When the contour conformity index is within the preset contour threshold range, no image capture adjustment is performed, otherwise Q2 is executed; Q2, sending a prompt to the preset personnel to add a preset lighting device, the preset lighting device is used to eliminate shadows and reflections of the glass bottle image, when the monitored contour conformity index is within the preset contour threshold range, the execution is stopped, otherwise Q3 is executed; Q3, obtaining the preset frequency threshold and preset multiple from the preset database, sending a prompt to the preset personnel to increase the capture frequency of the preset capture device by the preset multiple of the preset frequency threshold, when the monitored contour conformity index is within the preset contour threshold range, the execution is stopped, otherwise feedback is given to the preset personnel to re-acquire the glass bottle image.

[0049] In this embodiment, a preset contour threshold and a preset multiple are obtained from a preset database, the preset contour threshold is represented by the average value of glass bottle height data in a historical period, 0.5 times the preset contour threshold is used as the lower limit of the preset contour threshold range, and 1.5 times the preset contour threshold is used as the upper limit of the preset contour threshold range, the preset lighting device includes a halogen lamp and a high-frequency fluorescent lamp, the preset frequency threshold is represented by the average value of the frequency data of glass bottles captured by the industrial camera in the historical period, the capture frequency of the preset capture device is increased by a preset multiple of the preset frequency threshold, and the preset multiple is up to 5 times, considering that there are shadows or reflections in the image of the glass bottle, resulting in contour distortion, the brightness of the glass bottle image is increased by adding the preset lighting device, and the clarity of the glass bottle image and the accuracy of the contour are improved. Due to the fast movement speed of the glass bottle and the slow response speed of the capture device, its contour cannot be accurately captured. At this time, by increasing the capture frequency of the capture device; the accuracy of the visual positioning camera triggering the glass bottle is improved.

[0050] Furthermore, an offset evaluation index is obtained by combining the offset data of the glass bottle and the reference offset data obtained from a preset database. The specific process is as follows: at a preset time point, the offset data of the glass bottle is obtained by a preset offset measuring device, the preset offset measuring device includes a laser displacement sensor and an angle sensor, the offset data of the glass bottle includes the coordinates of the glass bottle and the offset angle, the offset angle represents the angle of rotation of the glass bottle when it passes through a preset area at the preset time point; the preset trigger position coordinates and the preset offset angle threshold are obtained from the preset database, and a first offset deviation and a second offset deviation are obtained in combination with the offset data of the glass bottle, the first offset deviation is used to evaluate the deviation of the trigger position, and the second offset deviation is used to evaluate the deviation of the offset angle; a preset first offset deviation threshold and a preset first offset deviation threshold are obtained from the preset database, and a ratio of the first offset deviation to the preset first offset deviation threshold is obtained in combination with the first offset deviation and the preset first offset deviation threshold, and a ratio of the first offset deviation to the preset first offset deviation threshold is obtained in combination with the first offset deviation and the preset first offset deviation threshold. The second offset deviation and the preset second offset deviation threshold obtain the ratio of the second offset deviation and the preset second offset deviation threshold; the preset time point and the glass bottle are numbered, when the preset time point is numbered 1 or the glass bottle is numbered 1, the corresponding first offset deviation and the second offset deviation are recorded as 0, otherwise the preset first offset allocation weight and the preset first offset allocation weight are obtained from the preset database, and the offset evaluation index is obtained by combining the ratio of the first offset deviation and the preset first offset deviation threshold, and the ratio of the second offset deviation and the preset second offset deviation threshold; the preset first offset allocation weight is used to evaluate the influence of the first offset deviation on the offset evaluation index, and the preset second offset allocation weight is used to evaluate the influence of the second offset deviation on the offset evaluation index, and the reference offset data includes the preset trigger position coordinates, the preset offset angle threshold, the preset first offset deviation threshold, the preset second offset deviation threshold, the preset first offset allocation weight and the preset second offset allocation weight.

[0051] The deviation assessment index is calculated using the following formula:

[0052] ;

[0053] ;

[0054] ;

[0055] In the formula, represents the deviation evaluation index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, represents the first offset deviation of the rth glass bottle at the i-th preset time point, represents the second offset deviation of the rth glass bottle at the i-th preset time point, represents the coordinate of the rth glass bottle in the X-axis direction at the i-th preset time point, represents the coordinate of the rth glass bottle in the Y-axis direction at the i-th preset time point, represents the offset angle of the rth glass bottle at the i-th preset time point, Indicates the coordinate of the preset trigger position in the X-axis direction. Indicates the coordinate of the preset trigger position in the Y-axis direction. Indicates the preset offset angle threshold, represents a preset first offset deviation threshold, represents a preset second offset deviation threshold, and e represents a natural constant.

[0056] In this embodiment, the preset trigger position coordinates are respectively represented by the average values ​​of the horizontal coordinate data and the vertical coordinate data of the trigger position of the industrial camera in the historical time period in the historical database, the preset offset angle threshold is represented by the average value of the offset angle data of the glass bottle when the industrial camera is triggered in the historical time period in the historical database, the preset first offset deviation threshold is represented by the variance value of the offset data of the glass bottle when the industrial camera is triggered in the historical time period in the historical database, and the preset second offset deviation threshold is represented by the variance value of the offset angle data of the glass bottle when the industrial camera is triggered in the historical time period in the historical database; the angle sensor is used to measure the rotation angle of the glass bottle when it passes through the preset area at a preset time point, and the laser displacement sensor measures the coordinate position of the glass bottle by laser triangulation. The laser beam emitted by the laser transmitter irradiates the surface of the glass bottle and is captured by the receiver after being reflected by the surface. According to the angle of the reflected light and the known distance between the laser and the camera, the distance between the sensor and the surface of the object, that is, the coordinate position of the glass bottle, can be calculated.

[0057] Specifically, the sum of the preset first offset allocation weight and the preset second offset allocation weight is 1, for example, the preset first offset allocation weight is 0.5, and the preset second offset allocation weight is 0.5; the preset first offset allocation weight is the weight corresponding to the preset offset angle value in the preset database, which represents the influence of the offset angle value on the offset evaluation index. When used, the weight corresponding to the preset offset angle value can be directly obtained from the preset database, and the corresponding relationship can be a pre-set mapping relationship. For example, the offset angle of the glass bottle positioning trigger training set and the weight corresponding to the preset offset angle value in the preset database form a mapping set, and the real-time offset angle is input into the mapping set to obtain the corresponding weight, wherein the mapping relationship can be a one-to-one correspondence or a many-to-one relationship. In this example, its value range is [0, 1].

[0058] The algorithm of this embodiment combines the offset data of the glass bottle and jar, and comprehensively analyzes to obtain the offset evaluation index. In this formula, there is a common adjustment relationship between the offset data of the glass bottle and jar and the camera-related data. For example, the measurement of coordinates may be affected by the offset angle, because the rotation of the glass bottle and jar can cause the laser beam to be unable to stably irradiate the predetermined measurement point, which may change the relative position between the laser displacement sensor and the glass bottle and jar. During the rotation process, the undulations or irregular shapes on the surface of the glass bottle and jar may also cause the reflection path of the laser beam to change. Similarly, the measurement of the offset angle may be affected by the coordinate deviation. If the position of the glass bottle and jar changes, the originally set measurement path or direction may also change, because the change in the position of the glass bottle and jar may affect the reading of the angle sensor. The first offset deviation is used to evaluate the deviation between the actual coordinate position of the glass bottle and jar and the preset trigger position coordinate, and the second offset deviation is used to evaluate the deviation between the actual offset angle and the preset offset angle threshold. The calculation results of these two deviations are crucial to evaluating the position accuracy of the glass bottle and jar.

[0059] Specifically, assuming that the first offset deviation The range is 0-10 (mm), second offset deviation The range is 0-5 (degrees), the preset first offset allocation weight is 0.5, the preset second offset allocation weight is 0.5, and the preset first offset deviation threshold The second offset deviation threshold is preset to 2 (mm). is 1 (degrees), the statistical table of the change of the offset evaluation index is shown in Table 1:

[0060] Table 1 Statistics of changes in the deviation assessment index

[0061]

[0062] It can be seen from Table 1 that with the first offset deviation and the second offset deviation The gradual increase of the deviation evaluation index means that the deviation degree of the glass bottles and cans from the preset trigger position is gradually increasing, which intuitively reflects that the position stability of the glass bottles and cans on the production line is gradually weakening, and reveals that the deviation degree between the glass bottles and cans and the preset trigger position is gradually increasing; the accuracy of the visual positioning camera in triggering the glass bottles and cans is improved.

[0063] Furthermore, the specific process of determining whether to perform an offset adjustment in combination with the preset offset threshold range obtained from the preset database is as follows: P1, obtain the preset offset threshold range from the preset database, and determine whether the offset evaluation index is within the preset offset threshold range. When the offset evaluation index is within the preset offset threshold range, no offset adjustment is performed, otherwise P2 is executed; P2, obtain the preset speed threshold and preset multiple from the preset database, and send a prompt to the preset personnel to reduce the conveying speed of the conveyor belt by the preset multiple of the preset speed threshold. When the monitored offset evaluation index is within the preset offset threshold range, the execution is stopped, otherwise P3 is executed; P3, send a prompt to the preset personnel to install shock pads and shock absorbers to reduce the vibration frequency of the conveyor belt. When the offset evaluation index is within the preset offset threshold range, the execution is stopped, otherwise feedback is given to the preset personnel to perform conveyor belt maintenance.

[0064] In this embodiment, a preset offset threshold and a preset multiple are obtained from a preset database, the preset offset threshold is represented by the average value of the offset data of glass bottles in a historical period, the preset speed threshold is represented by the average value of the conveyor belt transmission speed data in a historical period, and the preset vibration frequency threshold is represented by the average value of the conveyor belt vibration frequency data in a historical period. 0.5 times of the preset offset threshold is used as the lower limit of the preset offset threshold range, and 1.5 times of the preset offset threshold is used as the upper limit of the preset offset threshold range. By reducing the transmission speed, the dynamic deviation of the bottles in the transmission process can be reduced, thereby To reduce the deviation of glass bottles and cans, when the conveying speed of the conveyor belt is reduced by a preset multiple of the preset speed threshold, the minimum preset multiple is 0.5 times. The vibration frequency of the conveyor belt may affect the stability of the glass bottles and cans, thereby causing deviation. By reducing the vibration frequency, the impact on the stability of the glass bottles and cans can be reduced. To further reduce the deviation, when the vibration frequency of the conveyor belt is reduced by a preset multiple of the preset vibration frequency threshold, the minimum preset multiple is 0.5 times. Preset personnel will inspect the conveyor belt, including checking the centering, balance and fastening components of the conveyor belt; the accuracy of triggering glass bottles and cans by the visual positioning camera is improved.

[0065] Furthermore, the specific process of obtaining the comprehensive trigger index according to the contour conformity index and the offset evaluation index is as follows: obtaining the preset comprehensive first allocation weight and the preset comprehensive second allocation weight from the preset database, and obtaining the comprehensive trigger index in combination with the obtained contour conformity index and the offset evaluation index; the specific process of combining the obtained contour conformity index and the offset evaluation index is as follows: combining the preset comprehensive first allocation weight with the contour conformity index to obtain the change in the degree of influence of the contour conformity index, combining the preset comprehensive second allocation weight with the offset evaluation index to obtain the change in the degree of influence of the offset evaluation index, combining the change in the degree of influence of the contour conformity index with the change in the degree of influence of the offset evaluation index to obtain the comprehensive trigger index, the preset comprehensive first allocation weight is used to evaluate the degree of influence of the contour conformity index on the comprehensive trigger index, and the preset comprehensive second allocation weight is used to evaluate the degree of influence of the offset evaluation index on the comprehensive trigger index.

[0066] The comprehensive trigger index is calculated using the following formula:

[0067] ;

[0068] In the formula, represents the comprehensive trigger index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, Indicates the contour conformity index of the rth glass bottle at the i-th preset time point, represents the deviation evaluation index of the rth glass bottle at the i-th preset time point, Indicates the preset comprehensive first allocation weight, represents the preset comprehensive second allocation weight, and e represents a natural constant.

[0069] In this embodiment, the algorithm of this embodiment combines the contour conformity index and the offset evaluation index, and comprehensively analyzes to obtain the comprehensive trigger index. In this formula, there is a common adjustment relationship between the contour conformity index and the offset evaluation index. For example, if the height of the glass bottle is offset from the preset position point, it may affect the accurate matching of the contour, because the detected contour may be partially beyond the field of view or blocked. If the contour of the glass bottle is significantly deformed (such as squeezed or twisted), it may affect the accuracy of its position detection, because the position detection may rely on the feature points of the contour. The accuracy of the visual positioning camera triggering the glass bottle is improved.

[0070] Specifically, the sum of the preset comprehensive first allocation weight and the preset comprehensive second allocation weight is 1, for example, the preset comprehensive first allocation weight is 0.5, and the preset comprehensive second allocation weight is 0.5; the preset comprehensive first allocation weight is the weight corresponding to the glass bottle image height value preset in the preset database, which represents the influence of the glass bottle image height value on the comprehensive trigger index. When used, the weight corresponding to the preset glass bottle image height value can be directly obtained from the preset database, and the corresponding relationship can be a pre-set mapping relationship. For example, the glass bottle image height in the glass bottle positioning trigger training set and the weight corresponding to the glass bottle image height value preset in the preset database form a mapping set, and the real-time glass bottle image height is input into the mapping set to obtain the corresponding weight, wherein the mapping relationship can be a one-to-one correspondence or a many-to-one relationship. In this example, its value range is [0, 1].

[0071] Furthermore, the specific process of correction and adjustment is as follows: W1, obtain the preset trigger threshold range from the preset database, and determine whether the comprehensive trigger index is within the preset trigger threshold range. When the comprehensive trigger index is within the preset trigger threshold range, no correction or adjustment is performed, otherwise W2 is executed; W2, send a prompt to the preset personnel to replace the industrial camera. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise W3 is executed; W3, send a prompt to the preset personnel to replace the preset encoder. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise it is fed back to the preset personnel for system maintenance.

[0072] In this embodiment, a preset trigger threshold and a preset multiple are obtained from a preset database. The preset trigger threshold is represented by the average value of the glass bottle trigger data in the historical period. 0.5 times the preset trigger threshold is used as the lower limit of the preset trigger threshold range, and 1.5 times the preset trigger threshold is used as the upper limit of the preset offset threshold range. The industrial camera is a key device for capturing images of glass bottles and cans on the production line, and its performance directly affects the accuracy of contour extraction and offset measurement. The preset encoder is used to accurately measure the position and offset angle of glass bottles and cans. System maintenance may include checking and maintaining mechanical parts and calibrating measuring equipment. After maintenance, restart the production line and continue to monitor the comprehensive trigger index until it is within the preset trigger threshold range; the accuracy of visual positioning cameras triggering glass bottles and cans is improved.

[0073] like Figure 3As shown, it is a structural schematic diagram of a positioning data processing device for a visual camera provided in an embodiment of the present application. The positioning data processing device for a visual camera provided in an embodiment of the present application includes: a contour conformance index acquisition module, an offset evaluation index acquisition module and a comprehensive trigger index acquisition module: wherein the contour conformance index acquisition module is used to install a preset capture device in a preset area on a glass bottle production line to acquire glass bottle images and perform contour extraction to acquire glass bottle contour data, obtain a contour conformance index in combination with the glass bottle contour data and reference contour data acquired from a preset database, and determine whether to perform image capture adjustment in combination with a preset contour threshold range acquired from the preset database, the image capture adjustment is used to adjust the contour conformance index to within a preset contour threshold range, the contour conformance index is used to evaluate the contour condition of the glass bottle, the glass bottle contour data is used to describe the contour features in the glass bottle image, and the contour extraction is used to extract the contour features in the glass bottle image. edge contour features; the offset evaluation index acquisition module is used to install a preset encoder in a preset area on the glass bottle production line and obtain the offset data of the glass bottles, combine the glass bottle offset data and the reference offset data obtained from the preset database to obtain the offset evaluation index, and combine the preset offset threshold range obtained from the preset database to determine whether to perform an offset adjustment, the offset adjustment is used to adjust the offset evaluation index to within the preset offset threshold range, the offset evaluation index is used to evaluate the offset of the glass bottles and preset trigger positions, and the glass bottles and offset data are used to describe the offset of the glass bottles and preset trigger positions; the comprehensive trigger index acquisition module is used to obtain the comprehensive trigger index according to the contour compliance index and the offset evaluation index, and the preset trigger threshold range is obtained from the preset database. When the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is performed, and the correction adjustment is used to adjust the comprehensive trigger index to within the preset trigger threshold range.

[0074] In this embodiment, the contour conformity index acquisition module makes adjustments based on the comparison result between the contour conformity index and the preset contour threshold range when the contour conformity index is not within the preset contour threshold range; the offset assessment index acquisition module makes adjustments based on the comparison result between the offset assessment index and the preset offset threshold range when the offset assessment index is not within the preset offset threshold range; the comprehensive trigger index acquisition module compares the comprehensive trigger index with the preset trigger threshold range to determine whether to issue a trigger prompt; when the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued; through the coordinated work of various modules, real-time monitoring and evaluation of the contour quality and position offset of glass bottles and jars are achieved; and the accuracy of triggering glass bottles and jars by the visual positioning camera is improved.

[0075] To summarize, the embodiment of the present application obtains glass bottle and jar images and performs contour extraction to obtain glass bottle and jar contour data and obtains a contour conformity index in combination with reference contour data, then obtains glass bottle and jar offset data, obtains an offset evaluation index in combination with the glass bottle and jar offset data, and finally obtains a comprehensive trigger index based on the contour conformity index and the offset evaluation index, thereby improving the real-time adjustment of the trigger conditions of the glass bottles and jars, and further improving the accuracy of the visual positioning camera triggering the glass bottles and jars, effectively solving the problem of low triggering accuracy of the visual positioning camera corresponding to the glass bottles and jars in the prior art.

[0076] It will be appreciated by those skilled in the art that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Furthermore, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0077] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0078] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0079] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0080] Although the preferred embodiments of the present invention have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of the present invention.

[0081] Obviously, those skilled in the art can make various changes and modifications to the present invention without departing from the spirit and scope of the present invention. Thus, if these modifications and variations of the present invention fall within the scope of the claims of the present invention and their equivalents, the present invention is also intended to include these modifications and variations.

Claims

1. A positioning data processing method for a visual camera, characterized in that: The following steps are involved: S1, installing a preset capture device in a preset area on a glass bottle production line to obtain images of glass bottles and extract contours to obtain contour data of the glass bottles, combining the contour data of the glass bottles and reference contour data obtained from a preset database to obtain a contour conformity index, and combining a preset contour threshold range obtained from the preset database to determine whether to perform image capture adjustment, wherein the contour conformity index is used to evaluate the contour condition of the glass bottles; S2, installing a preset encoder in a preset area on the glass bottle production line and obtaining the offset data of the glass bottle, obtaining an offset evaluation index by combining the offset data of the glass bottle and the reference offset data obtained from a preset database, and determining whether to perform an offset adjustment by combining a preset offset threshold range obtained from the preset database, wherein the offset evaluation index is used to evaluate the offset of the glass bottle from a preset trigger position; S3, obtaining a comprehensive trigger index according to the contour conformance index and the offset evaluation index, and obtaining a preset trigger threshold range from a preset database. When the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is performed; The glass bottle contour data is obtained by extracting the contour of the glass bottle image; The glass bottle outline data includes image height, image width, pixel distance and standard angle; The pixel distance represents the distance from the center point of the top pixel of the glass bottle to the center point of the bottom pixel in the image of the glass bottle at a preset time point; The standard angle represents the relative tilt angle between the glass bottle and the industrial camera at a preset time point; The method further includes installing a preset capture device in a preset area on the glass bottle production line to obtain the glass bottle image, and then preprocessing the glass bottle image; The preprocessing includes graying and filtering; The specific process of combining the glass bottle contour data and the reference contour data obtained from the preset database to obtain the contour conformity index is as follows: At a preset time point, camera-related data is obtained by a laser rangefinder, and a first height deviation and a second height deviation are obtained by combining the glass bottle contour data and the camera-related data, wherein the camera-related data includes a camera focal length and a standard distance; The preset time points and glass bottles are numbered. When the preset time point is numbered 1 or the glass bottle is numbered 1, the corresponding first height deviation and second height deviation are recorded as 0. Otherwise, reference contour data is obtained from the preset database, and the contour conformity index is obtained by combining the first height deviation and the second height deviation. The reference contour data includes a first contour allocation weight, a second contour allocation weight, a preset first height deviation threshold, and a preset second height deviation threshold; The profile conformity index is calculated using the following formula: ; ; ; In the formula, Indicates the contour conformity index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, represents the first height deviation of the rth glass bottle at the i-th preset time point, represents the second height deviation of the rth glass bottle at the i-th preset time point, represents the image height of the rth glass bottle at the i-th preset time point, represents the image width of the r-th glass bottle at the i-th preset time point, represents the pixel distance of the rth glass bottle at the i-th preset time point, represents the standard angle of the rth glass bottle at the i-th preset time point, represents the focal length of the industrial camera corresponding to the rth glass bottle at the i-th preset time point, represents the standard distance of the rth glass bottle at the i-th preset time point, represents the first contour assignment weight, represents the second contour assignment weight, Indicates the preset first height deviation threshold, represents the preset second height deviation threshold, and e represents a natural constant; The specific process of combining the glass bottle offset data and the reference offset data obtained from the preset database to obtain the offset evaluation index is as follows: At a preset time point, the offset data of the glass bottle is obtained by a preset offset measuring device, wherein the offset data of the glass bottle includes the coordinates of the glass bottle and the offset angle; Obtaining preset trigger position coordinates and preset offset angle thresholds from a preset database, and obtaining a first offset deviation and a second offset deviation in combination with the offset data of the glass bottle, wherein the first offset deviation is used to evaluate the deviation of the trigger position, and the second offset deviation is used to evaluate the deviation of the offset angle; Acquire a preset first offset deviation threshold and a preset first offset deviation threshold from a preset database, obtain a ratio of the first offset deviation to the preset first offset deviation threshold by combining the first offset deviation and the preset first offset deviation threshold, and obtain a ratio of the second offset deviation to the preset second offset deviation threshold by combining the second offset deviation and the preset second offset deviation threshold; The preset time points and glass bottles are numbered. When the preset time point is numbered 1 or the glass bottle is numbered 1, the corresponding first offset deviation and second offset deviation are recorded as 0. Otherwise, the preset first offset allocation weight and the preset first offset allocation weight are obtained from the preset database, and the offset evaluation index is obtained by combining the ratio of the first offset deviation and the preset first offset deviation threshold, and the ratio of the second offset deviation and the preset second offset deviation threshold; The reference offset data includes a preset trigger position coordinate, a preset offset angle threshold, a preset first offset deviation threshold, a preset second offset deviation threshold, a preset first offset allocation weight, and a preset second offset allocation weight; The deviation assessment index is calculated using the following formula: ; ; ; In the formula, represents the deviation evaluation index of the rth glass bottle at the i-th preset time point, , i represents the number of the preset time point, n represents the total number of preset time points, , r represents the number of glass bottles, m represents the total number of glass bottles, represents the first offset deviation of the rth glass bottle at the i-th preset time point, represents the second offset deviation of the rth glass bottle at the i-th preset time point, represents the coordinate of the rth glass bottle in the X-axis direction at the i-th preset time point, represents the coordinate of the rth glass bottle in the Y-axis direction at the i-th preset time point, represents the offset angle of the rth glass bottle at the i-th preset time point, Indicates the coordinate of the preset trigger position in the X-axis direction. Indicates the coordinate of the preset trigger position in the Y-axis direction. Indicates the preset offset angle threshold, represents a preset first offset deviation threshold, represents a preset second offset deviation threshold, and e represents a natural constant.

2. A positioning data processing method for a visual camera as claimed in claim 1, characterized in that: The specific process of determining whether to perform image capture adjustment in combination with the preset contour threshold range obtained from the preset database is as follows: Q1, obtaining a preset contour threshold range from a preset database, and determining whether the contour coincidence index is within the preset contour threshold range. When the contour coincidence index is within the preset contour threshold range, no image capture adjustment is performed, otherwise Q2 is executed; Q2, send a reminder to the preset personnel to add a preset lighting device. When the monitored contour conformity index is within the preset contour threshold range, the execution stops, otherwise Q3 is executed; Q3, obtain the preset frequency threshold and preset multiple from the preset database, send a prompt to the preset personnel to increase the capture frequency of the preset capture device by the preset multiple of the preset frequency threshold, and stop the execution when the monitored contour meets the index within the preset contour threshold range, otherwise feedback is given to the preset personnel to re-acquire the glass bottle image.

3. A positioning data processing method for a visual camera as claimed in claim 1, characterized in that: The specific process of determining whether to perform offset adjustment in combination with the preset offset threshold range obtained from the preset database is as follows: P1, obtain a preset offset threshold range from a preset database, and determine whether the offset evaluation index is within the preset offset threshold range. When the offset evaluation index is within the preset offset threshold range, no offset adjustment is performed, otherwise, P2 is executed; P2, obtains the preset speed threshold and preset multiple from the preset database, sends a prompt to the preset personnel to reduce the conveying speed of the conveyor belt by the preset multiple of the preset speed threshold, and stops executing when the monitored deviation evaluation index is within the preset deviation threshold range, otherwise executes P3; P3, sends a prompt to the preset personnel to install shock pads and shock absorbers to reduce the vibration frequency of the conveyor belt. When the offset evaluation index is within the preset offset threshold range, the execution is stopped. Otherwise, feedback is given to the preset personnel to perform conveyor belt maintenance.

4. A positioning data processing method for a visual camera as claimed in claim 1, characterized in that: The specific process of obtaining the comprehensive trigger index according to the profile compliance index and the offset evaluation index is as follows: Obtaining a preset comprehensive first allocation weight and a preset comprehensive second allocation weight from a preset database, and obtaining a comprehensive trigger index in combination with the obtained profile conformance index and offset evaluation index; The specific process of combining the obtained contour conformity index and offset evaluation index is as follows: The preset comprehensive first allocation weight and the contour conformity index are combined to obtain the change in the influence of the contour conformity index, the preset comprehensive second allocation weight is combined with the offset assessment index to obtain the change in the influence of the offset assessment index, and the change in the influence of the contour conformity index is combined with the change in the influence of the offset assessment index to obtain the comprehensive trigger index.

5. A positioning data processing method for a visual camera as claimed in claim 1, characterized in that: The specific process of the correction and adjustment is as follows: W1, obtain the preset trigger threshold range from the preset database, and determine whether the comprehensive trigger index is within the preset trigger threshold range. When the comprehensive trigger index is within the preset trigger threshold range, no correction adjustment is performed, otherwise W2 is executed; W2, send a reminder to the preset personnel to replace the industrial camera. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger reminder is issued, otherwise W3 is executed; W3, sends a reminder to the preset personnel to replace the preset encoder. When the monitored comprehensive trigger index is within the preset trigger threshold range, a trigger reminder is issued, otherwise it is fed back to the preset personnel for system maintenance.

6. A device using the positioning data processing method for a visual camera as claimed in any one of claims 1 to 5, characterized in that: It includes contour compliance index acquisition module, offset evaluation index acquisition module and comprehensive trigger index acquisition module: The contour matching index acquisition module is used to install a preset capture device in a preset area on the glass bottle production line to acquire glass bottle images and perform contour extraction to acquire glass bottle contour data, combine the glass bottle contour data and reference contour data acquired from a preset database to acquire a contour matching index, and combine the preset contour threshold range acquired from the preset database to determine whether to perform image capture adjustment, and the contour matching index is used to evaluate the contour condition of the glass bottle; The offset evaluation index acquisition module is used to install a preset encoder in a preset area on the glass bottle production line and obtain the offset data of the glass bottle, obtain the offset evaluation index by combining the offset data of the glass bottle and the reference offset data obtained from the preset database, and determine whether to perform offset adjustment by combining the preset offset threshold range obtained from the preset database, and the offset evaluation index is used to evaluate the offset of the glass bottle from the preset trigger position; The comprehensive trigger index acquisition module is used to obtain the comprehensive trigger index according to the contour compliance index and the offset evaluation index, and obtain the preset trigger threshold range from the preset database. When the comprehensive trigger index is within the preset trigger threshold range, a trigger prompt is issued, otherwise a correction adjustment is performed.

Citation Information

Patent Citations

  • Assistant data processing method for improving image positioning precision of stereoscopic plotting camera

    CN102306160B

  • Method and system for camera positioning inside real space

    CN112837375B

  • Monitoring regulation and control system applied to closed-loop vehicle attitude contour sensing module

    CN117841985A