Industrial programmable controller production automation detection method

By combining the chunking model of the luminous layout and CNN model of the quality inspection image, dynamic adjustment of the lighting configuration is solved, and the problem that traditional detection solutions are difficult to adapt to industrial programmable controller components of different materials and shapes is significantly improved. The accuracy of detection is greatly improved and automation level.

CN119200575AActive Publication Date: 2024-12-27TUOFUBAO (NANJING) POWER TECH CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202411751746.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-02
Publication Date
2024-12-27
Estimated Expiration
2044-12-02

AI Technical Summary

Technical Problem

Traditional fixed lighting solutions are difficult to adapt to industrial programmable controller components of different materials and geometric shapes, resulting in reflective interference detection results, affecting the accuracy of automated visual inspection.

Method used

The tiling block layout and blocking model of quality inspection image lighting is adopted, and the lighting configuration is dynamically adjusted through image preprocessing, multi-scale feature extraction and reflection suppression function optimization, and the appearance detection and performance analysis are combined with the CNN model to ensure detection accuracy and consistency.

Benefits of technology

It improves image quality and detection accuracy, reduces the risks of misjudgment and missed inspection, improves the degree of automation of the production line and product quality control capabilities, and achieves an efficient and reliable automated inspection process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119200575A_ABST
    Figure CN119200575A_ABST
Patent Text Reader

Abstract

The invention discloses an automatic detection method for production of an industrial programmable controller, and relates to the technical field of automatic detection. The invention discloses an industrial programmable controller production automation detection method. The method comprises production automation light adjustment, production automation appearance detection and production automation feature fusion detection. According to the method, the block image set of the initial to-be-tested controller is acquired, and the illumination block layout model is used for analysis and optimization, so that the quality and consistency of image shooting are ensured; by removing noise and interference and optimizing illumination conditions, the definition and availability of the image are improved; through an appearance detection model, the appearance of the controller is accurately detected by using CNN and other technologies, and it is ensured that the controller conforms to design specifications; and in combination with a performance test data set, analysis is performed through a performance detection model, so that the functionality and reliability of the controller are ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the technical field of automated detection, and in particular to an automated detection method for production of an industrial programmable controller. Background Art

[0002] The production inspection process of industrial programmable controllers includes appearance inspection and functional testing, which aims to ensure that the products are of high quality and reliability after leaving the factory; appearance inspection checks the appearance quality of the product through manual or automated equipment to ensure that there is no physical damage, defects or non-standard appearance features; functional testing ensures that the various functions of the industrial programmable controller, such as the input and output interface, processing power and response speed, operate normally according to design requirements.

[0003] Since industrial programmable controllers usually use special materials, such as metal alloys or high-performance plastics, these materials will produce inconsistent reflective effects under different lighting conditions, which poses a challenge to automated visual inspection systems; traditional fixed lighting schemes are difficult to adapt to industrial programmable controller components of different materials and geometries, resulting in reflections interfering with detection results; therefore, it is necessary to introduce an automated detection method that can dynamically adjust the lighting configuration according to the different materials and parts of the industrial programmable controller to improve image quality and detection accuracy. Summary of the invention

[0004] The present invention aims to provide an automated production detection method for an industrial programmable controller, which automatically completes the quality detection of the industrial programmable controller while ensuring the detection accuracy.

[0005] An industrial programmable controller production automation detection method comprises the following steps: Step S1: production automation lighting adjustment; Get the initial controller block image set X of the controller under test, X={X i |i=1,2,…,I},X i Represents the initial block image X of the controller component to be tested i , I is the total number of blocks of the components of the controller to be tested; the initial block image set of the controller to be tested is input into the block model of the quality inspection image illumination block layout for analysis to obtain the block illumination layout scheme of the controller to be tested; based on the block illumination layout scheme of the controller to be tested, the block image of the controller to be tested is re-shot to obtain the block detection image set of the controller to be tested; the block model of the quality inspection image illumination block layout includes an image preprocessing layer, a block feature analysis layer, an illumination optimization layer and a scheme output layer, which is constructed based on the improved image processing method and is used to perform image preprocessing on the initial block image set X of the controller to be tested to remove image noise and interference; Step S2: production automated appearance inspection; According to the block detection image set of the controller to be tested and the controller appearance detection model, the appearance detection of the controller to be tested is performed to obtain the appearance detection result of the controller to be tested; the controller appearance detection model includes a model registration layer, an image fusion layer, an appearance detection layer and an appearance detection result output layer, which is constructed based on the CNN model and is used to perform appearance detection using the point cloud registration model; Step S3: production automation feature fusion detection; Get the controller performance test data set Y of the controller under test, Y={Y n |n=1, 2, ..., N}; where N is the total number of sub-items of the controller performance test to be tested, Y n Indicates the performance index of the controller to be tested Y n ; Input the performance test data set Y of the controller to be tested into the controller performance detection model for data analysis to obtain the performance detection result of the controller to be tested; if the appearance detection result and the performance detection result of the controller to be tested are both passed, the controller to be tested completes a production automation detection; otherwise, readjust the controller to be tested.

