A machine vision-based method for detecting spare parts
By using machine vision technology and combining laser scanning equipment with CCD cameras, the problem of low accuracy in parts inspection has been solved, enabling rational and precise control of parts and improving inspection efficiency.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- SHENZHEN FUTURE PARTS TECH CO LTD
- Filing Date
- 2023-08-10
- Publication Date
- 2026-05-29
AI Technical Summary
The current technology for testing spare parts is not rigorous enough, resulting in low testing accuracy and an inability to achieve reasonable and precise control.
By using a machine vision-based approach, point cloud data of sub-regions of parts is acquired using laser scanning equipment, and then image acquisition and median filtering are performed using a CCD camera to achieve the inspection of the size and appearance quality of the parts.
This has enabled rational and precise control over the inspection of spare parts, improving the accuracy and efficiency of inspection.
Smart Images

Figure CN117030615B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of machine vision technology, and more specifically to a machine vision-based method for inspecting spare parts. Background Technology
[0002] With the continuous progress and development of science and technology, computers are increasingly widely used in scientific and technological research and development, production, and daily life, achieving leaps and bounds in application. In modern industrial production, the research on intelligent inspection systems for industrial products has become an important direction for modern production. The application of computer vision inspection systems can replace manual labor in product production and inspection, which is of great significance for minimizing inspection omissions, improving the accuracy of production inspection, and enhancing inspection efficiency.
[0003] The existing technology for component inspection suffers from low accuracy due to insufficient rigor, which makes it impossible to achieve reasonable and precise control over component inspection. Summary of the Invention
[0004] This application provides a machine vision-based method for inspecting spare parts, which solves the problem of low inspection accuracy caused by insufficient rigor in the existing spare parts inspection work, and realizes rational and precise control over the spare parts inspection work.
[0005] In view of the above problems, this application provides a machine vision-based method for the inspection of spare parts.
[0006] Firstly, a first component is obtained, wherein the first component has a component structural feature identifier and a component design feature identifier; N component sub-regions are determined, wherein the N component sub-regions are obtained by dividing the first component into regions based on the component structural feature identifier; the N component sub-regions are scanned using a laser scanning device to obtain point cloud data of the N sub-regions; a size verification result of the first component is obtained, wherein the size verification result of the first component is obtained by verifying the size of the first component using the component design feature identifier and the point cloud data of the N sub-regions; when the size verification result of the first component is passed, a first appearance quality inspection command is obtained; the first appearance quality inspection command activates a CCD camera to perform image acquisition of the N component sub-regions, and median filtering is applied to the image acquisition results to obtain images of the N sub-regions; the appearance quality of the first component is inspected using the component design feature identifier and the images of the N sub-regions to obtain a first appearance quality inspection report.
[0007] Secondly, this application provides a machine vision-based spare parts inspection system, comprising: a spare parts acquisition module for acquiring a first spare part, wherein the first spare part has a spare part structural feature identifier and a spare part design feature identifier; a region division module for determining N spare part sub-regions, wherein the N spare part sub-regions are acquired by dividing the first spare part into regions using the spare part structural feature identifier; a point cloud data module for scanning the N spare part sub-regions using a laser scanning device to obtain N sub-region point cloud data; a size verification module for obtaining the size verification result of the first spare part, wherein the size verification result of the first spare part is obtained by verifying the size of the first spare part using the spare part design feature identifier and the N sub-region point cloud data; an inspection instruction module for obtaining a first appearance quality inspection instruction when the size verification result of the first spare part is passed; an image acquisition module for activating a CCD camera to acquire images of the N spare part sub-regions using the first appearance quality inspection instruction, and performing median filtering on the image acquisition results to obtain N sub-region images; and a quality inspection module for performing appearance quality inspection of the first spare part using the spare part design feature identifier and the N sub-region images to obtain a first appearance quality inspection report.
[0008] One or more technical solutions provided in this application have at least the following technical effects or advantages:
[0009] This application provides a machine vision-based component inspection method. It obtains a first component with component structural feature identifiers and component design feature identifiers. The method then divides the first component into N sub-regions based on the component structural feature identifiers. A laser scanning device scans these N sub-regions to obtain point cloud data. The first component's dimensions are verified using the component design feature identifiers and the N sub-region point cloud data. When the dimension verification result is satisfactory, a first appearance quality inspection command is obtained. This command activates a CCD camera to perform image acquisition and median filtering of the N sub-regions, obtaining N sub-region images. The appearance quality of the first component is then inspected using the component design feature identifiers and the N sub-region images, resulting in a first appearance quality inspection report. This method solves the problem of low accuracy in component inspection due to insufficient rigor in existing technologies, achieving rational and precise control over component inspection. Attached Figure Description
[0010] Figure 1 This application provides a schematic flowchart of a machine vision-based component inspection method;
[0011] Figure 2 This application provides a schematic diagram of a machine vision-based parts inspection system.
[0012] Explanation of reference numerals in the attached diagram: a) Accessory acquisition module, b) Area division module, c) Point cloud data module, d) Size verification module, e) Inspection instruction module, f) Image acquisition module, g) Quality inspection module. Detailed Implementation
[0013] This application provides a machine vision-based method for inspecting spare parts. The method involves obtaining a first spare part, which has structural feature identifiers and design feature identifiers; determining N sub-regions; scanning the N sub-regions using a laser scanning device to obtain point cloud data for the N sub-regions; obtaining a size verification result for the first spare part, which is obtained by verifying the size of the first spare part using the design feature identifiers and the point cloud data of the N sub-regions; when the size verification result of the first spare part is satisfactory, obtaining a first appearance quality inspection command; activating a CCD camera with the first appearance quality inspection command to perform image acquisition of the N sub-regions, and performing median filtering on the image acquisition results to obtain N sub-region images; and performing appearance quality inspection of the first spare part using the design feature identifiers and the N sub-region images to obtain a first appearance quality inspection report. This method solves the problem of low inspection accuracy in existing spare parts inspection methods due to insufficient rigor, and achieves rational and precise control over spare parts inspection.
[0014] Example 1
[0015] like Figure 1 As shown, this application provides a machine vision-based method and system for inspecting spare parts. The method includes:
[0016] Obtain a first spare part, wherein the first spare part has a spare part structural feature identifier and a spare part design feature identifier;
[0017] The components are structurally identified, with their features categorized into two types: structural features and design features. Structural features include functional structural designs such as threads, pin holes, and keyways. Design features refer to the size of the components. Each type of component is identified by its structural and design features, resulting in component structural feature identifiers and component design feature identifiers. These identifiers are stored to provide a basis for subsequent region division of the first component.
[0018] N component sub-regions are determined, wherein the N component sub-regions are obtained by dividing the first component into regions based on the component structural feature identifier;
[0019] The first spare part is divided into regions, and the part with the accessory structure feature identifier is separately divided into a sub-region. A spare part has one or more accessory structure feature identifiers, that is, there are correspondingly multiple accessory sub-regions. The accessory sub-regions are separately divided, which facilitates subsequent laser scanning of the accessory sub-regions. Since some spare parts have relatively complex structure features, such as internal threads, the laser scanner is prone to scanning omissions and incomplete scanning images when scanning them. Therefore, such accessory structure feature identifiers need to be separately divided and laser scanned emphatically to make the obtained scanning images more accurate.
[0020] The laser scanning device performs scanning of the N accessory sub-regions to obtain N sub-region point cloud data;
[0021] A laser scanner is a device that performs scanning measurements through high-speed lasers. It can quickly obtain the three-dimensional coordinate data of the measured object, and the area of the three-dimensional coordinate data is larger and the resolution is higher. Different from ordinary image acquisition devices, the three-dimensional scanner captures position information, while ordinary image acquisition devices capture color information and consist of many pixel points. The point cloud data of the laser scanner consists of many coordinate points. The three-dimensional coordinate data is the point cloud data, which is obtained by scanning the measured object with a laser scanner. The laser scanner performs a full rotary scan on the accessory sub-region to obtain the complete point cloud data of the accessory sub-region, that is, the sub-region point cloud data. The sub-region point cloud data provides a data basis for subsequent dimension verification of the first spare part.
[0022] The dimension verification result of the first spare part is obtained. Among them, the dimension verification result of the first spare part is obtained by performing dimension verification on the first spare part through the accessory design feature identifier and the N sub-region point cloud data;
[0023] By matching the dimensions of the accessory sub-region with the accessory design feature identifier, the dimension of the accessory sub-region, that is, the sub-region standard dimension data, is obtained. The obtained sub-region standard dimension data is matched with the sub-region point cloud data to judge the dimension size of the sub-region point cloud data, and the matching result regional dimension standard degree is obtained. The standard degree is verified by the standard degree analysis network to ensure the accuracy of the result. The average value of the dimension standard degrees of all regions of the target spare part is calculated to obtain the first dimension standard degree. The first dimension standard degree represents the overall dimension situation of the spare part. This dimension is compared with a preset threshold. If it is satisfied, it is qualified and the next step is processed. If it is not satisfied, it is unqualified and a warning is given to the spare part, providing a basis for subsequent further processing.
[0024] When the dimension verification result of the first spare part is passed, a first appearance quality inspection instruction is obtained;
[0025] After the first component's dimensions are verified, it indicates that the component's dimensions are qualified. The component's appearance quality needs to be inspected. Appearance inspection requires the use of an image acquisition device to capture the appearance. Compared to the laser scanning used in dimension inspection to obtain point cloud data, image acquisition can process the appearance of the component, such as color, texture, and decoration, more accurately and meticulously. The first appearance acquisition command is generated and sent to the image acquisition device, providing a basis for the subsequent activation of the image acquisition device to acquire images of the target component.
[0026] The first appearance quality inspection command activates the CCD camera to perform image acquisition of the N accessory sub-regions, and the image acquisition results are subjected to median filtering to obtain N sub-region images;
[0027] The image acquisition device is a CCD camera, which is widely used in image acquisition due to its small size and low cost. Upon receiving the first appearance quality inspection command, the CCD camera is activated and acquires images of multiple component sub-regions. The acquired images are then processed using median filtering, where the grayscale value of each pixel in each component sub-region is set to the median of the grayscale values of all pixels in its neighborhood, resulting in a sub-region image. Median filtering of the images acquired by the image acquisition device eliminates isolated noise points in the image, providing a foundation for subsequent appearance quality inspection.
[0028] The appearance quality of the first component is inspected using the component design feature identifier and the N sub-region images to obtain a first appearance quality inspection report.
[0029] A part model is established by identifying the design features of the parts. This model is then compared with a first part. A CCD camera is used to acquire images of the first part, and the acquisition results are analyzed. By comparing the acquired images of the first part with the data from the model, the appearance quality of the first part is assessed, and the appearance quality analysis results are obtained. In summary, a first part model is constructed, and the captured images undergo preprocessing such as smoothing and filtering to divide the image into sub-regions. Image features are extracted and compared with the features of each sub-region in the image acquired by the image acquisition device. This is used to detect the processing quality of parts on the assembly line, identify any component assembly errors, and provide error prompts and warnings, achieving the goal of intelligent detection.
[0030] Furthermore, this application also includes:
[0031] Obtain standard dimension data for N sub-regions, wherein the standard dimension data for the N sub-regions is obtained by matching the design feature identifiers of the accessories with the N accessory sub-regions;
[0032] Using the standard size data of the N sub-regions, the size standard of the point cloud data of the N sub-regions is identified to obtain the size standard of the N regions;
[0033] Obtain a first size standard, wherein the first size standard is the average of the size standards of the N regions;
[0034] Determine whether the first size standard meets the preset size standard;
[0035] If the first size standard does not meet the preset size standard, the obtained first part size verification result is "failed", and a first part size warning instruction is generated.
[0036] When dividing spare parts into sub-regions, the structural feature identifiers of the spare parts are first dimensioned using spare part design feature identifiers to obtain the sub-regional dimension information of each spare part, which is called the sub-regional standard dimension data. The sub-regional point cloud data is then matched and compared based on the sub-regional standard dimension data. After the matching and comparison is completed, the matching and comparison results are verified using a parsing network model. Based on the verification results, the sub-regional point cloud data is labeled, i.e., dimension standard recognition is performed to obtain the regional dimension standard. The average of all regional dimension standard values is calculated to obtain the average regional dimension standard, which is used as the first dimension standard. A dimension judgment is then performed on this average. If it meets the standard, subsequent operations are performed; if it does not meet the preset dimension standard value, the verification result is deemed unsuccessful, and a first spare part dimension warning command is generated to issue a warning.
[0037] Furthermore, this application also includes:
[0038] Using the standard size data of the N sub-regions and the point cloud data of the N sub-regions, generate N sub-region comparison data sets;
[0039] Obtain a database of identification records for component size standards, and build a twin size standard resolution network based on the database of identification records for component size standards;
[0040] Using the twin size standard resolution network, size standard recognition is performed on the N sub-region comparison data groups to generate the N region size standard.
[0041] The standard size data of sub-regions is compared with the point cloud data of the sub-regions. Using the same reference frame, the standard size data and the point cloud data of the sub-regions have a one-to-one spatial correspondence, resulting in a sub-region comparison data set. The parts size standard recognition record library includes historical sub-region comparison data sets and historical region size standards, with a one-to-one correspondence between them. A twin size standard resolution network is constructed based on the parts size standard recognition record library. The historical sub-region comparison data sets are input into the twin size standard resolution network, which outputs the test region size standard. The output test region standard is compared with its corresponding historical region size standard, and parameters are adjusted based on the comparison results. The model is iteratively optimized until convergence. After model training, the sub-region comparison data sets are input and processed by the twin size standard resolution network to output the region size standard. The acquisition of the region size standard provides a data foundation for subsequent determination of whether the preset size standard is met.
[0042] Furthermore, this application also includes:
[0043] A first standard model of a spare part is generated, wherein the first standard model of the spare part is obtained by modeling using the design feature identifier of the spare part through a simulation modeling platform;
[0044] N sub-region models are obtained, wherein the N sub-region models are obtained by locating the first component standard model using the N component sub-regions;
[0045] The CCD camera is used to acquire images of the N sub-region models, and the median filtering is applied to the model image acquisition results to obtain standard images of the N sub-regions.
[0046] The appearance quality is evaluated using the standard images of the N sub-regions and the images of the N sub-regions to obtain the quality evaluation coefficients of the N sub-regions, and the quality evaluation coefficients of the N sub-regions are added to the first appearance quality inspection report.
[0047] The target component parameters from the component design feature identifier are input into the simulation modeling platform. The platform generates a model based on these parameters and compares it with the component design feature identifier. If the comparison is successful, the model is output, resulting in the first component standard model. An image matching algorithm is used to match the component sub-regions with the first component standard model, obtaining matching results. Based on these results, the first component standard model is further divided according to the component sub-region division method, resulting in multiple sub-region models. Images of these sub-region models are acquired using a CCD camera, and the acquired results are filtered. Specifically, the grayscale value of each pixel in the acquired images is set to the median grayscale value of all pixels in its neighborhood, resulting in a sub-region standard image. This sub-region standard image is used as a benchmark and compared with the sub-region images to obtain the comparison result, i.e., the sub-region quality evaluation coefficient. This sub-region quality evaluation coefficient is added to the first appearance quality inspection report. Dividing the first component standard model into multiple sub-region models and processing these sub-region models improves the accuracy and efficiency of model processing, thereby increasing overall efficiency.
[0048] Furthermore, this application also includes:
[0049] Obtain N sub-model standard data, wherein the N sub-model standard data are obtained by extracting the component design feature identifiers from the N component sub-regions;
[0050] Consistency evaluation is performed by traversing the standard data of the N sub-models and the N sub-regional models to obtain the consistency evaluation results of the sub-models;
[0051] Determine whether the consistency evaluation result of the sub-model meets the preset consistency evaluation result;
[0052] If the consistency evaluation result of the sub-model does not meet the preset consistency evaluation result, a sub-model optimization instruction is generated.
[0053] The component sub-region includes component design feature identifiers. By extracting these identifiers, standard data for the sub-model is obtained. A similarity analysis is then performed between this standard data and the sub-region model to determine the similarity level. If the similarity meets a preset threshold, the sub-model is considered consistent and its data is accurate. If the similarity does not meet the threshold, the sub-model is considered inconsistent and requires further optimization, generating optimization instructions to provide further parameter correction for the sub-region model.
[0054] Furthermore, this application also includes:
[0055] Traverse the N component sub-regions to obtain the first component sub-region;
[0056] Using the first component sub-region, an evaluation data source for the first sub-region is generated based on the standard images of the N sub-regions and the images of the N sub-regions;
[0057] An appearance quality evaluation channel is established, which includes a feature recognition branch and a feature comparison branch.
[0058] The first sub-region evaluation data source is identified using the feature recognition branch to obtain the first sub-region standard features and the first sub-region features;
[0059] The feature comparison branch is used to perform the comparison degree analysis of the standard features of the first sub-region and the features of the first sub-region to obtain the feature comparison degree of the first sub-region.
[0060] Obtain the quality evaluation coefficient of the first sub-region and add the quality evaluation coefficient of the first sub-region to the quality evaluation coefficients of the N sub-regions, wherein the quality evaluation coefficient of the first sub-region is the reciprocal of the feature comparison degree of the first sub-region.
[0061] In all component sub-regions, one component sub-region is randomly selected as the first component sub-region. The first component sub-region, along with its corresponding standard and sub-region images, forms the dataset, known as the first sub-region evaluation data source. An appearance quality evaluation analysis model is constructed, consisting of two layers: a feature recognition branch and a feature comparison branch. The feature recognition branch extracts the regional features from the first sub-region evaluation data source, obtaining the standard and first sub-region features. In component inspection, image feature extraction is the primary problem the inspection system needs to solve to determine whether a component is qualified. Image features include commonly used features such as color, texture, shape, and spatial relationships, with color being the most essential. The first sub-region standard and first sub-region features are compared and analyzed in the comparison branch to obtain the first sub-region feature comparison degree. The first sub-region feature comparison degree is then inversely divided to obtain the first sub-region quality evaluation coefficient, which is added to the sub-region quality evaluation coefficient. The sub-region quality evaluation coefficient provides the data foundation for the subsequent first appearance quality inspection report.
[0062] Furthermore, this application also includes:
[0063] Determine whether the quality evaluation coefficient of the first sub-region is greater than or equal to the preset quality evaluation coefficient;
[0064] If the quality evaluation coefficient of the first sub-region is less than the preset quality evaluation coefficient, the quality standard deviation of the first sub-region is obtained, and the quality standard deviation of the first sub-region is added to the first appearance quality inspection report.
[0065] Determine whether the quality evaluation coefficient of the first sub-region meets the standard, i.e., whether it meets the preset quality evaluation coefficient. The preset quality evaluation coefficient is the minimum standard value of the quality evaluation coefficient. If the standard value is met, the obtained preset quality standard coefficient is considered to be reasonable data and can be used for subsequent calculations. If the standard value is not met, the obtained quality evaluation coefficient is considered to be a problematic quality parameter and deviation analysis needs to be performed to obtain its deviation degree, i.e., the quality deviation degree of the first sub-region. The quality standard deviation degree of the first sub-region is added to the first appearance quality inspection report. The setting of the preset quality evaluation coefficient can filter out unqualified first sub-region quality evaluation coefficients, making the obtained analysis results more reasonable and accurate.
[0066] Example 2
[0067] Based on the same inventive concept as the machine vision-based parts inspection method in the foregoing embodiments, such as Figure 2 As shown, this application provides a machine vision-based parts inspection system, the system comprising:
[0068] Parts acquisition module a: The parts acquisition module a is used to acquire a first spare part, wherein the first spare part has a part structural feature identifier and a part design feature identifier;
[0069] Region division module b: The region division module b is used to determine N component sub-regions, wherein the N component sub-regions are obtained by dividing the first component into regions based on the component structural feature identifier;
[0070] Point cloud data module c: The point cloud data module c is used to perform scanning of the N accessory sub-regions with the laser scanning device to obtain point cloud data of the N sub-regions;
[0071] Size verification module d: The size verification module d is used to obtain the size verification result of the first part, wherein the size verification result of the first part is obtained by verifying the size of the first part through the part design feature identifier and the point cloud data of the N sub-regions;
[0072] Inspection instruction module e: The inspection instruction module e is used to obtain a first appearance quality inspection instruction when the first part size verification result is passed;
[0073] Image acquisition module f: The image acquisition module f is used to activate the CCD camera to perform image acquisition of the N accessory sub-regions with the first appearance quality inspection command, and to perform median filtering on the image acquisition results to obtain N sub-region images;
[0074] Quality inspection module g: The quality inspection module g is used to perform appearance quality inspection of the first part using the part design feature identifier and the N sub-region images, and obtain a first appearance quality inspection report.
[0075] Furthermore, the system also includes:
[0076] Sub-region standard size data acquisition module: The sub-region standard size data acquisition module is used to acquire standard size data of N sub-regions, wherein the N sub-region standard size data are acquired by matching the accessory design feature identifier with the N accessory sub-regions;
[0077] Size standard recognition module: The size standard recognition module is used to identify the size standard of the point cloud data of the N sub-regions respectively using the standard size data of the N sub-regions, so as to obtain the size standard of the N regions;
[0078] The module for obtaining the average value of the size standard is used to obtain a first size standard, wherein the first size standard is the average value of the size standard values of the N regions.
[0079] Preset size standard judgment module: The preset size standard judgment module is used to determine whether the first size standard meets the preset size standard;
[0080] First spare part size warning module: The first spare part size warning module is used to obtain the first spare part size verification result as unsuccessful if the first size standard does not meet the preset size standard, and generate a first spare part size warning instruction.
[0081] Furthermore, the system also includes:
[0082] Sub-region comparison data group module: The sub-region comparison data group module is used to generate N sub-region comparison data groups using the standard size data of the N sub-regions and the point cloud data of the N sub-regions;
[0083] Twin size standard resolution analysis network construction module: The twin size standard resolution analysis network construction module is used to obtain a part size standard recognition record library, and to construct a twin size standard resolution analysis network based on the part size standard recognition record library;
[0084] Regional size standardization module: The regional size standardization module is used to identify the size standardization of the N sub-region comparison data groups using the twin size standardization resolution network, and generate the N regional size standardizations.
[0085] Furthermore, the system also includes:
[0086] Feature Identification Modeling Module: The feature identification modeling module is used to generate a first spare part standard model, wherein the first spare part standard model is obtained by modeling the spare part design feature identification through a simulation modeling platform;
[0087] Parts sub-region positioning module: The parts sub-region positioning module is used to obtain N sub-region models, wherein the N sub-region models are obtained by locating the first spare parts standard model using the N parts sub-regions;
[0088] Sub-region model image acquisition module: The sub-region model image acquisition module is used to perform image acquisition of the N sub-region models with the CCD camera, and to perform median filtering on the model image acquisition results to obtain N sub-region standard images;
[0089] Appearance quality evaluation module: The appearance quality evaluation module is used to evaluate the appearance quality using the standard images of the N sub-regions and the images of the N sub-regions, obtain the quality evaluation coefficients of the N sub-regions, and add the quality evaluation coefficients of the N sub-regions to the first appearance quality inspection report.
[0090] Furthermore, the system also includes:
[0091] Sub-model standard data acquisition module: The sub-model standard data acquisition module is used to obtain N sub-model standard data, wherein the N sub-model standard data are obtained by extracting the component design feature identifiers from the N component sub-regions;
[0092] Consistency evaluation result acquisition module: The consistency evaluation result acquisition module is used to traverse the standard data of the N sub-models and the N sub-regional models to perform consistency evaluation and obtain the consistency evaluation results of the sub-models;
[0093] Sub-model consistency evaluation result module: The sub-model consistency evaluation result module is used to determine whether the sub-model consistency evaluation result meets the preset consistency evaluation result;
[0094] Sub-model optimization instruction generation module: The sub-model optimization instruction generation module is used to generate sub-model optimization instructions if the consistency evaluation result of the sub-model does not meet the preset consistency evaluation result.
[0095] Furthermore, the system also includes:
[0096] First component sub-region acquisition module: The first component sub-region acquisition module is used to traverse the N component sub-regions and obtain the first component sub-region;
[0097] First sub-region evaluation data source module: The first sub-region evaluation data source module is used to generate a first sub-region evaluation data source based on the first accessory sub-region, the N sub-region standard images and the N sub-region images;
[0098] Appearance quality evaluation channel construction module: The appearance quality evaluation channel construction module is used to construct an appearance quality evaluation channel, wherein the appearance quality evaluation channel includes a feature recognition branch and a feature comparison branch;
[0099] First sub-region evaluation data source identification module: The first sub-region evaluation data source identification module is used to identify the first sub-region evaluation data source using the feature identification branch, and obtain the first sub-region standard feature and the first sub-region feature;
[0100] First sub-region feature comparison module: The first sub-region feature comparison module is used to perform the comparison degree analysis of the first sub-region standard features and the first sub-region features with the feature comparison branch to obtain the first sub-region feature comparison degree;
[0101] First Sub-Region Quality Evaluation Coefficient Acquisition Module: The first sub-region quality evaluation coefficient acquisition module is used to acquire the first sub-region quality evaluation coefficient and add the first sub-region quality evaluation coefficient to the N sub-region quality evaluation coefficients, wherein the first sub-region quality evaluation coefficient is the reciprocal of the feature comparison degree of the first sub-region.
[0102] Furthermore, the system also includes:
[0103] Preset quality evaluation coefficient judgment module: The preset quality evaluation coefficient judgment module is used to determine whether the quality evaluation coefficient of the first sub-region is greater than or equal to the preset quality evaluation coefficient;
[0104] First sub-region quality standard deviation acquisition module: The first sub-region quality standard deviation acquisition module is used to obtain the first sub-region quality standard deviation if the first sub-region quality evaluation coefficient is less than the preset quality evaluation coefficient, and add the first sub-region quality standard deviation to the first appearance quality inspection report.
[0105] Through the foregoing detailed description of a machine vision-based component inspection method, those skilled in the art can clearly understand that this embodiment is a machine vision-based component inspection method. As for the device disclosed in the embodiment, since it corresponds to the method disclosed in the embodiment, the description is relatively simple, and relevant parts can be referred to the method section description.
[0106] The above description of the disclosed embodiments enables those skilled in the art to make or use this application. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of this application. Therefore, this application is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.
Claims
1. A machine vision-based method for inspecting spare parts, characterized in that, The method is applied to a machine vision-based parts inspection system, the system including a laser scanning device and a CCD camera, and the method includes: Obtain a first spare part, wherein the first spare part has a spare part structural feature identifier and a spare part design feature identifier; N component sub-regions are determined, wherein the N component sub-regions are obtained by dividing the first component into regions based on the component structural feature identifier; The laser scanning device is used to scan the N component sub-regions to obtain point cloud data for the N sub-regions; Obtain the size verification result of the first component, wherein the size verification result of the first component is obtained by verifying the size of the first component through the component design feature identifier and the point cloud data of the N sub-regions; When the size verification result of the first component is passed, the first appearance quality inspection instruction is obtained; The first appearance quality inspection command activates the CCD camera to perform image acquisition of the N accessory sub-regions, and the image acquisition results are subjected to median filtering to obtain N sub-region images; The appearance quality of the first component is inspected using the component design feature identifier and the N sub-region images to obtain a first appearance quality inspection report; The process of obtaining the first component size verification result includes: Obtain standard dimension data for N sub-regions, wherein the standard dimension data for the N sub-regions is obtained by matching the design feature identifiers of the accessories with the N accessory sub-regions; Using the standard size data of the N sub-regions, the size standard of the point cloud data of the N sub-regions is identified to obtain the size standard of the N regions; Obtain a first size standard, wherein the first size standard is the average of the size standards of the N regions; Determine whether the first size standard meets the preset size standard; If the first size standard does not meet the preset size standard, the obtained first part size verification result is unsuccessful, and a first part size warning instruction is generated; The step involves identifying the size standard of the point cloud data of the N sub-regions using the standard size data of the N sub-regions, thereby obtaining the size standard of the N regions, including: Using the standard size data of the N sub-regions and the point cloud data of the N sub-regions, generate N sub-region comparison data sets; Obtain a database of identification records for component size standards, and build a twin size standard resolution network based on the database of identification records for component size standards; Using the twin size standard resolution network, size standard recognition is performed on the N sub-region comparison data groups to generate the N region size standard.
2. The method as described in claim 1, characterized in that, The appearance quality of the first component is inspected using the component design feature identifier and the N sub-region images to obtain a first appearance quality inspection report, including: A first standard model of a spare part is generated, wherein the first standard model of the spare part is obtained by modeling using the design feature identifier of the spare part through a simulation modeling platform; N sub-region models are obtained, wherein the N sub-region models are obtained by locating the first component standard model using the N component sub-regions; The CCD camera is used to acquire images of the N sub-region models, and the median filtering is applied to the model image acquisition results to obtain standard images of the N sub-regions. The appearance quality is evaluated using the standard images of the N sub-regions and the images of the N sub-regions to obtain the quality evaluation coefficients of the N sub-regions, and the quality evaluation coefficients of the N sub-regions are added to the first appearance quality inspection report.
3. The method as described in claim 2, characterized in that, After obtaining N sub-region models, the following are included: Obtain N sub-model standard data, wherein the N sub-model standard data are obtained by extracting the component design feature identifiers from the N component sub-regions; Consistency evaluation is performed by traversing the standard data of the N sub-models and the N sub-regional models to obtain the consistency evaluation results of the sub-models; Determine whether the consistency evaluation result of the sub-model meets the preset consistency evaluation result; If the consistency evaluation result of the sub-model does not meet the preset consistency evaluation result, a sub-model optimization instruction is generated.
4. The method as described in claim 2, characterized in that, Appearance quality is evaluated using the standard images of the N sub-regions and the images of the N sub-regions to obtain N sub-region quality evaluation coefficients, including: Traverse the N component sub-regions to obtain the first component sub-region; Using the first component sub-region, an evaluation data source for the first sub-region is generated based on the standard images of the N sub-regions and the images of the N sub-regions; An appearance quality evaluation channel is established, which includes a feature recognition branch and a feature comparison branch. The first sub-region evaluation data source is identified using the feature recognition branch to obtain the first sub-region standard features and the first sub-region features; The feature comparison branch is used to perform the comparison degree analysis of the standard features of the first sub-region and the features of the first sub-region to obtain the feature comparison degree of the first sub-region. Obtain the quality evaluation coefficient of the first sub-region and add the quality evaluation coefficient of the first sub-region to the quality evaluation coefficients of the N sub-regions, wherein the quality evaluation coefficient of the first sub-region is the reciprocal of the feature comparison degree of the first sub-region.
5. The method as described in claim 4, characterized in that, After obtaining the quality evaluation coefficient of the first sub-region, the following is included: Determine whether the quality evaluation coefficient of the first sub-region is greater than or equal to the preset quality evaluation coefficient; If the quality evaluation coefficient of the first sub-region is less than the preset quality evaluation coefficient, the quality standard deviation of the first sub-region is obtained, and the quality standard deviation of the first sub-region is added to the first appearance quality inspection report.
6. A machine vision-based parts inspection system, characterized in that, The system is used to perform the method according to any one of claims 1 to 5, the system comprising a laser scanning device and a CCD camera, the system comprising: Parts Acquisition Module: Acquires a first spare part, wherein the first spare part has a part structural feature identifier and a part design feature identifier; Region division module: Determines N component sub-regions, wherein the N component sub-regions are obtained by dividing the first component into regions based on the component structural feature identifier; Point cloud data module: The laser scanning device is used to scan the N accessory sub-regions to obtain point cloud data for the N sub-regions; Size verification module: Obtains the size verification result of the first component, wherein the size verification result of the first component is obtained by verifying the size of the first component through the component design feature identifier and the point cloud data of the N sub-regions; Inspection instruction module: When the size verification result of the first component is passed, a first appearance quality inspection instruction is obtained; Image acquisition module: Activates the CCD camera with the first appearance quality inspection command to perform image acquisition of the N accessory sub-regions, and performs median filtering on the image acquisition results to obtain N sub-region images; Quality inspection module: Performs appearance quality inspection on the first component using the component design feature identifier and the N sub-region images, and obtains a first appearance quality inspection report; Sub-region standard size data acquisition module: The sub-region standard size data acquisition module is used to acquire standard size data of N sub-regions, wherein the N sub-region standard size data are acquired by matching the accessory design feature identifier with the N accessory sub-regions; Size standard recognition module: The size standard recognition module is used to identify the size standard of the point cloud data of the N sub-regions respectively using the standard size data of the N sub-regions, so as to obtain the size standard of the N regions; The module for obtaining the average value of the size standard is used to obtain a first size standard, wherein the first size standard is the average value of the size standard values of the N regions. Preset size standard judgment module: The preset size standard judgment module is used to determine whether the first size standard meets the preset size standard; First spare part size warning module: The first spare part size warning module is used to obtain the first spare part size verification result as unsuccessful if the first size standard does not meet the preset size standard, and generate a first spare part size warning instruction; Sub-region comparison data group module: The sub-region comparison data group module is used to generate N sub-region comparison data groups using the standard size data of the N sub-regions and the point cloud data of the N sub-regions; Twin size standard resolution analysis network construction module: The twin size standard resolution analysis network construction module is used to obtain a part size standard recognition record library, and to construct a twin size standard resolution analysis network based on the part size standard recognition record library; Regional size standardization module: The regional size standardization module is used to identify the size standardization of the N sub-region comparison data groups using the twin size standardization resolution network, and generate the N regional size standardizations.