A visual inspection intelligent control method and system for surface defects of luggage accessories
By obtaining preset defect information and preset matching bags, we build a defect detection model, identify defect geometric features and simulate defect scenarios, solving the problem of inaccurate surface defect detection and evaluation of bag accessories in the existing technology, and achieving accurate detection of defects. Assessment and treatment.
Patent Information
- Application Number
- CN202410525298.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-29
- Publication Date
- 2024-10-18
- Estimated Expiration
- 2044-04-29
AI Technical Summary
Existing surface defect detection methods for luggage accessories are difficult to accurately assess the impact of defects on product practicality, aesthetics and durability, resulting in inaccurate assessment and over-processing or omission of processing.
By obtaining preset defect information and preset matching bags, a defect detection model is constructed to identify defect geometric features and simulate defect scenarios. It detects and evaluates defects using convolutional neural networks to generate accurate defect detection results.
It achieves accurate assessment and targeted treatment of surface defects of luggage accessories, improves detection accuracy and processing precision, and avoids excessive or omitted processing.
Smart Images

Figure CN118379267B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to artificial intelligence related fields, and in particular to an intelligent control method and system for visual detection of surface defects of luggage accessories. Background Art
[0002] With the rapid development of industrial production, the production volume of luggage accessories is increasing, and the requirements for product quality are also getting higher and higher. In the production process of luggage accessories, surface defect detection is a key link. Existing surface defect detection methods for luggage accessories mainly focus on the identification and location of defects. However, these methods ignore the impact of defects in the actual use scenarios of luggage. Even if defects are detected, it is difficult to determine whether these defects will have a significant impact on the practicality, aesthetics or durability of the luggage, which leads to inaccurate evaluation of defects and excessive or missed processing.
[0003] In the current relevant technologies, the surface defect detection and control of luggage accessories have technical problems such as inaccurate evaluation and insufficient processing precision. Summary of the invention
[0004] The present application provides an intelligent control method and system for visual inspection of surface defects of luggage accessories, and adopts technical means such as obtaining preset defect information and preset matching luggage, building a defect detection model, and simulating defect scenarios, thereby achieving the technical effect of realizing accurate evaluation and targeted treatment of defects.
[0005] The present application provides an intelligent control method for visual detection of surface defects of luggage accessories, comprising:
[0006] Obtaining preset defect information and preset matching luggage of target luggage accessories;
[0007] Based on the preset defect information, defect geometric features are identified to construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction;
[0008] Constructing a defect detection model according to the convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction;
[0009] Acquire a set of accessory images at multiple positions of the target luggage accessory, and input them into the defect detection model for defect detection control to obtain an original defect detection result, wherein the original defect detection result includes a defect position and size;
[0010] Based on the original defect detection result, a defect scenario simulation of the accessory and the preset matching bag is performed to obtain a bag defect simulation result;
[0011] Based on the bag defect simulation result and the original defect detection result, a comparison is performed with the preset qualified index of the preset matching bag to obtain a target defect detection result;
[0012] The target defect detection result is returned to the production line control end of the target luggage accessories to perform defect warning control on accessories in the same batch.
[0013] In a possible implementation, defect geometric feature recognition is performed based on the preset defect information, a preset detection frame is constructed, and the following processing is performed:
[0014] Mining a historical surface defect detection record set of a target luggage accessory, clustering the historical surface defect detection record set based on defect types, and obtaining a first type of defect detection record set;
[0015] Extracting the first type of defect geometric feature set from the first type of defect detection record set and performing central tendency analysis to obtain the first type of defect geometric feature value;
[0016] Taking the first type of defect geometric feature values as a reference, identifying the optimization direction of the first type of defect geometric feature set to obtain a preset optimization direction;
[0017] The preset detection frame is generated according to the first type of defect geometric feature value, and the preset optimization direction is marked on the preset detection frame.
[0018] In a possible implementation, the first type of defect geometric feature value is used as a reference, the optimization direction of the first type of defect geometric feature set is identified, a preset optimization direction is obtained, and the following processing is performed:
[0019] Taking the first type of defect geometric feature value as a reference feature, performing defect area diffusion identification on other first type of defect geometric features in the first type of defect geometric feature set, and obtaining multiple defect diffusion directions and multiple defect diffusion sizes;
[0020] generating a preset rotation direction based on the plurality of defect diffusion directions, and generating a preset scaling size based on the plurality of defect diffusion sizes;
[0021] The preset optimization direction is obtained according to the preset rotation direction and the preset scaling size.
[0022] In a possible implementation, the following processing is performed:
[0023] The defect detection model includes a defect detection layer and a detection frame optimization layer;
[0024] Constructing the defect detection layer according to the convolutional neural network training, and constructing the detection frame optimization layer based on the preset optimization direction;
[0025] The defect detection layer first performs defect detection according to the preset detection frame and performs defect edge verification;
[0026] The detection frame optimization layer rotates and scales the preset detection frame according to the preset optimization direction based on the defect edge verification result, and inputs the optimized detection frame into the defect detection layer for defect detection again until the defect edge verification result passes.
[0027] In a possible implementation, a set of accessory images of multiple positions of the target luggage accessory is acquired and input into the defect detection model for defect detection control to obtain an original defect detection result, and the following processing is performed:
[0028] Performing defect detection on a first position image in the accessory image set according to the preset detection frame by the defect detection layer in the defect detection model to obtain a first defect detection result;
[0029] Identify the first frame line distance between the defect edge and the preset detection frame based on the first defect detection result, and if the first frame line distance does not meet the preset distance, the defect edge verification result is failed;
[0030] Matching the rotation angle and the scaling factor in the preset optimization direction based on the first frame line spacing by the detection frame optimization layer in the defect detection model;
[0031] Optimizing and controlling the preset detection frame with the rotation angle and the scaling factor to obtain a first optimized detection frame and input it into the defect detection layer;
[0032] Based on the first optimized detection frame, defect detection is performed on the first position image, and defect edge verification is repeatedly performed until the defect edge verification result is passed, and the corresponding defect detection result is obtained as the first original defect detection result of the first position image, and the first original defect detection result is added to the original defect detection result.
[0033] In a possible implementation, based on the original defect detection result, a defect scenario simulation of the accessory and the preset matching bag is performed to obtain a bag defect simulation result, and the following processing is performed:
[0034] Performing three-dimensional scene mapping of the target luggage accessories and the preset matching luggage accessories for accessory assembly to obtain a three-dimensional scene mapping model;
[0035] Rendering the original defect detection result to the three-dimensional scene mapping model;
[0036] Defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the bag defect simulation result.
[0037] In a possible implementation, defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the bag defect simulation result, and the following processing is performed:
[0038] Based on the three-dimensional scene mapping model, defects of the exposed outer surface are identified to obtain an exposed defect identification result;
[0039] Performing difference extraction based on the exposed defect recognition result and the original defect detection result to obtain an attenuated surface defect;
[0040] Determining whether the attenuation surface defect is a functional defect, and marking the functional defect as the attenuation surface defect;
[0041] The marked attenuated surface defects are used as the bag defect simulation results.
[0042] The present application also provides an intelligent control system for visual detection of surface defects of luggage accessories, including:
[0043] A preset information acquisition module, which is used to acquire preset defect information of target luggage accessories and preset matching luggage;
[0044] A defect geometric feature recognition module, the defect geometric feature recognition module is used to perform defect geometric feature recognition based on the preset defect information and construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction;
[0045] A defect detection model construction module, wherein the defect detection model construction module is used to construct a defect detection model according to a convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction;
[0046] An accessory image set acquisition module, the accessory image set acquisition module is used to acquire an accessory image set of multiple positions of the target luggage accessories, and input the defect detection model to perform defect detection control to obtain an original defect detection result, wherein the original defect detection result includes a defect position and size;
[0047] A defect scenario simulation module, the defect scenario simulation module is used to simulate the defect scenario of the accessory and the preset matching bag based on the original defect detection result, and obtain a bag defect simulation result;
[0048] An index comparison module, which is used to compare the luggage defect simulation result and the original defect detection result with the preset qualified index of the preset matching luggage to obtain a target defect detection result;
[0049] A defect warning control module is used to return the target defect detection result to the production line control end of the target luggage accessories to perform defect warning control on accessories in the same batch.
[0050] The present application proposes an intelligent control method and system for visual inspection of surface defects of luggage accessories. First, the preset defect information and preset matching luggage of the target luggage accessories are obtained, and then the defect geometric features are identified based on the preset defect information to construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction, and then a defect detection model is constructed according to the convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction, and then a set of accessory images of multiple positions of the target luggage accessories are acquired and input into the defect detection model for Defect detection control obtains the original defect detection result, which includes the defect position and size. Based on the original defect detection result, the defect scenario simulation of the accessories and the preset matching luggage is performed to obtain the luggage defect simulation result. Then, based on the luggage defect simulation result and the original defect detection result, the preset qualified indicators of the preset matching luggage are compared to obtain the target defect detection result. Finally, the target defect detection result is returned to the production line control end of the target luggage accessory to perform defect early warning control on the accessories in the same batch, thereby achieving the technical effect of realizing accurate defect assessment and targeted treatment. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the technical solution of the embodiment of the present invention, the accompanying drawings of the embodiment of the present invention will be briefly introduced below. A flow chart is used in the present application to illustrate the operations performed by the system according to the embodiment of the present application. It should be understood that the preceding or following operations are not necessarily performed accurately in order. On the contrary, various steps can be processed in reverse order or simultaneously as needed. At the same time, other operations can also be added to these processes, or one or more operations can be removed from these processes.
[0052] Figure 1 A schematic diagram of a flow chart of an intelligent control method for visual inspection of surface defects of luggage accessories provided in an embodiment of the present application;
[0053] Figure 2 A schematic diagram of the structure of an intelligent control system for visual detection of surface defects of luggage accessories provided in an embodiment of the present application.
[0054] Explanation of the accompanying drawings: preset information acquisition module 10, defect geometric feature recognition module 20, defect detection model construction module 30, accessory image set acquisition module 40, defect scene simulation module 50, index comparison module 60, defect warning control module 70. DETAILED DESCRIPTION
[0055] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below.
[0056] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.
[0057] In the following description, reference is made to "some embodiments", which describe a subset of all possible embodiments, but it is understood that "some embodiments" may be the same subset or different subsets of all possible embodiments, and may be combined with each other without conflict, and the terms "first\second" involved are merely to distinguish similar objects and do not represent a specific ordering of objects. The terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product, or server that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or modules that are not clearly listed or inherent to these processes, methods, products, or devices. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those generally understood by technicians in the technical field of this application. The terms used herein are for the purpose of describing the embodiments of the present application only.
[0058] The present application embodiment provides an intelligent control method for visual detection of surface defects of luggage accessories, such as Figure 1 As shown, the method includes:
[0059] Step S100, obtaining preset defect information and preset matching luggage of the target luggage accessories. Specifically, the historical defect records of the target luggage accessories are retrieved from the database to obtain the preset defect information, which is a predefined type of surface defects that may exist in the target luggage accessories, and is used to guide the construction and training of the defect detection model, such as scratches, dents or bulges, rust, breakage or cracking, etc. According to the type and purpose of the target luggage accessories, the corresponding preset matching luggage is selected from the database. The preset matching luggage refers to the type or style of luggage that uses the target luggage accessories, representing the expected application scenario and use environment of the target luggage accessories. The preset matching luggage is used to provide a reference for actual application scenarios for defect detection, and to assist in evaluating the performance of the target luggage accessories on the actual luggage and the possible impact of defects.
[0060] Step S200, based on the preset defect information, the defect geometric features are identified, and a preset detection frame is constructed, wherein the preset detection frame carries a preset optimization direction. Specifically, the preset defect information is parsed, and the geometric features of each defect, such as shape, size, direction, etc., are identified. According to the identified geometric features, a preset detection frame is constructed, and the preset detection frame is a rectangular frame or an irregular shape frame constructed according to the defect geometric features, and is used to locate the defect area in the image and reduce the interference of background pixels. Among them, the preset detection frame carries a preset optimization direction, and the preset optimization direction is an optimization direction preset according to the defect type and geometric features, and is used to guide the defect detection model to fine-tune the preset detection frame during the training process to improve the accuracy and efficiency of defect detection.
[0061] In a possible implementation, defect geometric feature recognition is performed based on the preset defect information, and a preset detection frame is constructed. Step S200 further includes step S210, mining the historical surface defect detection record set of the target luggage accessories, clustering and dividing the historical surface defect detection record set based on the defect type, and obtaining a first-category defect detection record set. Specifically, the historical surface defect detection record set of the target luggage accessories is obtained from a database or file system, and the historical surface defect detection records in the historical surface defect detection record set are preprocessed to extract key information such as defect type, location, size, etc., and the historical surface defect detection record set is clustered according to the defect type using a clustering algorithm (such as K-means, hierarchical clustering, etc.) so that defects in the same class have similar features, and the clustering results are used as the first-category defect detection record set. Step S220, extract the first-category defect geometric feature set in the first-category defect detection record set and perform a central tendency analysis to obtain the first-category defect geometric feature value. Specifically, the geometric features (such as size, shape, direction, etc.) of all defects are extracted from the first type of defect detection record set to form a first type of defect geometric feature set, and the geometric features in the first type of defect geometric feature set are subjected to central tendency analysis, such as calculating the mean, median or mode, to obtain representative first type defect geometric feature values. Step S230, with the first type of defect geometric feature values as a reference, the first type of defect geometric feature set is optimized to identify the direction, and obtain the preset optimization direction. Specifically, according to the first type of defect geometric feature values, the distribution and performance of defects on the target luggage accessories are analyzed, and the optimization direction of the defect detection frame is determined in combination with the actual application scenario and detection requirements, that is, the improvement or adjustment direction proposed for the problems and deficiencies of the current detection frame or detection algorithm, such as expanding the detection range, adjusting the detection angle, etc., and these optimization directions are used as preset optimization directions. Step S240, the preset detection frame is generated according to the first type of defect geometric feature values, and the preset optimization direction is marked to the preset detection frame. Specifically, the size, position and shape of the preset detection frame are determined according to the geometric feature values of the first type of defects, so that the preset detection frame can cover or highlight typical first type defects, and the preset optimization direction is marked on the preset detection frame as metadata or a label. This implementation method uses the geometric feature values of the first type of defects to generate a preset detection frame and identify the optimization direction, which can generate a more accurate preset detection frame and preset optimization direction, thereby achieving the technical effect of improving the accuracy and efficiency of subsequent defect detection.
[0062] In a possible implementation, the first type of defect geometric feature value is used as a reference, and the first type of defect geometric feature set is optimized to identify the direction to obtain a preset optimization direction. Step S230 further includes step S231, using the first type of defect geometric feature value as a reference feature, and identifying the diffusion of defect areas for other first type of defect geometric features in the first type of defect geometric feature set, so as to obtain multiple defect diffusion directions and multiple defect diffusion sizes. Specifically, using the first type of defect geometric feature value as a reference feature, for each other first type of defect geometric feature in the first type of defect geometric feature set, the difference and change trend between it and the reference feature are analyzed, including determining the diffusion direction (such as up and down, left and right, oblique, etc.) and diffusion size (i.e., the degree of increase of the defect area) of the defect on the target luggage accessories, wherein the defect diffusion direction refers to the main direction in which the defect diffuses from the initial position to the surrounding area; the defect diffusion size refers to the size or range of the defect area increased in the diffusion direction. The diffusion direction and diffusion size of each defect are recorded to form a set of multiple defect diffusion directions and multiple defect diffusion sizes. Step S232, generating a preset rotation direction based on the multiple defect diffusion directions, and generating a preset scaling size based on the multiple defect diffusion sizes. Specifically, based on the multiple defect diffusion directions, determine one or more main diffusion directions, and based on the determined main diffusion directions, generate a preset rotation direction, the preset rotation direction is used to adjust the direction of the preset detection frame to better cover the defect area. Analyze multiple defect diffusion sizes, calculate their average value, maximum value or specific values selected according to a certain strategy, and these values are used to generate a preset scaling size, the preset scaling size is used to adjust the size of the preset detection frame so that the preset detection frame can cover the largest possible defect area. Step S233, obtain the preset optimization direction with the preset rotation direction and the preset scaling size. Specifically, the preset rotation direction and the preset scaling size are integrated into an optimization direction description, such as a combination of a rotation angle and a scaling ratio, and the integrated optimization direction is output as the preset optimization direction for the construction and optimization of the preset detection frame. This implementation method determines the changing trend of defects by identifying the diffusion of defect areas, provides clear guidance for the optimization of preset detection frames, and enables the preset optimization directions to better adapt to the diffusion characteristics of different defects, thereby achieving the technical effect of improving the accuracy of the generation of preset optimization directions.
[0063] Step S300, constructing a defect detection model according to the convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction. Specifically, the convolutional neural network structure is determined according to the complexity of the defect detection task, such as VGG, ResNet, MobileNet, etc., and the weights and biases of the convolutional neural network are initialized using a random initialization or pre-trained model. According to the position, size, shape and other parameters of the preset detection frame, corresponding variables or data structures are defined, and the parameters of the preset detection frame are integrated into a specific layer or module of the convolutional neural network, so that the network can use these parameters for defect detection during forward propagation, including extracting the rotation angle and scaling ratio from the preset optimization direction, rotating the preset detection frame according to the extracted rotation angle, so that the direction of the preset detection frame is consistent with the defect diffusion direction; scaling the preset detection frame according to the extracted scaling ratio, and adjusting the size of the preset detection frame to cover a larger range of defect areas. Collect target luggage accessories images with defect annotations as training data, determine the loss function (such as cross entropy loss, mean square error, etc.) and optimizer (such as SGD, Adam, etc.), use the training data to iteratively train the convolutional neural network, and update the network parameters through the back propagation algorithm. After the training is completed, a defect detection model is obtained that can rotate and scale the preset detection box according to the preset optimization direction.
[0064] In a possible implementation, step S300 further includes step S310, and the defect detection model includes a defect detection layer and a detection frame optimization layer. Specifically, the defect detection layer is used to locate the defect area in the image according to the preset detection frame and extract the defect features; the detection frame optimization layer is used to rotate and scale the preset detection frame based on the preset optimization direction to optimize the position and size of the preset detection frame. Step S320, construct the defect detection layer according to convolutional neural network training, and construct the detection frame optimization layer based on the preset optimization direction. Specifically, a convolutional neural network is used for training to learn how to extract effective defect features from the preset detection frame. According to the preset optimization direction, a corresponding network structure or algorithm is designed to realize the rotation and scaling control of the preset detection frame. Step S330, the defect detection layer first performs defect detection according to the preset detection frame, and performs defect edge verification. Specifically, the defect detection layer is used to perform defect detection on the image in the preset detection frame, extract defect features, check the distance between the detected defect edge and the preset detection frame, and determine whether the preset detection frame is appropriate. If the preset detection frame fits the actual boundary of the defect, it indicates that the preset detection frame is appropriate. Step S340, the detection frame optimization layer rotates and scales the preset detection frame according to the preset optimization direction based on the defect edge verification result, and inputs the optimized detection frame into the defect detection layer for defect detection again until the defect edge verification result passes. Specifically, if the preset detection frame is not appropriate, based on the defect edge verification result, the detection frame optimization layer is used to rotate and scale the preset detection frame according to the preset optimization direction to optimize the position and size of the preset detection frame, and the optimized preset detection frame is re-input into the defect detection layer for defect detection, and the defect edge verification is performed again. If the verification result passes, the iteration ends; otherwise, the preset detection frame continues to be optimized and the detection is iterated. This implementation method uses an iterative detection method to continuously optimize the position and size of the preset detection frame according to the defect edge verification results, gradually improves the detection effect of the defect detection model, and achieves the technical effect of making the detection results of the defect detection model more accurate and reliable.
[0065] Step S400, acquire a set of accessory images of multiple positions of the target luggage accessories, and input the defect detection model to perform defect detection control, and obtain an original defect detection result, wherein the original defect detection result includes the defect position and size. Specifically, use a camera or image acquisition device to capture images of multiple positions of the target luggage accessories from different angles and distances, and by moving the acquisition device or adjusting the position of the target luggage accessories, the acquired images can cover the possible defect areas, and the acquired images of the target luggage accessories at multiple positions are sorted, and duplicate or poor quality images are removed, and the sorted images are combined into a set, namely, the accessory image set, and the accessory image set contains the image data of multiple positions of the target luggage accessories. The acquired accessory image set is input into the defect detection model for defect detection control. The defect detection model runs on the input image, locates and extracts features of the defect area according to the preset detection frame, rotates and scales the preset detection frame based on the preset optimization direction, optimizes the position and size of the preset detection frame, identifies defects according to the optimized preset detection frame, and determines the position and size of the defects in the image. The position and size information of the defects are extracted from the defect detection model and sorted to form the original defect detection result.
[0066] In a possible implementation, a set of accessory images of multiple positions of the target luggage accessories is collected and obtained, and the defect detection model is input for defect detection control to obtain an original defect detection result. Step S400 further includes step S410, in which the defect detection layer in the defect detection model performs defect detection on the first position image in the accessory image set according to the preset detection frame to obtain a first defect detection result. Specifically, an image is selected from the accessory image set as the image of the first position. In the defect detection model, the preset detection frame is used to perform initial defect detection on the selected first position image. According to the image information in the preset detection frame, the defect detection layer outputs a preliminary defect detection result (first defect detection result). Step S420, based on the first defect detection result, the first frame line spacing between the defect edge and the preset detection frame is identified. If the first frame line spacing does not meet the preset spacing, the defect edge verification result is not passed. Among them, the preset spacing is set according to actual application requirements and is used to determine whether the preset detection frame is appropriate. The spacing threshold. Specifically, the preliminary defect detection result obtained in step S410 is analyzed, the distance between the defect edge and the boundary line of the preset detection frame (the first frame line distance) is measured, and the calculated first frame line distance is compared with the preset distance threshold. If it is not satisfied (that is, the first frame line distance is too large or too small), the defect edge verification result is determined to be unsuccessful. Step S430, the detection frame optimization layer in the defect detection model matches the rotation angle and scaling factor in the preset optimization direction based on the first frame line distance. Specifically, according to the spacing information obtained in step S420, analyze how the preset detection frame needs to be adjusted, and match the appropriate rotation angle and scaling factor in the detection frame optimization layer of the defect detection model according to the preset optimization direction (such as expanding the preset detection frame, reducing the preset detection frame, rotating clockwise, rotating counterclockwise, etc.). Step S440, optimize the preset detection frame with the rotation angle and the scaling factor, obtain the first optimized detection frame and input it into the defect detection layer. Specifically, according to the rotation angle and scaling coefficient obtained in step S430, the preset detection frame is rotated and scaled accordingly, and the preset detection frame after optimization control is the first optimized detection frame, and the first optimized detection frame is re-input into the defect detection layer to prepare for the next defect detection. Step S450, based on the first optimized detection frame, the first position image is subjected to defect detection, and the defect edge check is repeated until the defect edge check result is passed, and the corresponding defect detection result is obtained as the first original defect detection result of the first position image, and the first original defect detection result is added to the original defect detection result.Specifically, in the defect detection layer, the first optimized detection frame is used to perform defect detection on the first position image, and the distance between the defect edge and the first optimized detection frame is measured and judged again. If the defect edge verification result is passed, the defect detection result at this time is obtained as the first original defect detection result of the first position image, and the first original defect detection result is added to the final original defect detection result set. If the defect edge verification result is not passed, steps S430 to S450 are repeated until the defect edge verification result passes. This implementation method can gradually adjust the position and size of the detection frame by repeating defect edge verification and defect detection based on the optimized detection frame until the defect edge verification requirements are met, thereby ensuring that the image at each position can obtain accurate defect detection results, and achieving the technical effect of improving the reliability and stability of the entire defect detection process.
[0067] Step S500, based on the original defect detection result, a defect scene simulation of the accessory and the preset matching luggage is performed to obtain a luggage defect simulation result. The defect scene simulation is to simulate the actual presentation effect of the defect on the preset matching luggage based on the original defect detection result, so as to intuitively evaluate the impact of the defect. Specifically, the original defect detection result is mapped to the corresponding position of the preset matching luggage, and the image processing technology is used to simulate the actual display effect of the defect on the preset matching luggage to generate a defect scene simulation image.
[0068] In a possible implementation, step S500 further includes step S510, performing three-dimensional scene mapping of the target luggage accessories and the preset matching luggage for accessory assembly to obtain a three-dimensional scene mapping model. Specifically, the three-dimensional model data of the target luggage accessories and the preset matching luggage are extracted from the database, and the extracted three-dimensional data is converted into an editable three-dimensional model using three-dimensional modeling software or algorithm. In the three-dimensional modeling environment, the three-dimensional model of the target luggage accessories is mapped to the three-dimensional model of the preset matching luggage according to the actual assembly method, so that the position, angle and size of the target luggage accessories are consistent with the actual assembly situation. After completing the accessory assembly mapping, a three-dimensional scene mapping model is generated, and the three-dimensional scene mapping model includes a complete three-dimensional scene after the target luggage accessories are assembled with the preset matching luggage. Step S520, the original defect detection result is rendered to the three-dimensional scene mapping model. Specifically, the defect information of the target luggage accessories is extracted from the original defect detection results, including the location, size, shape, etc. of the defects. According to the defect information, the rendering parameters of the defects in the three-dimensional scene mapping model, such as color, transparency, texture, etc., are set. The defect information is rendered to the corresponding position of the three-dimensional scene mapping model using three-dimensional rendering technology to visualize the defects in the three-dimensional model. Step S530, defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the luggage defect simulation result. Specifically, in the three-dimensional scene mapping model, the rendered defects are detected to determine whether they are obscured due to the assembly of luggage accessories or the structure of the preset matching luggage itself. For example, if the defect is located on the inside of the preset matching luggage, or is covered by other accessories, it may not be observed in actual use. For the obscured defects, further analysis is performed to determine whether they have an impact on the performance of the preset matching luggage, that is, a functional evaluation is performed on the target luggage accessories. For example, if the defects are located in key parts such as buckles or zippers, even if they are obscured, they may affect the opening and closing functions of the preset matching luggage, thereby causing inconvenience in use. The detected obstructions and the impact of the obstructions on the performance of the preset matching luggage are recorded, and the luggage defects are quantitatively or qualitatively evaluated according to the preset evaluation criteria. Based on the above analysis, a luggage defect simulation report or data is generated, listing which defects are obscured and whether these obscured defects have an actual impact on the use of the preset matching luggage. This implementation method more accurately simulates and evaluates the impact of defects in the actual use of the preset matching luggage by performing defect attenuation identification, achieving the technical effect of providing strong data support and decision-making basis for subsequent repairs, replacements or design improvements.
[0069] In a possible implementation, step S530 further includes step S531, performing defect recognition on the exposed outer surface based on the three-dimensional scene mapping model to obtain an exposed defect recognition result. Specifically, in the three-dimensional scene mapping model, the exposed outer surface of the preset matching luggage is identified and extracted. The exposed outer surface is the part that the user can directly touch and observe when using the preset matching luggage, and is not blocked by other accessories or structures. Defect recognition is performed on the extracted exposed outer surface, and defects such as blemishes, scratches, and dents on the exposed outer surface are detected using image processing or pattern recognition technology, and information such as their position, size, and shape are recorded, and the identified exposed outer surface defects are organized into exposed defect recognition results, including information such as the type, location, and quantity of the defects. Step S532, performing difference extraction based on the exposed defect recognition result and the original defect detection result to obtain an attenuated surface defect. Specifically, the exposed defect recognition result is aligned with the original defect detection result so that they are in the same coordinate system, and the exposed defect recognition result and the original defect detection result are compared to find out the defects that are no longer exposed due to the structure or accessories after being assembled into the preset matching luggage. These defects exist in the original defect detection, but are not detected in the exposed outer surface recognition of the three-dimensional scene mapping model, so they are considered to be attenuated surface defects. The extracted attenuated surface defects are recorded, including their original position, size, and state after assembly. Step S533, determine whether the attenuated surface defect is a functional defect, and identify the functional defect judgment to the attenuated surface defect. Specifically, a functional analysis is performed on each attenuated surface defect to determine whether it affects the performance of the preset matching luggage, whether it will limit or invalidate the function of the preset matching luggage, including analyzing the location, type, and whether it involves key structures or functional components of the defect. For the attenuated surface defects that affect the performance of the preset matching luggage, they are identified as functional defects, and relevant information is recorded. Step S534, the identified attenuated surface defects are used as the luggage defect simulation results. Specifically, the marked attenuated surface defects are sorted, including their location, type, size, and whether they are functional defects, and the sorted attenuated surface defects are output as the bag defect simulation results. This implementation method provides more comprehensive and accurate bag defect simulation results by comprehensively analyzing the actual usage status of the preset matching bags, the visibility of the defects, and the functional impact, achieving the technical effect of improving the accuracy and completeness of the bag defect simulation.
[0070] Step S600, based on the luggage defect simulation result and the original defect detection result, compare with the preset qualified index of the preset matching luggage to obtain the target defect detection result. Specifically, the preset qualified index of the preset matching luggage is extracted. The preset qualified index is a preset quality standard for different types of luggage, which is used to evaluate whether the defects of luggage accessories are acceptable, such as the allowed defect type, quantity, size, etc. The luggage defect simulation result is compared with the preset qualified index, and each defect in the luggage defect simulation result is analyzed to see whether it exceeds the limit of the preset index, including checking the type, size, quantity of the defect and their impact on the performance of the luggage. At the same time, the original defect detection result is compared with the preset qualified index to confirm whether the defects of the accessories before assembly meet the quality requirements. The comparison results are integrated together to form a comprehensive target defect detection result, which is a conclusive result reflecting the overall quality status of the target luggage accessories.
[0071] Step S700, returning the target defect detection result to the production line control end of the target luggage accessories, and performing defect warning control of the same batch of accessories. Specifically, the target defect detection result is sent to the production line control end of the target luggage accessories through network connection, data interface, etc. The production line control end is a system or device for monitoring and managing the operation of the target luggage accessories production line, which can receive and process various production data and instructions. The production line control end performs defect warning analysis based on the received target defect detection result, including determining the type, quantity, severity and possible impact of the defect, identifying other accessories belonging to the same batch as the target luggage accessories through production records, batch identification and other information, and performing defect warning control on the same batch of accessories according to the defect warning analysis results, including suspending production, strengthening quality inspection, adjusting production process parameters, and conducting quality traceability and other measures to prevent the further expansion or spread of defects. The embodiment of the present application adopts technical means such as obtaining preset defect information and preset matching luggage, building a defect detection model, and performing defect scene simulation, so as to achieve the technical effect of realizing accurate evaluation and targeted treatment of defects.
[0072] In the above, refer to Figure 1 The present invention describes in detail a method for visually detecting surface defects of luggage accessories according to an embodiment of the present invention. Figure 2 An intelligent control system for visual detection of surface defects of luggage accessories according to an embodiment of the present invention is described.
[0073] According to an embodiment of the present invention, a visual inspection intelligent control system for surface defects of luggage accessories is used to solve the technical problems of inaccurate evaluation and insufficient processing precision in the existing detection and control of surface defects of luggage accessories, so as to achieve the technical effect of accurate evaluation and targeted processing of defects. A visual inspection intelligent control system for surface defects of luggage accessories includes: a preset information acquisition module 10, a defect geometric feature recognition module 20, a defect detection model construction module 30, an accessory image collection acquisition module 40, a defect scene simulation module 50, an index comparison module 60, and a defect warning control module 70.
[0074] The preset information acquisition module 10 is used to acquire preset defect information of the target luggage accessories and preset matching luggage;
[0075] The defect geometric feature recognition module 20 is used to perform defect geometric feature recognition based on the preset defect information and construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction;
[0076] The defect detection model building module 30 is used to build a defect detection model according to the convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction;
[0077] The accessory image set acquisition module 40 is used to acquire the accessory image set of multiple positions of the target luggage accessories, and input the defect detection model to perform defect detection control to obtain the original defect detection result, wherein the original defect detection result includes the defect position and size;
[0078] The defect scenario simulation module 50 is used to simulate the defect scenario of the accessory and the preset matching bag based on the original defect detection result to obtain the bag defect simulation result;
[0079] The index comparison module 60 is used to compare the luggage defect simulation result and the original defect detection result with the preset qualified index of the preset matching luggage to obtain the target defect detection result;
[0080] The defect warning control module 70 is used to return the target defect detection result to the production line control end of the target luggage accessories to perform defect warning control on accessories in the same batch.
[0081] The specific configuration of the defect geometric feature recognition module 20 will be described in detail below. As described above, defect geometric feature recognition is performed based on the preset defect information to construct a preset detection frame. The defect geometric feature recognition module 20 may further include: a first-category defect detection record set acquisition unit is used to mine the historical surface defect detection record set of the target luggage accessories, cluster the historical surface defect detection record set based on the defect type, and obtain the first-category defect detection record set; a first-category defect geometric feature value acquisition unit is used to extract the first-category defect geometric feature set in the first-category defect detection record set and perform a central trend analysis to obtain the first-category defect geometric feature value; an optimization direction recognition unit is used to identify the optimization direction of the first-category defect geometric feature set with reference to the first-category defect geometric feature value to obtain a preset optimization direction; a preset detection frame generation unit is used to generate the preset detection frame according to the first-category defect geometric feature value, and mark the preset optimization direction to the preset detection frame.
[0082] Among them, taking the first type of defect geometric feature value as a reference, the optimization direction of the first type of defect geometric feature set is identified to obtain a preset optimization direction, and the optimization direction identification unit may further include: a defect area diffusion identification subunit is used to take the first type of defect geometric feature value as a reference feature, and perform defect area diffusion identification on other first type of defect geometric features in the first type of defect geometric feature set to obtain multiple defect diffusion directions and multiple defect diffusion sizes; a preset direction size generation subunit is used to generate a preset rotation direction based on the multiple defect diffusion directions, and generate a preset scaling size based on the multiple defect diffusion sizes; a preset optimization direction acquisition subunit is used to obtain the preset optimization direction with the preset rotation direction and the preset scaling size.
[0083] The specific configuration of the defect detection model construction module 30 will be described in detail below. As described above, the defect detection model construction module 30 may further include: a defect detection model construction unit for the defect detection model including a defect detection layer and a detection frame optimization layer; a network layer construction unit for constructing the defect detection layer according to the convolutional neural network training, and constructing the detection frame optimization layer based on the preset optimization direction; a detection and verification unit for the defect detection layer to first perform defect detection according to the preset detection frame, and perform defect edge verification; an optimization unit for the detection frame optimization layer to rotate and scale the preset detection frame according to the preset optimization direction based on the defect edge verification result, and input the optimized detection frame into the defect detection layer for defect detection again, until the defect edge verification result passes.
[0084] The specific configuration of the accessory image set acquisition module 40 will be described in detail below. As described above, the accessory image set of multiple positions of the target luggage accessories is acquired and input into the defect detection model for defect detection control to obtain the original defect detection result. The accessory image set acquisition module 40 may further include: a defect detection unit for performing defect detection on the first position image in the accessory image set according to the preset detection frame through the defect detection layer in the defect detection model to obtain a first defect detection result; a result recognition unit for identifying the first frame line spacing between the defect edge and the preset detection frame based on the first defect detection result. If the first frame line spacing does not meet the preset spacing, the defect edge verification result is failed; a matching unit for passing The detection frame optimization layer in the defect detection model matches the rotation angle and the scaling factor in the preset optimization direction based on the first frame line spacing; the optimization control unit is used to optimize the preset detection frame with the rotation angle and the scaling factor, obtain a first optimized detection frame and input it into the defect detection layer; the first original defect detection result acquisition unit is used to perform defect detection on the first position image based on the first optimized detection frame, repeatedly perform defect edge verification until the defect edge verification result is passed, obtain the corresponding defect detection result as the first original defect detection result of the first position image, and add the first original defect detection result to the original defect detection result.
[0085] The specific configuration of the defect scene simulation module 50 will be described in detail below. As described above, based on the original defect detection result, the defect scene simulation of the accessories and the preset matching luggage is performed to obtain the luggage defect simulation result. The defect scene simulation module 50 may further include: a three-dimensional scene mapping unit for performing three-dimensional scene mapping of the assembly of the target luggage accessories and the preset matching luggage to obtain a three-dimensional scene mapping model; a rendering unit for rendering the original defect detection result to the three-dimensional scene mapping model; and a defect attenuation recognition unit for performing defect attenuation recognition based on the three-dimensional scene mapping model to obtain the luggage defect simulation result.
[0086] Among them, defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the luggage defect simulation result, and the defect attenuation identification unit may further include: an exposed outer surface defect identification subunit is used to perform exposed outer surface defect identification based on the three-dimensional scene mapping model to obtain an exposed defect identification result; a difference set extraction subunit is used to perform difference set extraction based on the exposed defect identification result and the original defect detection result to obtain an attenuated surface defect; an identification subunit is used to determine whether the attenuated surface defect is a functional defect, and identify the functional defect judgment to the attenuation surface defect; a luggage defect simulation result generation subunit is used to use the identified attenuated surface defect as the luggage defect simulation result.
[0087] An intelligent control system for visual detection of surface defects of luggage accessories provided in an embodiment of the present invention can execute an intelligent control method for visual detection of surface defects of luggage accessories provided in any embodiment of the present invention, and has functional modules and beneficial effects corresponding to the execution method.
[0088] Although the present application makes various references to certain modules in the system according to the embodiments of the present application, any number of different modules may be used and run on the user terminal and / or server, and the various units and modules included are only divided according to functional logic, but are not limited to the above division, as long as the corresponding functions can be achieved; in addition, the specific names of the functional units are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention.
[0089] The above specific implementation manner does not constitute a limitation to the protection scope of the present application. It should be understood by those skilled in the art that various modifications, combinations and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present application should be included in the protection scope of the present application. In some cases, the actions or steps recorded in the present application can be performed in an order different from that in the embodiment and can still achieve the desired results. In addition, the process depicted in the accompanying drawings does not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
Claims
1. An intelligent control method for visual inspection of surface defects of luggage accessories, characterized in that: The method comprises: Obtaining preset defect information and preset matching luggage of target luggage accessories; Based on the preset defect information, defect geometric features are identified to construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction; Constructing a defect detection model according to the convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction; Acquire a set of accessory images at multiple positions of the target luggage accessory, and input them into the defect detection model for defect detection control to obtain an original defect detection result, wherein the original defect detection result includes a defect position and size; Based on the original defect detection result, a defect scenario simulation of the accessory and the preset matching bag is performed to obtain a bag defect simulation result; Based on the bag defect simulation result and the original defect detection result, a comparison is performed with the preset qualified index of the preset matching bag to obtain a target defect detection result; The target defect detection result is returned to the production line control end of the target luggage accessories to perform defect warning control on accessories in the same batch; The defect detection model includes a defect detection layer and a detection frame optimization layer; Constructing the defect detection layer according to the convolutional neural network training, and constructing the detection frame optimization layer based on the preset optimization direction; The defect detection layer first performs defect detection according to the preset detection frame and performs defect edge verification; The detection frame optimization layer rotates and scales the preset detection frame according to the preset optimization direction based on the defect edge verification result, and inputs the optimized detection frame into the defect detection layer for defect detection again until the defect edge verification result passes.
2. The method for visual inspection of surface defects of luggage accessories according to claim 1, characterized in that: Based on the preset defect information, defect geometric feature recognition is performed to construct a preset detection frame, including: Mining a historical surface defect detection record set of a target luggage accessory, clustering the historical surface defect detection record set based on defect types, and obtaining a first type of defect detection record set; Extracting the first type of defect geometric feature set from the first type of defect detection record set and performing central tendency analysis to obtain the first type of defect geometric feature value; Taking the first type of defect geometric feature values as a reference, identifying the optimization direction of the first type of defect geometric feature set to obtain a preset optimization direction; The preset detection frame is generated according to the first type of defect geometric feature value, and the preset optimization direction is marked on the preset detection frame.
3. The method for visual inspection of surface defects of luggage accessories according to claim 2, characterized in that: Taking the first type of defect geometric feature value as a reference, the optimization direction of the first type of defect geometric feature set is identified to obtain a preset optimization direction, including: Taking the first type of defect geometric feature value as a reference feature, performing defect area diffusion identification on other first type of defect geometric features in the first type of defect geometric feature set, and obtaining multiple defect diffusion directions and multiple defect diffusion sizes; generating a preset rotation direction based on the plurality of defect diffusion directions, and generating a preset scaling size based on the plurality of defect diffusion sizes; The preset optimization direction is obtained according to the preset rotation direction and the preset scaling size.
4. The method for visual inspection of surface defects of luggage accessories according to claim 1, characterized in that: A set of accessory images at multiple positions of the target luggage accessory is acquired and input into the defect detection model for defect detection control to obtain an original defect detection result, including: Performing defect detection on a first position image in the accessory image set according to the preset detection frame by the defect detection layer in the defect detection model to obtain a first defect detection result; Identify the first frame line distance between the defect edge and the preset detection frame based on the first defect detection result, and if the first frame line distance does not meet the preset distance, the defect edge verification result is failed; Matching the rotation angle and the scaling factor in the preset optimization direction based on the first frame line spacing by the detection frame optimization layer in the defect detection model; Optimizing and controlling the preset detection frame with the rotation angle and the scaling factor to obtain a first optimized detection frame and input it into the defect detection layer; Based on the first optimized detection frame, defect detection is performed on the first position image, and defect edge verification is repeatedly performed until the defect edge verification result is passed, and the corresponding defect detection result is obtained as the first original defect detection result of the first position image, and the first original defect detection result is added to the original defect detection result.
5. The method for visual inspection of surface defects of luggage accessories according to claim 1, characterized in that: Based on the original defect detection result, a defect scenario simulation of the accessory and the preset matching bag is performed to obtain a bag defect simulation result, including: Performing three-dimensional scene mapping of the target luggage accessories and the preset matching luggage accessories for accessory assembly to obtain a three-dimensional scene mapping model; Rendering the original defect detection result to the three-dimensional scene mapping model; Defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the bag defect simulation result.
6. The method for visual inspection of surface defects of luggage accessories according to claim 5, characterized in that: Defect attenuation identification is performed based on the three-dimensional scene mapping model to obtain the bag defect simulation result, including: Based on the three-dimensional scene mapping model, defects of the exposed outer surface are identified to obtain an exposed defect identification result; Performing difference extraction based on the exposed defect recognition result and the original defect detection result to obtain an attenuated surface defect; Determining whether the attenuation surface defect is a functional defect, and marking the functional defect as the attenuation surface defect; The marked attenuated surface defects are used as the bag defect simulation results.
7. An intelligent control system for visual inspection of surface defects of luggage accessories, characterized in that: The system is used to implement the intelligent control method for visual detection of surface defects of luggage accessories according to any one of claims 1 to 6, and the system comprises: A preset information acquisition module, which is used to acquire preset defect information of target luggage accessories and preset matching luggage; A defect geometric feature recognition module, the defect geometric feature recognition module is used to perform defect geometric feature recognition based on the preset defect information and construct a preset detection frame, wherein the preset detection frame carries a preset optimization direction; A defect detection model construction module, wherein the defect detection model construction module is used to construct a defect detection model according to a convolutional neural network and the preset detection frame, wherein the defect detection model rotates and scales the preset detection frame according to the preset optimization direction; An accessory image set acquisition module, the accessory image set acquisition module is used to acquire an accessory image set of multiple positions of the target luggage accessories, and input the defect detection model to perform defect detection control to obtain an original defect detection result, wherein the original defect detection result includes a defect position and size; A defect scenario simulation module, the defect scenario simulation module is used to simulate the defect scenario of the accessory and the preset matching bag based on the original defect detection result, and obtain a bag defect simulation result; An index comparison module, which is used to compare the luggage defect simulation result and the original defect detection result with the preset qualified index of the preset matching luggage to obtain a target defect detection result; A defect warning control module is used to return the target defect detection result to the production line control end of the target luggage accessories to perform defect warning control on accessories in the same batch.
Citation Information
Patent Citations
Device for recognizing defects in finished surface of product
US20220373474A1
Rotating target and improved attention mechanism-based thin film scratch defect detection method
WO2022252348A1