[0006] As a preferred technical solution of the present invention, the quality inspection image illumination block layout block model includes an image preprocessing layer, a block feature analysis layer, an illumination optimization layer and a solution output layer; The image preprocessing layer is used to process the initial controller component block image X in the initial controller block image set X. i Perform preprocessing to obtain the preprocessed initial controller component block image X i '; The block feature analysis layer is used to pre-process the initial block image X of the controller component to be tested. i 'Perform multi-scale feature extraction to obtain the characteristic region feature Z of the controller component to be tested i ; The illumination optimization layer is used to measure the characteristic area Z of the controller component to be tested. i The reflection suppression function is used to optimize the lighting scheme and obtain the block lighting layout F of the controller to be tested. i ; The output layer of the scheme is used to loop through the initial controller component block images X in the initial controller block image set X. i , get the block lighting layout F of all controllers to be tested i ; Divide all controllers to be tested into blocks for lighting layout F i The blocks are combined to obtain a lighting layout scheme for the controller to be tested, and the lighting layout scheme for the controller to be tested is output.

[0007] As a preferred technical solution of the present invention, the specific steps of performing multi-scale feature extraction in the block feature analysis layer include: Preprocess the initial block image X of the controller component to be tested i 'Extract the region of interest to obtain the region of interest image G of the controller component to be tested i ; The specific steps for extracting the region of interest include: Calculate the preprocessed initial block image X of the controller component to be tested i The midline pixel intensity of ' and the two adjacent columns of pixels are bilaterally filtered to obtain a smoothed block image C of the controller component to be tested. i ; Smoothing the block image C of the controller component to be tested i Calculate the maximum continuous pixel gradient in the same direction at the vertical coordinate to obtain the image G of the region of interest of the controller component to be tested i ; The image G of the region of interest of the controller component to be tested is divided into blocks i Perform the first denoising process to obtain the initial denoised image G of the block area of ​​interest of the controller component to be tested i '; The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform adaptive image segmentation and cut feature edges to obtain the block feature segmentation image P of the controller component to be tested i ; The specific steps of performing adaptive image segmentation and cutting feature edges include: The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Calculate the pixel value distribution and obtain the denoised image histogram E i ; Based on the denoised image histogram E i Search for the minimum value in the area and obtain the image segmentation threshold A i ; Based on the image segmentation threshold A i The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform image segmentation to obtain the block feature segmentation image P of the controller component to be tested i ; The block feature segmentation image P of the controller component to be tested i Perform the second denoising process to obtain the characteristic region feature Z of the controller component to be tested i .

[0008] As a preferred technical solution of the present invention, the specific steps of constructing the reflection suppression function in the illumination optimization layer include: Collect several groups of controller appearance control training samples; each group of controller appearance control training samples includes a group of reflective controller block images and adjusted controller block images; combine several groups of controller appearance control training samples to obtain a controller appearance control training set; use a basic neural network model to perform function fitting on the controller appearance control training set to obtain an initial reflection suppression function; Based on the initial reflection suppression function, K optimized reflection suppression function individuals H are constructed. k , k = 1, 2, ..., K; K optimized reflection suppression function individuals H k Combination, get the reflection suppression function iteration population; let the individual percentage be W; based on the individual percentage, divide the reflection suppression function iteration population into Q iteration groups D q , q=1, 2, ..., Q; Q=K*W; the remaining optimized reflection suppression function individuals H in the reflection suppression function iteration population k Uniformly distributed in the iteration group D q In the iteration group D q Randomly generate the best individual in the population; suppose the individual H that optimizes the reflection suppression function k The fitness is the fitness S k ; Set the maximum number of iterations; Calculate the fitness S k The specific steps include: Using the optimized reflection suppression function individual H k The reflective controller block images in the controller appearance control training samples are simulated and adjusted to obtain simulated adjusted block images; the similarity between the simulated adjusted block images and the adjusted controller block images is calculated to obtain the simulated adjustment similarity; the average of the simulated adjustment similarities of all controller appearance control training samples is taken as the fitness S k ; Based on iterative group D q Perform population iteration. In each population iteration, the iterated population D q The individual with the largest internal fitness is taken as the optimal individual in the new population; and the individual random fluctuation factor U is introduced, U=rand(L up -L down )+L down , L up represents the upper bound of the population iteration space, L down represents the lower bound of the population iteration space, rand() represents a random function; the individual random fluctuation factor U is used to iterate the population D q The individual optimization reflection suppression function in the individual mutation operation is performed to achieve the iteration group D q Update operation; When the maximum number of iterations is reached, the optimized reflection suppression function individual corresponding to the maximum fitness is output, which is the optimal optimized reflection suppression function individual; the reflection suppression function in the optimal optimized reflection suppression function individual is used as the reflection suppression function in the illumination optimization layer.

[0009] As a preferred technical solution of the present invention, the controller appearance detection model includes a model registration layer, an image fusion layer, an appearance detection layer and an appearance detection result output layer; The model registration layer is used to register the block detection image set of the controller to be tested with the standard controller point cloud model to obtain the registered component block point cloud model M i ; The image fusion layer is used to divide the registration components into block point cloud models M i The image is fused with the block detection image set of the controller to be tested to obtain the block point cloud model M of the fused registration component i '; The appearance detection layer is used to fusion-register the component block point cloud model M i 'Perform appearance inspection and obtain the appearance inspection result R of the registration component block i ; The appearance detection result output layer is used to divide all the registered parts into blocks and generate the appearance detection results R i Perform feature fusion to obtain the appearance detection result of the controller to be tested.

[0010] As a preferred technical solution of the present invention, the specific steps of training the appearance detection layer include: Collecting several groups of training registration component block point cloud models with detection target value annotations; combining several groups of training registration component block point cloud models with detection target value annotations to obtain an appearance detection training set; The appearance detection training set is input into the controller appearance detection model, and the appearance detection layer is trained using the detection target value as the target to obtain an initial appearance detection layer; the initial appearance detection layer is model evaluated to obtain an initial appearance detection layer model evaluation result; if the initial appearance detection layer model evaluation result is passed, the initial appearance detection layer is used as the appearance detection layer in the controller appearance detection model; otherwise, the model training is continued using the appearance detection training set.

[0011] As a preferred technical solution of the present invention, the controller performance detection model includes a sub-item data preprocessing layer, a sub-item data feature recognition layer and a sub-item feature result fusion layer; The sub-item data preprocessing layer is used to calculate the sub-item index Y of the controller performance under test in the controller performance test data set Y. n Perform preprocessing to obtain the performance sub-item index Y of the preprocessing controller to be tested n '; The sub-item data feature recognition layer is used to pre-process the sub-item index Y of the controller performance to be tested. n 'Perform feature recognition and obtain the performance sub-item index feature T (Y n ); The sub-item feature result fusion layer is used to combine all performance sub-item indicator features T (Y n ) to perform feature fusion and obtain the performance test results of the controller to be tested.

[0012] As a preferred technical solution of the present invention, the specific steps of training the item data feature recognition layer include: Collecting several groups of performance sub-item feature training samples; each group of performance sub-item feature training samples contains performance sub-item indicator data and performance sub-item indicator characteristic values ​​with test sub-item indicator labels; using the performance sub-item indicator characteristic values ​​as training target values ​​in a group of performance sub-item feature training samples; combining several groups of performance sub-item feature training samples to obtain a performance sub-item feature training set; The performance sub-item feature training set is input into the controller performance detection model to perform model training on the sub-item data feature recognition layer to obtain an initial sub-item data feature recognition layer; the initial sub-item data feature recognition layer is model evaluated to obtain an initial sub-item data feature recognition layer model evaluation result; if the initial sub-item data feature recognition layer model evaluation result is passed, the initial sub-item data feature recognition layer is used as the sub-item data feature recognition layer in the controller performance detection model; otherwise, the performance sub-item feature training set is used to continue model training.

[0013] The present invention has the following advantages: 1. The present invention obtains an initial block image set of the controller to be tested, and uses a lighting block layout model to analyze and optimize it to ensure the quality and consistency of image capture; by removing noise and interference and optimizing lighting conditions, the clarity and usability of the image are improved; through an appearance detection model, CNN and other technologies are used to accurately detect the appearance of the controller to ensure that it meets the design specifications; combined with a performance test data set, the performance detection model is used for analysis to ensure the functionality and reliability of the controller. If both the appearance and performance tests are passed, the production detection process is completed, otherwise adjustments are made; this method improves the degree of automation and accuracy of detection, reduces the possibility of manual intervention and misjudgment, and improves production efficiency and product quality.

[0014] 2. The present invention improves the accuracy and efficiency of detection through image processing and optimization algorithms, preprocesses and extracts features of controller component images through the quality inspection image illumination block layout model, and utilizes multi-scale feature analysis and adaptive image segmentation technology to accurately identify and remove noise and interference in the image to ensure the clarity of the feature area; the illumination optimization layer reduces the reflection effect in the image through the reflection suppression function, and improves the rationality and consistency of the illumination layout; the reflection suppression function is trained and optimized through a neural network model and an iterative optimization algorithm to ensure its applicability and robustness under different lighting conditions; this method can significantly improve the accuracy of the appearance and performance detection of the controller, reduce the risk of misjudgment and missed detection, enhance the automation level of the production line and the product quality control capability, and ultimately achieve an efficient and reliable automated detection process. BRIEF DESCRIPTION OF THE DRAWINGS

[0015] Figure 1 The present invention is a flowchart of an industrial programmable controller production automation detection method used in an embodiment of the present invention. DETAILED DESCRIPTION

[0016] In order to enable persons skilled in the art to better understand the technical solutions in the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention.

[0017] An industrial programmable controller production automation detection method, see Figure 1 As shown, the following steps are included: Step S1: Production Automation Lighting Adjustment Get the initial controller block image set X of the controller under test, X={X i |i=1,2,…,I},X i Represents the initial block image X of the controller component to be tested i , I is the total number of component blocks of the controller to be tested; the initial block image set of the controller to be tested is input into the quality inspection image illumination block layout block model for analysis to obtain the block illumination layout scheme of the controller to be tested; based on the block illumination layout scheme of the controller to be tested, the block images of the controller to be tested are re-shot to obtain the block detection image set of the controller to be tested; the quality inspection image illumination block layout block model includes an image preprocessing layer, a block feature analysis layer, an illumination optimization layer and a scheme output layer, which is constructed based on the improved image processing method and is used to perform image preprocessing on the initial block image set X of the controller to be tested to remove image noise and interference.

[0018] The controller to be tested is an industrial programmable controller, which is divided into blocks, and pictures are taken of areas of different materials in blocks.

[0019] The block layout model of quality inspection image illumination includes image preprocessing layer, block feature analysis layer, illumination optimization layer and solution output layer; The image preprocessing layer is used to process the initial controller component block image X in the initial controller block image set X. i Perform preprocessing to obtain the preprocessed initial controller component block image X i '; Through preprocessing, the contrast and clarity of the image are improved, providing higher quality input data for subsequent feature extraction and analysis, and reducing the possibility of false detection and missed detection; The block feature analysis layer is used to pre-process the initial block image X of the controller component to be tested. i 'Perform multi-scale feature extraction to obtain the characteristic region feature Z of the controller component to be tested i ; Multi-scale feature extraction can capture subtle features and important structural information in the image, improve the ability to analyze complex images, and ensure that key details are not missed; The illumination optimization layer is used to measure the characteristic area Z of the controller component to be tested. i The reflection suppression function is used to optimize the lighting scheme and obtain the block lighting layout F of the controller to be tested. i ;By optimizing the lighting conditions, the brightness and contrast of the image are balanced, avoiding the interference of reflections and shadows on image analysis, and improving the usability of the image and the accuracy of detection; The output layer of the scheme is used to loop through the initial controller component block images X in the initial controller block image set X. i , get the block lighting layout F of all controllers to be tested i ; Divide all controllers to be tested into blocks for lighting layout F i The blocks are combined to obtain a lighting layout scheme for the controller to be tested, and the lighting layout scheme for the controller to be tested is output.

[0020] The specific steps of multi-scale feature extraction in the block feature analysis layer include: Preprocess the initial block image X of the controller component to be tested i 'Extract the region of interest to obtain the region of interest image G of the controller component to be tested i .

[0021] The specific steps for extracting the region of interest include: Calculate the preprocessed initial block image X of the controller component to be tested i The midline pixel intensity of ' and the two adjacent columns of pixels are bilaterally filtered to obtain a smoothed block image C of the controller component to be tested. i ; Smoothing the block image C of the controller component to be tested iCalculate the maximum continuous pixel gradient in the same direction at the vertical coordinate to obtain the image G of the region of interest of the controller component to be tested i ; The image G of the region of interest of the controller component to be tested is divided into blocks i Perform the first denoising process to obtain the initial denoised image G of the block area of ​​interest of the controller component to be tested i '; The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform adaptive image segmentation and cut feature edges to obtain the block feature segmentation image P of the controller component to be tested i .

[0022] The specific steps of performing adaptive image segmentation and cutting feature edges include: The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Calculate the pixel value distribution and obtain the denoised image histogram E i ; Based on the denoised image histogram E i Search for the minimum value in the area and obtain the image segmentation threshold A i ; Based on the image segmentation threshold A i The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform image segmentation to obtain the block feature segmentation image P of the controller component to be tested i ; The block feature segmentation image P of the controller component to be tested i Perform the second denoising process to obtain the characteristic region feature Z of the controller component to be tested i ; Bilateral filtering can reduce noise while retaining edge details, improve image smoothness, and provide a more stable basis for subsequent gradient calculations. By identifying pixel gradient changes, it can effectively extract edges and important feature areas in the image and form a block image of the region of interest of the controller component to be tested. i ; The adaptive segmentation method can dynamically adjust the segmentation threshold according to the actual pixel distribution of the image, thereby improving the accuracy and adaptability of the segmentation; through step-by-step denoising, feature extraction and adaptive segmentation, the accuracy and reliability of image feature analysis are significantly improved, providing high-quality feature data for subsequent lighting optimization and detection.

[0023] The specific steps of constructing the reflection suppression function in the lighting optimization layer include: Collect several groups of controller appearance control training samples; each group of controller appearance control training samples includes a group of reflective controller block images and adjusted controller block images; combine several groups of controller appearance control training samples to obtain a controller appearance control training set; use a basic neural network model to perform function fitting on the controller appearance control training set to obtain an initial reflection suppression function; Based on the initial reflection suppression function, K optimized reflection suppression function individuals H are constructed. k , k = 1, 2, ..., K; K optimized reflection suppression function individuals H k Combination, to obtain the reflection suppression function iteration population; let the percentage of preferred individuals be W; based on the percentage of preferred individuals, the reflection suppression function iteration population is divided into Q preferred iteration groups D q , q=1, 2, ..., Q; Q=K*W; the remaining optimized reflection suppression function individuals H in the reflection suppression function iteration population k Uniformly distributed in the optimal iteration group D q In the optimal iteration group D q Randomly generate the best individual in the population; suppose the individual H that optimizes the reflection suppression function k The fitness is the fitness S k ; Set the maximum number of iterations; The maximum number of iterations is written by professional technicians based on actual conditions; The specific value of W is determined based on actual iteration requirements.

[0024] Calculate the fitness S k The specific steps include: Using the optimized reflection suppression function individual H k The reflective controller block images in the controller appearance control training samples are simulated and adjusted to obtain simulated adjusted block images; the similarity between the simulated adjusted block images and the adjusted controller block images is calculated to obtain the simulated adjustment similarity; the average of the simulated adjustment similarities of all controller appearance control training samples is taken as the fitness S k ; Based on the optimal iterative group D q Perform population iteration. In each population iteration, the optimal iteration population D q The individual with the largest internal fitness is taken as the optimal individual in the new population; and the individual random fluctuation factor U is introduced, U=rand(L up -L down )+L down , L up represents the upper bound of the population iteration space, L down represents the lower bound of the population iteration space, rand() represents a random function; the individual random fluctuation factor U is used to select the optimal iteration population D qThe individual mutation operation of the partial optimized reflection suppression function individuals in the optimization iteration group D is realized. q update operation; the introduction of randomness by the individual random fluctuation factor U can prevent the population from converging to the local optimal solution too early. By randomly perturbing individuals, the exploration ability of the understanding space is increased, thereby increasing the possibility of finding the global optimal solution; during the optimization process, the population may fall into stagnation, that is, the differences between individuals become smaller, leading to evolutionary stagnation. Introducing the individual random fluctuation factor U can break this stagnation and promote the continued evolution of the population through random changes; When the maximum number of iterations is reached, the optimized reflection suppression function individual corresponding to the maximum fitness is output, which is the optimal optimized reflection suppression function individual; the reflection suppression function in the optimal optimized reflection suppression function individual is used as the reflection suppression function in the illumination optimization layer; By constructing the reflection suppression function in the lighting optimization layer, the visual consistency of the controller's appearance under different lighting conditions can be significantly improved, ensuring that good display effects can be maintained in various environments; using the basic neural network model for initial function fitting provides a reliable starting point for subsequent optimization and ensures the effectiveness of reflection suppression; by constructing and combining multiple optimized reflection suppression function individuals to form an iterative population, this diversity strategy helps to explore a wider solution space and improve the comprehensiveness and accuracy of optimization; dividing the iterative population into preferred iterative groups and randomly generating the best individuals can accelerate the convergence process and improve the optimization efficiency; the fitness calculation method ensures an accurate evaluation of the reflection suppression effect, making the optimization process more targeted; through population iteration and individual variation operations, the performance of the reflection suppression function can be continuously updated and improved, enhancing its adaptability in practical applications, and the optimal reflection suppression function individuals finally output can effectively reduce reflection interference, improve image quality, and enhance user experience.

[0025] Step S2: Production automated appearance inspection The appearance detection of the controller to be tested is performed according to the block detection image set of the controller to be tested and the controller appearance detection model to obtain the appearance detection result of the controller to be tested; the controller appearance detection model includes a model alignment layer, an image fusion layer, an appearance detection layer and an appearance detection result output layer, which is constructed based on the CNN model and is used to perform appearance detection using the point cloud alignment model.

[0026] The controller appearance detection model includes a model registration layer, an image fusion layer, an appearance detection layer and an appearance detection result output layer; The model registration layer is used to register the block detection image set of the controller to be tested with the standard controller point cloud model to obtain the block point cloud model M of the registered component. i ;The standard controller point cloud model is constructed based on the industrial programmable controller; The image fusion layer is used to divide the registration components into block point cloud models M i The image is fused with the block detection image set of the controller to be tested to obtain the block point cloud model M of the fused registration component i '; The appearance detection layer is used to fusion-register the component block point cloud model M i 'Perform appearance inspection and obtain the appearance inspection result R of the registration component block i ; The appearance detection result output layer is used to block the appearance detection results R of all the registered parts i Perform feature fusion to obtain the appearance detection result of the controller to be tested.

[0027] The specific steps for training the appearance detection layer include: Collecting several groups of training registration component block point cloud models with detection target value annotations; combining several groups of training registration component block point cloud models with detection target value annotations to obtain an appearance detection training set; The appearance detection training set is input into the controller appearance detection model, and the appearance detection layer is trained using the detection target value as the target to obtain an initial appearance detection layer; the initial appearance detection layer is evaluated to obtain an initial appearance detection layer model evaluation result; if the initial appearance detection layer model evaluation result is passed, the initial appearance detection layer is used as the appearance detection layer in the controller appearance detection model; otherwise, the model training is continued using the appearance detection training set; By constructing a controller appearance detection model, the model registration layer is used to accurately align the image of the controller to be tested with the standard point cloud model, thereby achieving efficient and standardized processing of the detection object; the image fusion layer enhances the data integrity and detection accuracy by fusing the registered point cloud model with the detection image; the appearance detection layer performs detection on the fused data, which can effectively identify and locate the appearance defects of the controller, thereby improving the accuracy and reliability of detection; the appearance detection result output layer integrates the detection results of each block into the overall appearance detection result through feature fusion, providing a comprehensive detection analysis; the process of training the appearance detection layer ensures the accuracy and stability of the model, and through the evaluation of the initial model and necessary retraining, it ensures that the performance of the detection model meets the standards, thereby improving the efficiency and effectiveness of appearance detection.

[0028] Step S3: Production automation feature fusion detection Get the controller performance test data set Y of the controller under test, Y={Y n |n=1, 2, ..., N}; where N is the total number of sub-items of the controller performance test to be tested, Y n Indicates the performance index of the controller to be tested Y n; Input the performance test data set Y of the controller to be tested into the controller performance detection model for data analysis to obtain the performance detection result of the controller to be tested; if the appearance detection result and the performance detection result of the controller to be tested are both passed, the controller to be tested completes a production automation detection; otherwise, readjust the controller to be tested.

[0029] The controller performance detection model includes a sub-item data preprocessing layer, a sub-item data feature recognition layer and a sub-item feature result fusion layer; The sub-item data preprocessing layer is used to calculate the sub-item index Y of the controller performance under test in the controller performance test data set Y. n Perform preprocessing to obtain the performance sub-item index Y of the preprocessing controller to be tested n '; The sub-item data feature recognition layer is used to pre-process the sub-item index Y of the controller performance to be tested. n 'Perform feature recognition and obtain the performance sub-item index feature T (Y n ); The sub-item feature result fusion layer is used to combine all performance sub-item indicator features T (Y n ) to perform feature fusion and obtain the performance test results of the controller to be tested.

[0030] The specific steps of training the item data feature recognition layer include: Collecting several groups of performance sub-item feature training samples; each group of performance sub-item feature training samples contains performance sub-item indicator data and performance sub-item indicator characteristic values ​​with test sub-item indicator labels; using the performance sub-item indicator characteristic values ​​as training target values ​​in a group of performance sub-item feature training samples; combining several groups of performance sub-item feature training samples to obtain a performance sub-item feature training set; The performance sub-item feature training set is input into the controller performance detection model to perform model training on the sub-item data feature recognition layer to obtain an initial sub-item data feature recognition layer; the initial sub-item data feature recognition layer is model evaluated to obtain an initial sub-item data feature recognition layer model evaluation result; if the initial sub-item data feature recognition layer model evaluation result is passed, the initial sub-item data feature recognition layer is used as the sub-item data feature recognition layer in the controller performance detection model; otherwise, the performance sub-item feature training set is used to continue model training.

[0031] In production automation feature fusion detection, the performance test data set of the controller to be tested is obtained and analyzed to ensure a comprehensive evaluation and accurate detection of the controller performance; the sub-item data preprocessing layer preprocesses the performance sub-item indicators to improve the quality and consistency of the data, laying the foundation for subsequent analysis; the sub-item data feature recognition layer can effectively extract key performance features by performing feature recognition on the preprocessed data, thereby improving the recognition ability and accuracy of the model; the sub-item feature result fusion layer fuses the features of each performance sub-item to provide a comprehensive performance test result, ensuring the comprehensiveness and reliability of the test; the process of training the sub-item data feature recognition layer ensures the accuracy and robustness of the model by learning and evaluating the performance sub-item feature training samples, thereby improving the efficiency and success rate of production automation detection.

[0032] It should be understood that those skilled in the art can make improvements or changes based on the above description, and all such improvements and changes should fall within the scope of protection of the appended claims of the present invention. Parts not described in detail in this specification belong to the prior art known to those skilled in the art.

Claims

1. An industrial programmable controller production automation detection method, characterized in that: The following steps are involved: Step S1: production automation lighting adjustment; Get the initial controller block image set X of the controller to be tested, X={X i |i=1, 2, …, I}, X i Represents the initial block image X of the controller component to be tested i , I is the total number of controller component blocks to be tested; Input the initial block image set of the controller to be tested into the quality inspection image illumination block layout block model for analysis to obtain the block illumination layout scheme of the controller to be tested; Based on the block illumination layout scheme of the controller to be tested, the controller to be tested is re-photographed in blocks to obtain a block detection image set of the controller to be tested; The quality inspection image illumination block layout block model includes an image preprocessing layer, a block feature analysis layer, a lighting optimization layer, and a solution output layer. It is constructed based on the improved image processing method and is used to preprocess the initial controller block image set X to remove image noise and interference. Step S2: Production automated appearance inspection; The controller to be tested is subjected to appearance inspection based on the block detection image set and the controller appearance inspection model to obtain the appearance inspection result of the controller to be tested. The controller appearance inspection model includes a model registration layer, an image fusion layer, an appearance inspection layer, and an appearance inspection result output layer. It is constructed based on the CNN model and is used to perform appearance inspection using the point cloud registration model. Step S3: production automation feature fusion detection; Get the controller performance test data set Y of the controller under test, Y={Y n |n=1, 2, ..., N}; where N is the total number of sub-items of the controller performance test to be tested, Y n Indicates the performance sub-item index Y of the controller to be tested n ; Input the performance test data set Y of the controller to be tested into the controller performance detection model for data analysis to obtain the performance test results of the controller to be tested; if the appearance test results and the performance test results of the controller to be tested are both passed, the controller to be tested completes a production automation test; Otherwise, readjust the controller under test.

2. The industrial programmable controller production automation detection method according to claim 1, characterized in that: The block layout model of quality inspection image illumination includes image preprocessing layer, block feature analysis layer, illumination optimization layer and solution output layer; The image preprocessing layer is used to process the initial controller component block image X in the initial controller block image set X. i Perform preprocessing to obtain the preprocessed initial controller component block image X i '; The block feature analysis layer is used to pre-process the initial block image X of the controller component to be tested. i 'Perform multi-scale feature extraction to obtain the characteristic region feature Z of the controller component to be tested i ; The illumination optimization layer is used to measure the characteristic area Z of the controller component to be tested i The lighting scheme is optimized using the reflection suppression function to obtain the block lighting layout F of the controller to be tested. i ; The output layer of the scheme is used to loop through the initial controller component block image X in the initial controller block image set X i , get the block lighting layout F of all controllers to be tested i ; Divide all controllers to be tested into block lighting layout F i The blocks of the controller to be tested are combined to obtain a block lighting layout plan, and the block lighting layout plan of the controller to be tested is output.

3. The industrial programmable controller production automation detection method according to claim 2, characterized in that: The specific steps for multi-scale feature extraction in the block feature analysis layer include: Preprocess the initial block image X of the controller component to be tested i 'Extract the region of interest and obtain the image G of the region of interest of the controller component to be tested i ; The specific steps for extracting the region of interest include: Calculate the pre-processed initial block image X of the controller component to be tested i The midline pixel intensity and the two adjacent columns of pixels are bilaterally filtered to obtain the smoothed block image C of the controller component to be tested. i ; Smoothing the block image C of the controller component to be tested i Calculate the maximum continuous pixel gradient in the same direction at the vertical coordinate to obtain the image G of the region of interest of the controller component to be tested i ; The image G of the region of interest of the controller component to be tested is divided into blocks i Perform the first denoising process to obtain the initial denoised image G of the block area of ​​interest of the controller component to be tested i '; The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform adaptive image segmentation and cut feature edges to obtain the block feature segmentation image P of the controller component to be tested i ; The specific steps for adaptive image segmentation and cutting feature edges include: The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Calculate the pixel value distribution and obtain the denoised image histogram E i ; Based on the denoised image histogram E i Search for the minimum value of the area and obtain the image segmentation threshold A i ; Based on image segmentation threshold A i The initial denoised image G of the region of interest of the controller component to be tested is divided into blocks i 'Perform image segmentation to obtain the block feature segmentation image P of the controller component to be tested i ; Segment the image P of the controller component to be tested into blocks with features i Perform the second denoising process to obtain the characteristic region feature Z of the controller component to be tested i .

4. The industrial programmable controller production automation detection method according to claim 3, characterized in that: The specific steps for constructing the reflection suppression function in the lighting optimization layer include: Collecting several sets of controller appearance control training samples; each set of controller appearance control training samples includes a set of reflective controller block images and adjusted controller block images; combining the several sets of controller appearance control training samples to obtain a controller appearance control training set; using a basic neural network model to perform function fitting on the controller appearance control training set to obtain an initial reflection suppression function; Based on the initial reflection suppression function, K optimized reflection suppression function individuals H are constructed. k , k=1, 2, ..., K; K optimized reflection suppression function individuals H k Combination, get the reflection suppression function iteration population; let the individual percentage be W; based on the individual percentage, divide the reflection suppression function iteration population into Q iteration groups D q , q=1, 2, ..., Q; Q=K*W; the reflection suppression function is iterated among the remaining optimized reflection suppression function individuals H in the population k Uniformly distributed in the iteration group D q and in the iteration group D q Randomly generate the best individual in the population; suppose the individual H that optimizes the reflection suppression function k The fitness is the fitness S k ; Set the maximum number of iterations; Calculate fitness S k The specific steps include: Using the optimized reflection suppression function individual H k Perform simulation adjustment on the reflective controller block image in the controller appearance control training sample to obtain the simulated adjustment block image; calculate the similarity between the simulated adjustment block image and the adjusted controller block image to obtain the simulated adjustment similarity; take the average of the simulated adjustment similarities of all controller appearance control training samples as the fitness S k ; Based on iterative group D q Perform population iteration. In each population iteration, the iterative population D q The individual with the largest fitness is regarded as the optimal individual in the new population; and the individual random fluctuation factor U is introduced, U=rand(L up -L down ) + L down , L up represents the upper bound of the population iteration space, L down Represents the lower bound of the population iteration space, rand() represents a random function; the individual random fluctuation factor U is used to iterate the population D q The individual optimization reflection suppression function in the individual mutation operation is performed to achieve the iteration group D q Update operation; When the maximum number of iterations is reached, the optimized reflection suppression function individual corresponding to the maximum fitness is output, which is the optimal optimized reflection suppression function individual; the reflection suppression function in the optimal optimized reflection suppression function individual is used as the reflection suppression function in the illumination optimization layer.

5. The industrial programmable controller production automation detection method according to claim 4, characterized in that: The controller appearance detection model includes a model registration layer, an image fusion layer, an appearance detection layer, and an appearance detection result output layer; The model registration layer is used to perform model registration on the block detection image set of the controller to be tested and the standard controller point cloud model to obtain the registered component block point cloud model M i ; The image fusion layer is used to divide the registration components into block point cloud models M i The image fusion is performed with the block detection image set of the controller to be tested to obtain the fused registration component block point cloud model M i '; The appearance detection layer is used to fusion-register the component block point cloud model M i 'Perform appearance inspection and obtain the appearance inspection result R of the registration component block i ; The appearance detection result output layer is used to divide all the registered parts into blocks and generate the appearance detection results R i Perform feature fusion to obtain the appearance detection results of the controller to be tested.

6. The method for automated production detection of an industrial programmable controller according to claim 5, characterized in that: The specific steps for training the appearance detection layer include: Collecting several sets of training registration component block point cloud models with detection target value annotations; combining several sets of training registration component block point cloud models with detection target value annotations to obtain an appearance detection training set; The appearance detection training set is input into the controller appearance detection model, and the appearance detection layer is trained using the detection target value as the target to obtain an initial appearance detection layer; the initial appearance detection layer is model evaluated to obtain an initial appearance detection layer model evaluation result; if the initial appearance detection layer model evaluation result is passed, the initial appearance detection layer is used as the appearance detection layer in the controller appearance detection model; otherwise, the model training is continued using the appearance detection training set.

7. The industrial programmable controller production automation detection method according to claim 6, characterized in that: The controller performance detection model includes a sub-item data pre-processing layer, a sub-item data feature recognition layer and a sub-item feature result fusion layer; The sub-item data preprocessing layer is used to calculate the sub-item performance index Y of the controller under test in the controller performance test data set Y. n Perform preprocessing to obtain the performance sub-item index Y of the preprocessed controller to be tested n '; The sub-item data feature recognition layer is used to pre-process the sub-item index Y of the controller performance to be tested. n 'Perform feature recognition and obtain the performance sub-item index feature T (Y n ); The fusion layer of the sub-item feature results is used to combine all the performance sub-item indicator features T (Y n ) to perform feature fusion and obtain the performance test results of the controller to be tested.

8. The method for automated production detection of an industrial programmable controller according to claim 7, characterized in that: The specific steps for training the itemized data feature recognition layer include: Collecting several groups of performance sub-item feature training samples; each group of performance sub-item feature training samples contains performance sub-item indicator data and performance sub-item indicator characteristic values ​​with test sub-item indicator labels; using the performance sub-item indicator characteristic values ​​as training target values ​​in a group of performance sub-item feature training samples; combining several groups of performance sub-item feature training samples to obtain a performance sub-item feature training set; The performance sub-item feature training set is input into the controller performance detection model to perform model training on the sub-item data feature recognition layer to obtain an initial sub-item data feature recognition layer; the initial sub-item data feature recognition layer is model evaluated to obtain an initial sub-item data feature recognition layer model evaluation result; if the initial sub-item data feature recognition layer model evaluation result is passed, the initial sub-item data feature recognition layer is used as the sub-item data feature recognition layer in the controller performance detection model; otherwise, the performance sub-item feature training set is used to continue model training.

Citation Information

Patent Citations

  • Rubber glove defect detection method and system based on nondestructive testing technology

    CN116818792A

  • Industrial LED light illumination regulation and control method and system

    CN118591044A

  • System for operating an imaging device, damage analysis and evaluation of structures

    KR102567163B1

  • Machine vision inspection system and method having improved operations for increased precision inspection throughput

    US20040223053A1

  • Method and Apparatus For Monitoring a Production Line

    US20110019877A1