Plastic mold injection molding defect detection method and system
By using multi-view image acquisition and correlation indexing methods, combined with geometric and texture feature analysis, the problem of the inability to comprehensively detect internal defects in plastic molds in existing technologies has been solved. This has enabled efficient defect localization and process optimization, thereby improving the quality and production efficiency of injection molded parts.
Patent Information
- Application Number
- CN202511665280.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-11-13
- Publication Date
- 2026-01-16
AI Technical Summary
Existing methods for detecting defects in plastic mold injection molding cannot fully acquire internal information, leading to missed detection of internal defects such as air bubbles and uneven wall thickness. Furthermore, they cannot accurately locate the mold cavity corresponding to the defects, affecting detection efficiency and process optimization.
A multi-view industrial camera array is used to acquire surface and internal tomographic images. A correlation index of mold number-viewpoint-image is established, geometric and texture features are fused, and a multi-dimensional image dataset is generated. Defect analysis and optimization suggestions are made through a defect-process correlation model.
It enables comprehensive capture of internal defects, reduces missed detections, improves detection accuracy and the targeted nature of process optimization, generates executable process adjustment plans, and improves the production quality and efficiency of injection molded parts.
Smart Images

Figure CN121353259A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of image detection, in particular, mainly relates to a plastic mold injection defect detection method and system. BACKGROUND
[0002] The plastic mold injection defect detection technology gradually replaces the traditional detection method and becomes a technical means for ensuring the quality of injection parts and optimizing the mold process due to its unique advantages of integrating multi-view images and fusing geometric and texture features. Currently, some plastic mold injection defect detection methods have been proposed. These methods mainly use a single-view camera to collect the surface image of the injection part, combine simple threshold segmentation or edge detection to identify obvious defects, and then classify them through a model. However, the existing methods are affected by the lack of internal tomographic information and the neglect of the correlation between mold cavity numbers and collection angles, and only rely on surface features, which may miss internal defects such as bubbles and uneven wall thickness, and cannot accurately locate the mold cavity position corresponding to the defects, making it difficult to trace the process deviation leading to the defects, thereby reducing the detection efficiency of injection part defects. SUMMARY
[0003] To overcome the shortcomings of the prior art, the present application provides a plastic mold injection defect detection method, comprising the following steps: Step S1: Collect the surface image and internal tomographic image of the plastic mold injection part through a multi-view industrial camera array, and perform denoising, grayscale conversion and image alignment. At the same time, establish a correlation index between the mold cavity number and the collection angle corresponding to the plastic mold injection part, and generate a multi-dimensional image dataset corresponding to each injection part. Step S2: Extract the geometric features including surface flatness, wall thickness uniformity and cavity filling completeness, and the texture features including surface scratch texture and bubble distribution texture corresponding to each injection part based on the multi-dimensional image dataset, and fuse to generate a geometric texture vector corresponding to each injection part. Based on the geometric texture vector corresponding to each injection part and a pre-set defect-free injection part feature template, a preliminary defect judgment coefficient corresponding to each injection part is generated by similarity determination. Step S3: Based on the preliminary defect judgment coefficient corresponding to each injection part, the suspected defect area of each injection part is recursively determined, and the defect type of each suspected area is identified and determined. At the same time, the area proportion, depth value and position coordinates corresponding to each defect type are estimated, and a defect parameter table of the injection part is generated. Step S4: Based on the defect type and parameters in the injection part defect parameter table, and combined with the process parameters of the plastic mold, a defect-process correlation model is constructed to analyze the process deviation factors leading to the defect type, and an injection part process defect optimization suggestion is generated. At the same time, the injection defect detection archive is stored in association with the injection part defect parameter table.
[0004] Further, the present application also provides a plastic mold injection defect detection system, comprising a processor, a memory, and a computer program stored on the memory and executable on the processor, for executing the plastic mold injection defect detection method as described above.
[0005] The beneficial effects of this application are as follows: By generating a multi-dimensional image dataset through multi-view acquisition and associated indexing, the problems of traditional single-view acquisition, incomplete information, and inability to locate cavities are solved. The multi-view industrial camera array simultaneously acquires surface images and internal tomographic images, breaking the limitations of traditional methods that only acquire surface images. It can capture hidden defects such as internal bubbles and uneven wall thickness, avoiding missed detections. Noise reduction, grayscale conversion, and image alignment processing eliminate environmental interference and viewpoint deviations, ensuring the authenticity and reliability of image features. Through the associated index of mold number-viewpoint-image, a mapping relationship between defects and corresponding cavities is established—for example, if a cosmetic injection molded part frequently exhibits surface defects, the cavity can be directly located through the index. Traditional methods cannot achieve this kind of location and traceability, laying the foundation for subsequent inspection and process traceability, and improving the comprehensiveness and traceability of inspection from the source. Secondly, by fusing geometric and texture features to identify defects, geometric features such as surface flatness and wall thickness uniformity are extracted from multi-dimensional images, covering defect types that are easily overlooked by traditional methods, such as uneven internal wall thickness and insufficient cavity filling. Texture features such as surface scratches and bubble distribution supplement surface defect information. The geometric texture vector generated by fusing the two avoids the bias caused by single features. Similarity estimation with a defect-free template generates a preliminary defect judgment coefficient, quantifying the degree of defect and avoiding the subjective error of traditional threshold segmentation. This significantly improves the comprehensiveness and accuracy of preliminary defect judgment, reducing missed detections and false positives. Then, by recursively locating suspected areas and generating a defect parameter table, suspected defect areas are recursively determined based on the preliminary judgment coefficient, avoiding minor defects that are easily missed by traditional single detection. Defect types (such as scratches, bubbles, uneven wall thickness, and cracks) are identified and parameters such as area ratio and depth are estimated. Compared with traditional detection that only marks the existence of defects, this significantly improves the targeting of defect analysis and lays the foundation for process optimization. Finally, by constructing a defect-process correlation model and generating optimization suggestions, the problem of traditional inspection being limited to defect identification, unable to trace process causes, and lacking optimization guidance is solved. Correlating defect parameters with mold process parameters (such as injection temperature, pressure, and holding time) can accurately locate the process deviations that cause defects. The generated process optimization suggestions (such as increasing the barrel temperature by 5°C for bubble defects and cleaning the cavity venting grooves) transform the inspection results into actionable process adjustment plans, avoiding the disconnect between traditional inspection and production optimization. At the same time, the defect parameter table and optimization suggestions are linked and stored to form an archive, which facilitates quick querying of solutions for similar defects in the future. Compared with traditional inspection that only outputs defect reports, this step achieves a leap from "discovering problems" to "solving problems," which not only improves defect detection efficiency but also reduces recurring defects caused by process deviations, thereby improving the production quality and efficiency of injection molded parts. Attached Figure Description
[0006] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1 This is a flowchart of the plastic mold injection defect detection method in this embodiment; Figure 2 for Figure 1 A detailed flowchart illustrating the implementation steps of step S1. Detailed Implementation
[0007] The following drawings disclose several embodiments of the present invention. For clarity, many practical details will be described in the following description. However, it should be understood that these practical details are not intended to limit the invention. That is, in some embodiments of the invention, these practical details are not essential. Furthermore, for the sake of simplicity, some conventional structures and components will be shown in the drawings in a simple schematic manner.
[0008] To further understand the invention's content, features, and effects, the following embodiments are provided, and detailed descriptions are given below in conjunction with the accompanying drawings: Reference Figure 1 , Figure 1 This is a flowchart of the plastic mold injection defect detection method in this embodiment. The plastic mold injection defect detection method in this embodiment includes the following steps: Step S1: Acquire surface images and internal tomographic scan images of the plastic mold injection parts using a multi-view industrial camera array, and perform noise reduction, grayscale conversion, and image alignment. At the same time, establish a correlation index of mold number-view-image correspondence based on the mold cavity number corresponding to the plastic mold injection parts and the acquisition viewpoint to generate a multi-dimensional image dataset for each injection part. In this embodiment of the invention, four surface imaging industrial cameras (located at the top, bottom, left, and right of the injection molded part, 30cm away) and two internal tomographic scanning cameras (located at the front and back of the injection molded part, 40cm away) are deployed at the unloading station of the cosmetic eyeshadow box lid injection production line. The camera acquisition parameters are set as follows: exposure time 500 microseconds, resolution 2048×2048 pixels, surface imaging camera angle 90° vertical shooting, and tomographic scanning camera angle 45° oblique shooting. The tomographic scanning covers the entire height of the eyeshadow box lid from 0-5cm (one layer per 0.2cm). Based on the production line's 8-second / piece production cycle, the cameras are synchronously triggered by a PLC signal. For each eyeshadow box lid passing by, the four surface cameras capture four surface images (showing the top, bottom, left, and right sides of the lid), and the two tomographic cameras capture 25 internal tomographic images (covering a depth of 0-5cm). Surface images were denoised using a 5×5 Gaussian filter to eliminate glare from workshop lights; Sobel edge enhancement was applied to tomographic images to highlight internal defect contours; all images were converted to grayscale (weighted average method: grayscale value = 0.299R + 0.587G + 0.114B) and geometrically aligned using the lid positioning holes as a reference to ensure coordinate uniformity. Based on the mold cavity number corresponding to the eyeshadow lid (e.g., M06, the mold has 8 cavities) and the acquisition perspective (upward S1, downward S2, left S3, right S4, front tomography T1, back tomography T2), association indexes such as "M06-S1-Image 1" and "M06-T1-Image 5" were established to generate a multi-dimensional image dataset (containing 29 aligned images) for each eyeshadow lid.
[0009] Step S2: Based on the multi-dimensional image dataset, extract the geometric features of each injection molded part, including surface flatness, wall thickness uniformity, and cavity filling completeness, as well as the texture features of surface scratch texture and bubble distribution texture, and fuse them to generate the geometric texture vector corresponding to each injection molded part; perform similarity estimation based on the geometric texture vector corresponding to each injection molded part and the preset defect-free injection molded part feature template to generate the preliminary defect judgment coefficient corresponding to each injection molded part; In this embodiment of the invention, geometric and texture features are extracted from a multi-dimensional image dataset of each eyeshadow box lid. Regarding geometric features, surface smoothness is estimated to be 0.5 by estimating the mean Euclidean distance between the surface contour point cloud and the standard contour (e.g., 0.03mm), combined with the elastic deformation threshold of ABS material (0.06mm), and calculated using the formula "Surface smoothness = 1 - (mean distance ÷ deformation threshold)". Wall thickness uniformity is estimated to be 0.667 by statistically analyzing the minimum wall thickness (0.7mm), maximum wall thickness (1.1mm), and average wall thickness (0.9mm) of the layered wall thickness region, and calculated using the formula "Wall thickness uniformity = 1 - (maximum - minimum) ÷ average". Cavity filling completeness is estimated to be 72.75% by statistically analyzing the cavity filling pixel rate (97%), combined with the edge area filling defect coefficient (0.25), and calculated using the formula "Cavity filling completeness = Filling pixel rate × (1 - Defect coefficient)". Regarding texture features, the surface scratch texture was obtained by dividing the area into 16×16 pixel windows, estimating the contrast using the gray-level co-occurrence matrix, and selecting high-contrast windows as suspected scratch areas. The consistency of texture direction was statistically calculated to be 0.7. The bubble distribution texture was obtained by extracting the texture pattern of the bubble region using the LBP operator, and the average frequency of the pattern was statistically calculated to be 0.06. The geometric features (0.5, 0.667, 0.7275) and texture features (0.7, 0.06) were fused to generate a 5-dimensional geometric texture vector [0.5, 0.667, 0.7275, 0.7, 0.06]. Retrieve the feature template of the defect-free eyeshadow box lid (standard vector [1.0,1.0,1.0,0.0,0.0]), estimate the cosine similarity of each dimension (e.g., surface flatness similarity 0.98, wall thickness uniformity 0.96), and calculate the mean and discrete values of the similarity. The overall similarity of the vector is estimated to be 0.89 according to "vector overall similarity = ∑(mean similarity × (1 - discrete value))". Combined with the vector confidence correction parameter of 0.67, the preliminary defect judgment coefficient is estimated to be (1 - 0.89) × 0.67 ≈ 0.0737 according to "preliminary defect judgment coefficient = (1 - overall similarity) × confidence parameter". Generate the preliminary defect judgment coefficient for each eyeshadow box lid.
[0010] Step S3: Based on the preliminary defect judgment coefficient corresponding to each injection molded part, recursively determine the suspected defect areas of each injection molded part, identify and determine the defect type of each suspected area, and estimate the area ratio, depth value and location coordinates of each defect type to generate a defect type parameter table for injection molded parts. In this embodiment of the invention, by setting the recursive trigger threshold for the initial defect judgment coefficient to 0.07, if the coefficient of a certain eyeshadow box lid is 0.0737, exceeding the threshold, its multi-dimensional image dataset is retrieved, and a 50×50 pixel sliding window is used to divide the image into blocks. The local defect coefficient of each image block is estimated (e.g., the coefficient of a certain block on the edge of the lid is 0.085), generating a local defect coefficient matrix, and locating high-deviation blocks as suspected defect candidate areas. The area is expanded by 20 pixels centered on the candidate area, and the overall defect coefficient of the expanded area is estimated to be 0.078 (still exceeding the threshold). The area is further expanded to 110×110 pixels, and the coefficient drops to 0.068 (below the threshold), thus determining the complete suspected defect area (110×110 pixels at the edge and 90×90 pixels in the middle). The feature vector of the suspected area is extracted (e.g., the flatness deviation of the edge area is 0.04 mm, and the wall thickness abrupt change is 0.12 mm), and input into the pre-trained defect classification model. The output shows a matching probability of 88% for "flash" and 92% for "bubble", determining the defect type as flash and bubble. Estimated quantization parameters: The pixel area of the flare region is 10890 pixels (calibrated ratio 1 pixel = 0.02mm), and the actual area is 4.356mm². 2 The total area of the corresponding region is 100mm. 2 The area ratio is 4.356%; the laser contouring instrument collects the highest point height of the flash (0.25mm) and depth (0.15mm); with the positioning hole as the origin, the coordinates of the flash center point are (7mm, 9mm) and the coordinates of the bubble center point are (4mm, 5mm). The defect type, area ratio, depth value, and position coordinates are organized to generate a defect parameter table for the injection molded part of this eyeshadow box lid.
[0011] Step S4: Based on the defect types and parameters in the injection molded part defect type parameter table and combined with the corresponding process parameters of the plastic mold, construct a defect-process correlation model to analyze the process deviation factors that lead to the defect types, generate optimization suggestions for injection molded part process defects, and simultaneously associate and store the model with the injection molded part defect type parameter table to generate an injection molded defect detection archive.
[0012] In this embodiment of the invention, the production process parameters of the eyeshadow box lid are retrieved from the mold process management system: injection temperature 215℃, injection pressure 88MPa, holding time 3.2s, injection speed 68mm / s, and mold temperature 78℃, generating a process parameter dataset. Defect types (flash 2, bubbles 3) are coded in the defect parameter table, and the area ratio is used as a severity indicator to construct a defect-process correlation model. Pearson correlation analysis is used to estimate the correlation coefficients: injection temperature = flash 0.73, and = bubbles 0.69; injection pressure = flash 0.66, and = bubbles 0.53. Based on the correlation coefficient, key process parameters (injection temperature and injection pressure) are determined. The deviations between actual values and standard ranges (injection temperature 195-205℃, pressure 68-78MPa) are estimated (temperature +15℃, pressure +10MPa). The impact of process deviation is calculated using the formula: "Process deviation impact = absolute value of correlation coefficient × deviation value". The impacts of temperature on flash are estimated as follows: 0.73 × 15 = 10.95, and on bubbles: 0.69 × 15 = 10.35; the impacts of pressure on flash are estimated as follows: 0.66 × 10 = 6.6, and on bubbles: 0.53 × 10 = 5.3. The impacts are prioritized, with a focus on analyzing factors related to injection temperature deviation (heating coil power exceeding 12%, raw material moisture content 0.18%). Based on historical cases (a batch where flash decreased by 75% after a 10℃ temperature reduction), the adjustment direction is determined: injection temperature reduced to 195-205℃, heating coil power reduced by 12%, and raw material drying time extended to 6 hours. Optimization suggestions for process defects are then generated. The suggestions are associated with the injection part number (YG008), mold number (M06), production timestamp (2024-06-15 10:20:00), and defect parameter table information, and stored in the format of "number-time-defect parameter-process deviation-optimization suggestion" to generate an injection molding defect detection archive.
[0013] Furthermore, refer to Figure 2 , Figure 2 for Figure 1 A detailed flowchart illustrating the implementation steps of step S1 is provided below. In this embodiment, step S1 includes the following steps: Step S11: Deploy a multi-view industrial camera array, including a surface imaging camera and a tomographic scanning camera, and set camera acquisition parameters including exposure time, resolution and shooting angle. Simultaneously, trigger image acquisition according to the production cycle of the plastic mold injection part to obtain surface images and internal tomographic scanning images of different depth layers of each injection part under different viewing angles, and generate the original image set corresponding to each injection part. In this embodiment of the invention, a multi-view industrial camera array is deployed around the discharge station of the cosmetic plastic mold injection molding production line. The array includes four surface imaging cameras and two tomographic scanning cameras. The surface imaging cameras are installed at positions 30cm above, 30cm below, 20cm to the left, and 20cm to the right of the injection molded part, respectively. The tomographic scanning cameras are installed at positions 40cm in front and 40cm behind the injection molded part. The camera acquisition parameters are set for the injection molded part of the cosmetic foundation bottle (12cm high, 5cm in diameter, with a threaded bottle mouth): the exposure time is uniformly set to 500 microseconds, the resolution is set to 2048×2048 pixels, the shooting angles of the surface imaging cameras are 90° from top, 90° from bottom, 90° from left, and 90° from right, and the shooting angles of the tomographic scanning cameras are 45° from front and 45° from back. The tomographic scanning depth covers the entire height of the injection molded part from 0 to 12cm (each 0.5cm is a depth layer). Based on the production line's 6-second / piece production cycle, the camera acquisition is synchronously triggered by the production line PLC signal. When each foundation bottle injection molding part passes through the acquisition station, 4 surface imaging cameras simultaneously capture 4 surface images (showing the surface state of the bottle neck thread, bottle side, bottle bottom, and bottle front, respectively), and 2 tomographic scanning cameras capture 24 internal tomographic scanning images according to depth layers (covering a depth of 0-12cm, 1 image every 0.5cm). The 28 images captured by the 6 cameras are integrated to generate the original image set corresponding to each foundation bottle injection molding part.
[0014] Step S12: Perform Gaussian filtering on the surface images in the original image set to eliminate noise points caused by ambient light interference, and perform edge enhancement on the internal tomographic scan images to highlight the contours corresponding to internal defects, thus obtaining the pre-processed image set for each injection molded part. In this embodiment of the invention, Gaussian filtering is applied to four surface images from the original image set of each foundation bottle injection molding part for noise reduction. A 5×5 Gaussian filter template is used, and the image pixel values are weighted and averaged through convolution operation. For example, the bright spot noise (pixel value 250-255) caused by the reflection of LED lights in the workshop in the surface image is smoothly reduced to 230-235 after filtering, eliminating noise points caused by ambient light interference, and making defects such as scratches and missing materials on the bottle surface clearer. Edge enhancement processing was performed on 24 internal tomographic scan images. The Sobel edge detection algorithm was used to estimate the gradient values of the images in the horizontal and vertical directions. Pixels with gradient values greater than a preset threshold (e.g., 80) were marked as edge pixels to highlight the contours of internal bubbles and impurities. For example, in the internal tomographic image, the gray value difference of the bubble edge of a 0.3cm diameter bubble was increased from 10-15 to 30-40 after edge enhancement, and the bubble contour was clearly distinguishable. Finally, a preprocessed image set was obtained for each foundation bottle injection molding part, including 4 denoised surface images and 24 edge-enhanced internal tomographic images.
[0015] Step S13: Perform grayscale processing on the preprocessed image set corresponding to each injection molded part to generate a grayscale image set corresponding to each injection molded part; In this embodiment of the invention, the pre-processed image set (28 images) corresponding to each foundation bottle injection molding part is grayscale processed, and the color image (RGB three channels) is converted into a grayscale image by weighted average method. The grayscale value estimation formula is grayscale value = 0.299 × R channel value + 0.587 × G channel value + 0.114 × B channel value. For example, in the pre-processed surface image, the red area of the bottle neck thread (R=220, G=180, B=150) has an estimated grayscale value of 0.299×220+0.587×180+0.114×150≈65.78+105.66+17.1=188.54, rounded to 188; in the internal tomographic image, the transparent area of the bottle body (R=240, G=240, B=240) has an estimated grayscale value of ≈0.299×240+0.587×240+0.114×240≈(0.299+0.587+0.114)×240=1×240=240. Using this method, all 28 pre-processed color images are converted to 8-bit grayscale images (grayscale value range 0-255), generating a grayscale image set corresponding to each foundation bottle injection molded part.
[0016] Step S14: Obtain the reference feature points of the surface image and internal tomographic scan image in the grayscale image set corresponding to each injection molded part, and perform geometric alignment of the surface image and internal tomographic scan image corresponding to different viewpoints based on the reference feature points to ensure that the coordinates of the multi-view image of the same injection molded part are unified, so as to generate the reference image set corresponding to each injection molded part. In this embodiment of the invention, reference feature points are obtained from the surface image and internal tomographic scan image of each foundation bottle injection molding part in the grayscale image set. The surface image selects three fixed tooth profile vertices of the bottle mouth thread (coordinates of (500,500), (800,500), and (1100,500) of the surface image) as reference feature points. The internal tomographic scan image selects two right angle intersection points of the inner wall of the bottle and the bottom of the bottle (coordinates of (600,800) and (1400,800) of the tomographic image) as reference feature points. An image registration algorithm is used to perform geometric transformations (translation, rotation, and scaling) on four surface images from different perspectives, using three reference feature points of the surface image as a reference. For example, the surface image taken on the right is rotated by 180° and translated by 200 pixels so that the coordinates of the reference feature points of this image are consistent with the coordinates of the reference feature points of the top-view surface image (both are (500, 500), (800, 500), (1100, 500)). Similarly, using two reference feature points of the internal tomographic scan image as a reference, 24 tomographic images at different depths are geometrically aligned to ensure that the coordinates of the reference feature points of all tomographic images are unified as (600, 800) and (1400, 800). Finally, a set of reference images (28 grayscale images with unified coordinates) corresponding to each foundation bottle injection molding part is generated.
[0017] Step S15: Obtain the mold cavity number corresponding to the plastic mold injection part, and establish the association index of mold number-viewpoint-image correspondence based on the corresponding shooting angle. At the same time, based on the association index of mold number-viewpoint-image correspondence, index and integrate the benchmark image set corresponding to each injection part to generate a multi-dimensional image dataset corresponding to each injection part.
[0018] In this embodiment of the invention, by obtaining the mold cavity number corresponding to each injection molding part of a cosmetic foundation bottle (e.g., the mold contains 8 cavities, numbered M01-M08, and each injection molding part is labeled with the corresponding cavity number, such as M03), and combining the corresponding shooting angle (surface image angle: top view F, bottom view U, left view L, right view R; tomographic scanning angle: front view F1, rear view F2), an association index of mold number-viewpoint-image is established, with the format being "mold number-viewpoint type-image sequence number", for example, M03-F-1 (representing the top view surface image of the injection molding part with cavity M03) and M03-F1-5 (representing the 5th layer image of the front view tomographic scanning of the injection molding part with cavity M03). Based on this association index, the baseline image set (28 images) for each injection molded part is indexed and integrated. The images are stored in a hierarchical classification according to "mold number → view type → image sequence number". For example, the baseline image set for the M03 cavity injection molded part is divided into two categories: "surface images (1 each of F, U, L, and R views)" and "computed tomography images (12 images of F1 view and 12 images of F2 view)". The images in each category are sorted by sequence number, generating a multi-dimensional image dataset corresponding to each injection molded part of a cosmetic foundation bottle, ensuring that the corresponding image can be quickly located by mold number and view during subsequent defect detection.
[0019] Furthermore, step S2 includes the following steps: Step S21: For each injection molded part, obtain the surface contour point cloud data of the injection molded part, estimate the average Euclidean distance between the contour points and the standard contour, and generate the average surface contour deviation; obtain the elastic deformation threshold corresponding to the material of the injection molded part, and generate the surface flatness corresponding to each injection molded part based on the ratio between the average surface contour deviation and the elastic deformation threshold. In this embodiment of the invention, surface contour point cloud data is extracted using an image segmentation algorithm based on a surface image (top-view grayscale image, resolution 2048×2048 pixels, calibration ratio 1 pixel = 0.02 mm) of the injection-molded outer shell of a cosmetic lipstick tube. A total of 1500 contour points (coordinates such as (500, 500), (600, 500)...(2000, 500)) are obtained. Standard contour point cloud data (corresponding points of the same number and position) of defect-free lipstick tube shells are retrieved, and the Euclidean distance between each corresponding contour point is estimated (e.g., the actual distance of the 1st point is 0.03 mm, the 500th point is 0.02 mm, and the 1500th point is 0.04 mm). The mean of the 1500 distances is calculated as (0.03 + 0.02 + ... + 0.04) ÷ 1500 ≈ 0.025 mm, generating a surface contour deviation mean of 0.025 mm. The injection molded part is made of ABS plastic, and its elastic deformation threshold is 0.05mm (preset material-deformation threshold reference table). By estimating "surface flatness = 1 - (average surface profile deviation ÷ elastic deformation threshold)", we get 1 - (0.025 ÷ 0.05) = 0.5, and the surface flatness of the lipstick tube shell injection molded part is 0.5.
[0020] Step S22: For each injection molded part, the internal tomographic scan image is divided into a wall thickness region, a cavity filling region, and an edge region. Based on the image calibration ratio, the minimum wall thickness, maximum wall thickness, and average wall thickness of the wall thickness region are statistically analyzed by depth layer. At the same time, the wall thickness uniformity is generated based on the wall thickness uniformity = 1 - (maximum wall thickness - minimum wall thickness) / average wall thickness. The cavity filling pixel rate is generated by statistically analyzing the pixel ratio of the cavity filling region by depth layer. The edge region filling defect coefficient is obtained based on the edge region. At the same time, the cavity filling completeness is estimated based on the cavity filling pixel rate and the edge region filling defect coefficient. In this embodiment of the invention, 24 internal tomographic scan images of the injection-molded outer shell of the cosmetic lipstick tube (covering a depth of 0-10cm, one image per 0.5cm, with a calibration ratio of 1 pixel = 0.02mm) are used to divide the wall thickness region (grayscale value 180-220), the cavity filling region (grayscale value 230-250), and the edge region (grayscale value 150-170) using a region growing algorithm. Statistical data on wall thickness by depth layer: Layer 1 (0-0.5cm): minimum wall thickness 0.8mm, maximum wall thickness 1.0mm, average wall thickness 0.9mm; Layer 10 (4.5-5cm): minimum wall thickness 0.75mm, maximum wall thickness 1.05mm, average wall thickness 0.9mm; Layer 24 (9.5-10cm): minimum wall thickness 0.82mm, maximum wall thickness 0.98mm, average wall thickness 0.9mm. Taking the average wall thickness of all layers as 0.9mm, the maximum wall thickness as 1.05mm, and the minimum wall thickness as 0.75mm, the wall thickness uniformity is estimated using "wall thickness uniformity = 1 - (maximum wall thickness - minimum wall thickness) / average wall thickness". The result is 1 - (1.05 - 0.75) ÷ 0.9 ≈ 1 - 0.333 = 0.667, thus generating a wall thickness uniformity of 0.667. The percentage of pixels in the cavity filling area is statistically analyzed based on the depth layer (e.g., 98% in layer 1, 97% in layer 10, and 99% in layer 24). The mean is (98% + 97% + ... + 99%) ÷ 24 ≈ 98%, resulting in a cavity filling pixel rate of 98%. The edge filling defect coefficient for this injection molded part was previously estimated at 0.26. Using the formula "Cavity filling completeness = Cavity filling pixel rate × (1 - Edge filling defect coefficient)", we estimate 98% × (1 - 0.26) = 72.52%, resulting in a cavity filling completeness of 72.52%.
[0021] Step S23: Divide the surface image into individual pixel windows, and use the gray-level co-occurrence matrix to estimate the contrast, correlation, and energy values of the pixels within the window. Select pixel window areas with contrast higher than the threshold as suspected scratch areas, and generate surface scratch texture based on the correlation and energy values of the corresponding areas to calculate the texture direction consistency of the areas. For the internal tomographic scan image, use the LBP texture operator to extract the local texture patterns corresponding to the bubble areas and calculate the frequency of pattern occurrence to generate bubble distribution texture. In this embodiment of the invention, the surface image (2048×2048 pixels) of the injection-molded part of the cosmetic lipstick tube shell is divided into 1024 16×16 pixel windows. For each pixel window, the contrast (range 0-1000), correlation (range -1-1), and energy value (range 0-1) are estimated using a gray-level co-occurrence matrix (distance 1, angle 0°). A contrast threshold of 300 is set, and 28 pixel windows with a contrast higher than 300 are selected as suspected scratch areas (e.g., the pixel window with coordinates (100-115, 200-215) has a contrast of 350). The correlation (mean 0.6) and energy value (mean 0.3) of these suspected scratch areas are statistically analyzed. The texture direction consistency algorithm estimates that the proportion of areas with consistent texture direction is 80%, and the surface scratch texture parameters are generated at 80%. The LBP texture operator (3×3 neighborhood, 8 sampling points) was used to extract the local texture patterns of the bubble region (grayscale value 100-150) from the internal tomographic scan image. A total of 5 patterns were identified (such as pattern 0: 11111111, pattern 1: 11110000, etc.). The frequency of each pattern was counted (pattern 0 appeared 12 times, pattern 1 appeared 8 times, ... pattern 5 appeared 5 times). The bubble distribution texture data was generated by organizing the data according to "pattern type-frequency".
[0022] Step S24: Fuse the geometric features of each injection molded part, which include surface flatness, wall thickness uniformity and cavity filling completeness, with the texture features, which include surface scratch texture and bubble distribution texture, to generate the geometric texture vector corresponding to each injection molded part. In this embodiment of the invention, geometric and texture features of the injection-molded outer shell of a cosmetic lipstick tube are extracted. Geometric features include surface flatness (0.5), wall thickness uniformity (0.667), and cavity filling completeness (72.52%, converted to 0.7252). Texture features include surface scratch texture (0.8, 80% conversion) and bubble distribution texture (the average frequency of each pattern is (12+8+…+5)÷5=8.2, converted to 0.082). A feature fusion algorithm is used to concatenate the two types of features in the order of "geometric features → texture features" to construct a 5-dimensional geometric texture vector: [0.5, 0.667, 0.7252, 0.8, 0.082]. The values of each dimension are normalized to the range of 0-1, generating the geometric texture vector corresponding to the injection-molded outer shell of the lipstick tube.
[0023] Step S25: Based on the geometric texture vector corresponding to each injection molded part and the preset feature template of the defect-free injection molded part, perform similarity judgment estimation to generate the preliminary defect judgment coefficient corresponding to each injection molded part.
[0024] In this embodiment of the invention, a preset feature template of a defect-free cosmetic lipstick tube casing injection molded part is retrieved. Its standard geometric texture vector is [1.0, 1.0, 1.0, 0.0, 0.0] (surface flatness 1.0, wall thickness uniformity 1.0, cavity filling completeness 1.0, surface scratch texture 0.0, bubble distribution texture 0.0). The cosine similarity between the vector to be detected [0.5, 0.667, 0.7252, 0.8, 0.082] and the standard vector is estimated, and the similarity is approximately 0.65. The vector confidence correction parameter of the injection molded part to be detected has been obtained in the early stage, which is 0.67. The preliminary defect judgment coefficient is estimated to be (1-0.65)×0.67≈0.2345 by using "preliminary defect judgment coefficient = (1-vector similarity)×vector confidence correction parameter". The preliminary defect judgment coefficient of the cosmetic lipstick tube casing injection molded part is then generated as 0.2345.
[0025] Furthermore, the step S22, which involves obtaining the corresponding edge region filling defect coefficient based on the edge region, includes the following steps: The Sobel operator is used to extract the contour pixels corresponding to the edge region, and the edge contour coordinate set is constructed. At the same time, the mold cavity design parameters corresponding to the edge region are associated, including the standard width and radius of curvature of the edge, to generate the basic dataset of the edge region. In this embodiment of the invention, edge detection is performed on the threaded edge region of the injection-molded bottle opening of a cosmetic foundation liquid (a top-view grayscale image selected from a reference image set). A 3×3 Sobel operator is used to estimate the gradient values of the image in the x-direction (horizontal) and y-direction (vertical) respectively. The gradient magnitude is then calculated using the formula: gradient magnitude = √(Gx) 2 +Gy 2 Pixels with gradient magnitudes greater than a preset threshold (80) are selected as edge contour pixels, and a total of 1200 contour pixels are extracted. The coordinates of these pixels (e.g., (501,500), (502,501)...(1099,500)) are arranged in order to construct an edge contour coordinate set. At the same time, the mold cavity design parameters corresponding to the edge of the bottle mouth thread are retrieved from the mold design document: the standard edge width is 0.8mm (corresponding to an image pixel width of 16 pixels, and the image calibration ratio is 1 pixel = 0.05mm), and the radius of curvature is 0.2mm (corresponding to an image pixel radius of 4 pixels). The edge contour coordinate set is integrated with the design parameters to generate the basic dataset of the edge region.
[0026] Furthermore, the actual geometric deviation rate of the edges is estimated based on the edge region dataset and the image calibration ratio; In this embodiment of the invention, based on the edge region dataset, the pixel dimensions in the edge contour coordinate set are first converted into actual geometric dimensions according to the image calibration ratio (1 pixel = 0.05 mm). Ten evenly distributed measurement points are selected from the edge contour coordinate set, and the actual width of the edge at each point is measured (e.g., the first measurement point has a pixel width of 14 pixels → actual width 0.7 mm, the fifth measurement point has a pixel width of 15 pixels → actual width 0.75 mm, and the tenth measurement point has a pixel width of 17 pixels → actual width 0.85 mm). The average actual width of the 10 measurement points is estimated to be (0.7 + 0.75 + 0.85 + 0.72 + 0.78 + 0.82 + 0.76 + 0.81 + 0.79 + 0.83) ÷ 10 = 0.785 mm. The standard edge width is 0.8mm. Using the formula for estimating the actual geometric deviation rate of the edge, "Actual geometric deviation rate of the edge = |Average actual width - Standard width| ÷ Standard width × 100%", we estimate that |0.785 - 0.8| ÷ 0.8 × 100% = 1.875%, which gives us the actual geometric deviation rate of the edge of the bottle neck threaded edge area as 1.875%.
[0027] Furthermore, the filling state data corresponding to the edge region is extracted, and the edge region is binarized based on the filling state data, where the filled region is 1 and the unfilled region is 0. The proportion of unfilled pixels in the edge region is calculated to generate the proportion of unfilled pixels in the edge. At the same time, the number of connected components and the average area of the unfilled region are analyzed. The edge filling defect dispersion is estimated based on the proportion of unfilled pixels in the edge, the number of connected components and the average area. In this embodiment of the invention, the filling status data corresponding to the edge region of the bottle neck thread is extracted (obtained from the preprocessed surface image; the grayscale value of pixels in the fully filled area is 230-250, and the grayscale value of pixels in the unfilled area is 100-150). A fixed threshold method (threshold 180) is used to binarize the edge region. Filled areas with a grayscale value ≥ 180 are marked as 1, and unfilled areas with a grayscale value < 180 are marked as 0. The total number of pixels in the edge region is 8000 pixels, and the number of unfilled pixels is 320 pixels. Using the formula for estimating the percentage of unfilled pixels at the edge: "Percentage of unfilled pixels at the edge = Number of unfilled pixels ÷ Total number of pixels × 100%", the estimated value is 320 ÷ 8000 × 100% = 4%. A connected component labeling algorithm (based on the 4-neighborhood connectivity criterion) was used to identify connected regions in unfilled areas. A total of 8 connected regions were detected. The pixel area of each connected region was measured (e.g., 45 pixels for the 1st connected region, 38 pixels for the 2nd connected region, 42 pixels for the 3rd connected region, ..., 35 pixels for the 8th connected region). The average area of the connected regions was estimated to be (45+38+42+39+41+37+40+35)÷8=39.625 pixels. Parameters were generated with an edge unfilled pixel ratio of 4%, 8 connected regions, and an average area of 39.625 pixels. With a weight of 0.5 for the percentage of unfilled pixels at the edge, a weight of 0.3 for the number of connected regions, and a weight of 0.2 for the average area, the edge fill defect dispersion is estimated as (4÷100)×0.5+(8÷10)×0.3+(39.625÷100)×0.2=0.02+0.24+0.07925=0.33925 using the formula: "Edge fill defect dispersion = (percentage of unfilled pixels ÷ 100)×0.5+(number of connected regions ÷ 10)×0.3+(average area ÷ 100)×0.2". The resulting edge fill defect dispersion is 0.33925.
[0028] Furthermore, the corresponding edge filling base defect value is obtained by weighted estimation based on the normalized weighted average of the actual geometric deviation rate of the edge and the proportion of unfilled pixels at the edge. The corresponding edge filling defect coefficient is then generated by estimating the edge filling defect coefficient = edge filling base defect value × (1 + edge filling defect dispersion) based on the edge filling defect dispersion and the edge filling base defect value.
[0029] In this embodiment of the invention, the actual geometric deviation rate of the edge (1.875%) and the proportion of unfilled pixels at the edge (4%) are normalized using the formula "normalized value = parameter value ÷ maximum parameter value". The maximum value of the actual geometric deviation rate is set to 10%, and the maximum proportion of unfilled pixels at the edge is set to 20%. Therefore, the normalized geometric deviation rate = 1.875 ÷ 10 = 0.1875, and the normalized unfilled proportion = 4 ÷ 20 = 0.2. With a weight of 0.4 for the normalized geometric deviation rate and 0.6 for the normalized unfilled proportion, the estimated value is 0.1875 × 0.4 + 0.2 × 0.6 = 0.075 + 0.12 = 0.195, calculated using the formula "edge fill base defect value = normalized geometric deviation rate × 0.4 + normalized unfilled proportion × 0.6". Given that the edge filling defect dispersion is 0.33925, substituting it into "Edge area filling defect coefficient = basic edge filling defect value × (1 + edge filling defect dispersion)", we estimate that 0.195 × (1 + 0.33925) = 0.195 × 1.33925 ≈ 0.2612, thus generating the edge area filling defect coefficient of 0.2612 corresponding to the threaded edge area of the injection molded part of the cosmetic foundation bottle.
[0030] Furthermore, step S25 includes the following steps: Step S251: Retrieve the preset feature template of the defect-free injection molded part, which includes the standard geometric feature vector in the defect-free state, including surface flatness, wall thickness uniformity and cavity filling completeness, and the standard texture feature vector, including surface scratch texture and bubble distribution texture. At the same time, extract the geometric texture vector corresponding to the injection molded part to be detected and construct the detection vector-standard vector comparison dataset. In this embodiment of the invention, a defect-free injection molded part feature template for a cosmetic blush box base is retrieved from the template library of the defect detection system. This template includes standard geometric feature vectors and standard texture feature vectors. In the standard geometric feature vectors, the standard value for surface flatness is 0.02mm (allowable deviation ±0.005mm), the standard value for wall thickness uniformity is 98% (allowable deviation ±2%), and the standard value for cavity filling completeness is 100% (no deviation). In the standard texture feature vectors, the standard value for surface scratch texture is 0 scratches / mm² (no scratches), and the standard value for bubble distribution texture is 0 bubbles / cm. 3 (No air bubbles). From the multi-dimensional image dataset of the blush box base of the cosmetic product to be tested, the corresponding geometric texture vectors were extracted: surface flatness 0.023 mm, wall thickness uniformity 95%, cavity filling completeness 99%, and surface scratch texture 0.3 lines / mm. 2 Bubble distribution texture: 0.2 bubbles / cm 3 The standard vector and the vector to be detected are organized in the format of "feature type-standard value-value to be detected" to construct a comparison dataset of vector to be detected and standard vector, ensuring that each feature dimension corresponds one-to-one.
[0031] Step S252: Use cosine similarity to estimate the dimensional similarity of each dimension in the dataset of the vector to be detected and the standard vector comparison, and calculate the mean and standard deviation of the dimensional similarity over a test time period to generate the mean and discrete values of dimensional similarity. In this embodiment of the invention, the cosine similarity algorithm is used to estimate the dimensional similarity of the five feature dimensions (surface smoothness, wall thickness uniformity, cavity filling completeness, surface scratch texture, and bubble distribution texture) in the dataset comparing the vector to be detected with the standard vector. Taking surface smoothness as an example, with a standard vector value of 0.02 mm and a vector to be detected value of 0.023 mm, the dimensional similarity is estimated to be 0.98 using the cosine similarity formula; for wall thickness uniformity, with a standard value of 98% and a value to be detected of 95%, the dimensional similarity is estimated to be 0.96; for cavity filling completeness, with a standard value of 100% and a value to be detected of 99%, the dimensional similarity is estimated to be 0.99; and for surface scratch texture, with a standard value of 0 scratches / mm... 2 The value to be detected is 0.3 pieces / mm. 2 The estimated dimensional similarity is 0.85; the standard value for bubble distribution texture is 0 bubbles / cm. 3 The value to be detected is 0.2 particles / cm. 3 The estimated dimensional similarity was 0.88. The test timeframe was set to 1 hour (including data from 20 similar injection molded parts). The mean and standard deviation of the similarity for each dimension were calculated within this timeframe: surface smoothness similarity: mean 0.97, standard deviation 0.01; wall thickness uniformity: mean 0.95, standard deviation 0.02; cavity filling completeness: mean 0.98, standard deviation 0.01; surface scratch texture: mean 0.86, standard deviation 0.03; bubble distribution texture: mean 0.87, standard deviation 0.02. The mean and standard deviation of the similarity for each dimension were then generated.
[0032] Step S253: Using the mean of dimensional similarity as the basic similarity and combining it with the discrete value of dimensional similarity for correction estimation, the overall similarity between the vector to be detected and the standard vector is estimated by the overall vector similarity = ∑ mean of dimensional similarity × (1 - discrete value of dimensional similarity). In this embodiment of the invention, the similarity is estimated by using the mean of the similarity in each dimension as the basic similarity, combined with the corresponding discrete value of the similarity in each dimension. The correction formula is "single dimension corrected similarity = mean of the similarity in each dimension × (1 - discrete value of the similarity in each dimension)". The corrected similarity in each of the five dimensions is estimated as follows: surface smoothness 0.97 × (1 - 0.01) = 0.9603; wall thickness uniformity 0.95 × (1 - 0.02) = 0.931; cavity filling completeness 0.98 × (1 - 0.01) = 0.9702; surface scratch texture 0.86 × (1 - 0.03) = 0.8342; bubble distribution texture 0.87 × (1 - 0.02) = 0.8526. By using the formula "overall vector similarity = ∑similarity after correction of a single dimension ÷ total number of dimensions", we estimate that (0.9603 + 0.931 + 0.9702 + 0.8342 + 0.8526) ÷ 5 ≈ 4.5483 ÷ 5 ≈ 0.9097, thus obtaining an overall vector similarity of 0.9097 for the injection-molded base of the blush box to be tested.
[0033] Step S254: Obtain the corresponding vector confidence correction parameters based on the geometric texture vector of the injection molded part to be detected; In this embodiment of the invention, the corresponding vector confidence correction parameter is obtained based on the geometric texture vector of the injection-molded blush box base of the cosmetic to be tested. This parameter is generated through prior source data quality assessment and vector stability analysis: in the acquisition equipment parameters, the standard value of the industrial camera exposure time is 450 microseconds, the actual value is 460 microseconds, and the equipment parameter deviation coefficient is 0.022; in the image processing output data, the detail retention rate after denoising is 96%, the edge enhancement contour accuracy is 94%, and the preprocessing effect score is 95; in the intrinsic stability of the vector, the average fluctuation amplitude of each dimension is 0.03mm (or %, bar / mm², etc.), the vector dimension fluctuation is 0.028, and the dimension correlation coefficient is 0.12. After normalized weighted estimation, the basic confidence value is 0.685; 100 historical confidence records of the same type of injection-molded parts are retrieved, the historical average is 0.678, and the estimated historical deviation correction coefficient is 0.992. Finally, by using the formula "vector confidence correction parameter = confidence base value × historical deviation correction coefficient", we estimate that 0.685 × 0.992 ≈ 0.680, and obtain the vector confidence correction parameter of 0.680 for the injection molded part to be tested.
[0034] Step S255: Based on the vector confidence correction parameter and the overall vector similarity between the vector to be detected and the standard vector, generate the preliminary defect judgment coefficient for each injection molded part. Specifically, the preliminary defect judgment coefficient = (1 - overall vector similarity) × vector confidence correction parameter.
[0035] In this embodiment of the invention, the preliminary defect determination coefficient is estimated using the estimation formula "Preliminary Defect Determination Coefficient = (1 - Overall Vector Similarity) × Vector Confidence Correction Parameter" based on the vector confidence correction parameter of 0.680 and the overall vector similarity between the vector to be detected and the standard vector of 0.9097. First, the overall vector similarity is estimated as 1 - 0.9097 = 0.0903. Then, this value is multiplied by the vector confidence correction parameter of 0.680: 0.0903 × 0.680 ≈ 0.0614, generating a preliminary defect determination coefficient of 0.0614 for the injection-molded blush box base of the cosmetic to be detected. This coefficient is used for subsequent defect level determination; a larger value indicates a higher probability of defects in the injection-molded part, while a smaller value indicates a higher confidence level of no defects.
[0036] Furthermore, step S254 includes the following steps: Based on the geometric texture vector of the injection molded part to be inspected, the corresponding generation source data is obtained, including the acquisition equipment parameter data and image processing output data, and a vector-source data association table is constructed to clarify the correspondence between the geometric texture vector and the data of each generation stage. In this embodiment of the invention, the corresponding source data is obtained by using the geometric texture vector (containing three dimensions: edge width, surface roughness, and texture density, with vector values of 0.75mm, 1.2μm, and 20 lines / mm, respectively) of the injection molded part of the cosmetic eyeshadow box lid (the injection molded part to be tested). The acquired equipment parameters include an industrial camera exposure time of 500 microseconds (standard value set at 450 microseconds), a resolution of 2048×2048 pixels (consistent with standard values), and a lens focal length of 16mm (standard value 16mm). The image processing output data includes an image signal-to-noise ratio of 35dB after Gaussian filtering and a contour extraction accuracy of 92% after edge enhancement. Construct a vector-source data association table. The table's rows are "Geometric texture vector dimensions (edge width, surface roughness, texture density)" and the columns are "Acquisition device parameters (exposure time, resolution, focal length)" and "Image processing output data (signal-to-noise ratio, contour extraction accuracy)". Fill in the corresponding relationships in the cells, such as "edge width - exposure time 500 microseconds - contour extraction accuracy 92%". Clarify the correspondence between each dimension of the geometric texture vector and the data in the generation process, and generate the vector-source data association table.
[0037] Furthermore, source data quality parameters are estimated based on the vector-source data association table to estimate the device parameter deviation coefficients for the acquired device parameter data; the detail retention rate and contour accuracy of the denoised image are analyzed for the image processing output data, and a preprocessing effect score is generated. In this embodiment of the invention, source data quality parameters are estimated based on a vector-source data association table. The device parameter deviation coefficient is estimated for the acquired device parameter data. Three parameters are selected: exposure time (standard value 450 microseconds, actual value 500 microseconds), resolution (standard and actual values are consistent), and focal length (standard and actual values are consistent). Using the formula "device parameter deviation coefficient = Σ(|actual value - standard value| ÷ standard value) ÷ total number of parameters", the estimated value is (|500 - 450| ÷ 450 + 0 + 0) ÷ 3 ≈ 0.037, resulting in a device parameter deviation coefficient of 0.037. For image processing output data analysis, the detail retention rate is estimated by comparing the number of texture feature points before and after denoising (1200 before denoising, 1150 after denoising), resulting in 1150 ÷ 1200 ≈ 0.958. The contour accuracy is estimated by comparing the number of overlapping pixels between the enhanced contour and the standard contour (800 pixels in the enhanced contour, 760 overlapping pixels), resulting in 760 ÷ 800 = 0.95. Using the formula "Preprocessing effect score = (detail retention rate × 0.5 + contour accuracy × 0.5) × 100", the estimated value is (0.958 × 0.5 + 0.95 × 0.5) × 100 ≈ 95.4, resulting in a preprocessing effect score of 95.4.
[0038] Furthermore, the intrinsic stability parameters of the geometric texture vector are estimated, and the consistency of the geometric feature dimension and the texture feature dimension in the geometric texture vector are checked respectively. The fluctuation range of each dimension data is statistically analyzed to generate the vector dimension fluctuation. At the same time, the correlation between each dimension of the vector is estimated to generate the dimension correlation coefficient. In this embodiment of the invention, the intrinsic stability parameters of the geometric texture vector are estimated. Consistency checks are performed on the three dimensions of the geometric texture vector (edge width, surface roughness, and texture density). Ten detection areas are selected on the injection-molded eyeshadow palette lid to be tested, and the dimensional data of each area are measured: edge width (0.75, 0.74, 0.76, 0.75, 0.73, 0.77, 0.75, 0.74, 0.76, 0.75 mm), surface roughness (1.2, 1.18, 1.22, 1.21, 1.19, 1.23, 1.2, 1.18, 1.22, 1.21 μm), and texture density (20, 19.8, 20.2, 20.1, 19.9, 20.3, 20, 19.8, 20.2, 20.1 lines / mm). Estimate the fluctuation range of each dimension (maximum value - minimum value): edge width 0.77-0.73=0.04mm, surface roughness 1.23-1.18=0.05μm, texture density 20.3-19.8=0.5 lines / mm. Using "vector dimension fluctuation = Σ (fluctuation range ÷ standard value) ÷ total number of dimensions" (standard value of edge width 0.8mm, standard value of surface roughness 1.2μm, standard value of texture density 20 lines / mm), we estimate (0.04÷0.8+0.05÷1.2+0.5÷20)÷3≈(0.05+0.0417+0.025)÷3≈0.0389, generating a vector dimension fluctuation of 0.0389. The correlation between the dimensions of the vector is estimated. The correlation coefficients between edge width and surface roughness are estimated to be 0.12, 0.08, and 0.15 respectively, using the Pearson correlation coefficient formula. The average value is (0.12+0.08+0.15)÷3≈0.117, and the dimensional correlation coefficient is 0.117.
[0039] Furthermore, a confidence baseline value is generated based on the source data quality parameters and intrinsic stability parameters. The contribution value of the source data is estimated after normalizing the equipment parameter deviation coefficient and the preprocessing effect score. The contribution value of the generated vector itself is estimated by combining the vector dimension volatility and dimension correlation coefficient. The two contribution values are then weighted and summed to obtain the confidence baseline value. In this embodiment of the invention, a confidence baseline value is generated based on source data quality parameters (equipment parameter deviation coefficient 0.037, preprocessing effect score 95.4) and intrinsic stability parameters (vector dimension volatility 0.0389, dimension correlation coefficient 0.117). The equipment parameter deviation coefficient is normalized (maximum value 0.1, normalized value 0.037 ÷ 0.1 = 0.37), and the preprocessing effect score is normalized (maximum value 100, normalized value 95.4 ÷ 100 = 0.954). Using the formula "source data contribution value = (1 - normalized deviation coefficient) × 0.4 + normalized preprocessing score × 0.6", the estimated value is (1 - 0.37) × 0.4 + 0.954 × 0.6 ≈ 0.252 + 0.572 = 0.824. Normalizing the vector dimension volatility (maximum value 0.1, normalized value 0.0389 ÷ 0.1 = 0.389) and the dimension correlation coefficient (maximum value 1, normalized value 0.117), and using the formula "vector self-contribution value = (1 - normalized volatility) × 0.7 + normalized correlation coefficient × 0.3", we estimate (1 - 0.389) × 0.7 + 0.117 × 0.3 ≈ 0.427 + 0.035 = 0.462. Setting the source data contribution value weight to 0.6 and the vector self-contribution value weight to 0.4, and using the formula "confidence base value = source data contribution value × 0.6 + vector self-contribution value × 0.4", we estimate 0.824 × 0.6 + 0.462 × 0.4 ≈ 0.494 + 0.185 = 0.679, generating a confidence base value of 0.679.
[0040] Furthermore, the confidence scores of geometric texture vectors of similar injection molded parts are retrieved, the deviation rate between the baseline confidence score and the historical mean of the injection molded part to be tested is estimated to generate a historical deviation correction coefficient, and the vector confidence score correction parameter is obtained by correcting and estimating the baseline confidence score.
[0041] In this embodiment of the invention, by retrieving the confidence scores of geometric texture vectors of injection-molded eyeshadow box lids of the same type from a cloud database, a total of 100 historical records are retrieved. The historical confidence average is estimated to be (0.65 + 0.68 + 0.67 + ... + 0.69) ÷ 100 ≈ 0.67. The baseline confidence score of the injection-molded part to be tested is 0.679. Using the formula "historical deviation correction coefficient = 1 - |baseline confidence score - historical average | ÷ historical average", we estimate that 1 - |0.679 - 0.67| ÷ 0.67 ≈ 1 - 0.013 ≈ 0.987, thus generating a historical deviation correction coefficient of 0.987. Using the formula "vector confidence correction parameter = baseline confidence score × historical deviation correction coefficient", we estimate that 0.679 × 0.987 ≈ 0.670, thus generating a confidence correction parameter of 0.670 for the geometric texture vector of the injection-molded eyeshadow box lid to be tested.
[0042] Furthermore, step S3 includes the following steps: Step S31: Set the recursive trigger threshold for the preliminary defect judgment coefficient. For injection molded parts whose preliminary defect judgment coefficient exceeds the recursive trigger threshold, retrieve their multi-dimensional image dataset and use a sliding window for block processing. Estimate the local defect judgment coefficient of each image block, generate the local defect coefficient matrix of the image block, and initially locate high deviation image blocks as suspected defect candidate areas. In this embodiment of the invention, by setting the recursive trigger threshold for the preliminary defect determination coefficient to 0.2, the preliminary defect determination coefficient of the injection-molded part of the cosmetic lipstick tube shell, 0.2345, exceeds the threshold, and its multi-dimensional image dataset (4 surface images and 24 internal tomographic images) is retrieved. The surface images (2048×2048 pixels) are divided into blocks using a 50×50 pixel sliding window, resulting in 16384 image blocks; the internal tomographic images are divided into 4356 image blocks using a 30×30 pixel sliding window. The local defect determination coefficient of each image block is estimated (e.g., the local coefficient of surface image block (100-149, 200-249) is 0.28, and the local coefficient of block (300-349, 500-549) is 0.15), generating an image block local defect coefficient matrix. Image blocks with a local coefficient > 0.2 were selected. 28 high-deviation image blocks (concentrated in the edge area of the lipstick tube opening) were located in the surface image, and 15 high-deviation image blocks (concentrated in the middle of the tube body) were located in the internal tomographic image. These image blocks were marked as suspected defect candidate areas.
[0043] Step S32: Recursively filter based on the local defect coefficient matrix, expand the window outward from the suspected defect candidate area as the center, estimate the overall defect coefficient of the expanded area, and generate the overall defect coefficient of the expanded area; if the coefficient still exceeds the recursive trigger threshold, the expanded area is included in the suspected defect area, and this recursive process is repeated until the area coefficient is lower than the recursive trigger threshold, thereby determining the complete suspected defect area. In this embodiment of the invention, a suspected defect candidate area is recursively screened based on the local defect coefficient matrix. Taking the suspected defect candidate area (50×50 pixels, local coefficient 0.28) at the edge of the surface image nozzle (as the center), a 70×70 pixel extended area is formed by expanding outwards by 20 pixels. The estimated overall defect coefficient of this extended area is (sum of local coefficients of all image blocks within the area) ÷ number of image blocks = (0.28 + 0.26 + 0.24 + 0.22) ÷ 4 = 0.25, which still exceeds the recursive trigger threshold of 0.2. Therefore, this extended area is included in the suspected defect area. Again, the 70×70 pixel area is expanded outwards by 20 pixels to form a 90×90 pixel area. The estimated overall defect coefficient is (0.25 + 0.23 + 0.21 + 0.19) ÷ 4 = 0.22, which still exceeds the threshold. The expansion continues. The third expansion extends to a 110×110 pixel region. The estimated overall defect coefficient is (0.22+0.20+0.18+0.16)÷4=0.19, which is below the threshold, so the recursion stops. Similarly, the suspected defect candidate regions in the internal tomographic images are processed, ultimately determining a complete suspected defect region of 110×110 pixels at the edge of the pipe opening and 90×90 pixels in the middle of the pipe body.
[0044] Step S33: Extract the feature vector of the suspected defect area, including the flatness deviation, wall thickness mutation value, scratch texture density and bubble texture entropy value, and input it into the pre-trained defect classification model. The model outputs the matching probability of each defect type, and selects the type with the highest probability as the preliminary defect type judgment result. At the same time, estimate the similarity between the feature vector and the standard features of the defect type to generate the type judgment confidence. If it is lower than the set value, trigger manual review to determine the defect type, including missing material, flash, bubbles and cracks. In this embodiment of the invention, feature vectors of suspected defective areas are extracted. The surface pipe edge region has a flatness deviation of 0.04 mm, a wall thickness abrupt change value of 0.15 mm, a scratch texture density of 0.5 lines / mm, and a bubble texture entropy value of 0.3. The central pipe region has a flatness deviation of 0.02 mm, a wall thickness abrupt change value of 0.08 mm, a scratch texture density of 0.1 lines / mm, and a bubble texture entropy value of 0.8. The feature vectors are input into a pre-trained defect classification model. The model outputs a matching probability of 85% for "flash" on the surface region, 10% for "material shortage," and 5% for "crack." For the central pipe region, the matching probability of "bubble" is 90%, "crack" is 8%, and "material shortage" is 2%. The type with the highest probability is selected as the preliminary defect type determination result (surface flash, pipe body bubble). The similarity between the surface region feature vector and the standard feature of "flash" is estimated to be 0.88 (higher than the set value of 0.8), and the similarity between the middle part of the tube and the standard feature of "bubble" is 0.92 (higher than the set value of 0.8). No manual review is required, and the defect types are determined to be flash and bubble.
[0045] Step S34: Estimate the quantitative parameters corresponding to the defect type. For the determined defect area, combine the image calibration ratio to count the pixel area of the defect area, and then compare it with the total pixel area of the corresponding area of the injection molded part to estimate the area ratio corresponding to the defect type. Collect the height data of the defect area through a laser profilometer, estimate the difference between the highest point and the surrounding normal surface to generate the depth value corresponding to the defect type. Establish a coordinate system with the positioning hole of the injection molded part as the origin, and estimate the coordinates of the center point of the defect area to obtain the defect position coordinates. In this embodiment of the invention, by estimating the quantization parameters corresponding to the defect type, the suspected defect area of the surface flash is 110×110 pixels. With an image calibration ratio of 1 pixel = 0.02 mm, the defect area has a pixel area of 12100 pixels, corresponding to an actual area of 12100×(0.02×0.02) = 4.84 mm. 2 The total pixel area corresponding to the lipstick tube opening is 500 × 500 = 250,000 pixels, and the actual total area is 250,000 × 0.0004 = 100 mm. 2 The estimated burr area ratio is 4.84 ÷ 100 = 4.84%. The height data of the burr area is collected using a laser profilometer; the highest point height is 0.3 mm, and the surrounding normal surface height is 0.1 mm, generating a burr depth value of 0.2 mm. A Cartesian coordinate system is established with the bottom positioning hole of the lipstick tube as the origin (coordinates (0,0)). The coordinates of the center point of the burr area (8 mm, 10 mm) and the center point of the bubble area (5 mm, 5 mm) are estimated to obtain the defect location coordinates.
[0046] Step S35: Add the injection part number, mold number, production timestamp, defect type, area ratio, depth value and position coordinates to the parameter table according to the preset format, thereby generating the injection part defect parameter table.
[0047] In this embodiment of the invention, the injection part number (HG001), mold number (M05), production timestamp (2024-06-10 14:30:00), defect type (flash, bubble), area percentage (flash 4.84%, bubble 2.1%), depth value (flash 0.2mm, bubble 0.1mm), and position coordinates (flash (8mm, 10mm), bubble (5mm, 5mm)) of the injection molded part of the cosmetic lipstick tube shell are associated and supplemented into the parameter table according to the preset format of "injection part number - mold number - production time - defect type - area percentage - depth value - position coordinates". Multiple defects of the same injection part are filled in according to the format of "defect type 1 + corresponding parameter | defect type 2 + corresponding parameter", ensuring that each parameter accurately corresponds to the defect type, and finally generating an injection part defect class parameter table containing all defect information.
[0048] Furthermore, step S4 includes the following steps: Step S41: By retrieving the process parameters corresponding to the plastic mold during the production of the injection molded part from the mold process management system, including injection temperature, injection pressure, holding time, injection speed and mold temperature, a process parameter dataset is generated. At the same time, the corresponding defect types are extracted from the defect type parameter table of the injection molded part to construct a defect-process correlation model, with the defect type as the dependent variable and the process parameter as the independent variable. The correlation coefficient between each process parameter and the defect type is estimated through correlation analysis. In this embodiment of the invention, process parameters during the production of the cosmetic blush box base injection molded part (number HG001) are retrieved from the mold process management system. These parameters include injection temperature 210℃, injection pressure 85MPa, holding time 3s, injection speed 65mm / s, and mold temperature 75℃. Simultaneously, process parameters for 100 other injection molded parts from the same batch are retrieved to generate a process parameter dataset. The defect types for this batch are extracted from the injection molded part defect type parameter table. HG001 has flash (area percentage 4.84%) and bubbles (area percentage 2.1%). Of the other 99 parts, 30 have flash, 25 have bubbles, 15 have missing material, and 5 have cracks. A defect-process correlation model is constructed, with the defect type (flash, bubbles, etc.) as the dependent variable and the five process parameters as independent variables. Pearson correlation analysis was used to estimate the correlation coefficients: injection temperature was correlated with flash by 0.72 and with bubbles by 0.68; injection pressure was correlated with flash by 0.65 and with bubbles by 0.52; holding time was correlated with flash by -0.58 (negative correlation) and with bubbles by -0.49; injection speed was correlated with flash by 0.61 and with bubbles by 0.55; mold temperature was correlated with flash by 0.45 and with bubbles by 0.38. The correlation coefficient between each process parameter and defect type was thus determined.
[0049] Step S42: Determine the key process parameters that affect the defect type based on the correlation coefficient, estimate the deviation between the actual value of the key process parameter and the standard process parameter range, and estimate the degree of influence of each key process parameter on the defect type by using the process deviation influence degree = absolute value of correlation coefficient × deviation value; In this embodiment of the invention, the key process parameters affecting the defect type are determined based on the absolute value of the correlation coefficient. For flash defects, the absolute value of the correlation coefficient is ranked as follows: injection temperature (0.72) > injection pressure (0.65) > injection speed (0.61) > holding time (0.58) > mold temperature (0.45). The first three items (injection temperature, injection pressure, and injection speed) are selected as the key process parameters for flash. For bubble defects, the ranking is as follows: injection temperature (0.68) > injection speed (0.55) > injection pressure (0.52) > holding time (0.49) > mold temperature (0.38). The first three items (injection temperature, injection speed, and injection pressure) are selected as the key process parameters for bubbles. The standard process parameter range for this injection molded part is as follows: injection temperature 190-200℃, injection pressure 65-75MPa, and injection speed 45-55mm / s. The estimated deviations between the actual values of the key process parameters and the median values of the standard ranges are: actual injection temperature 210℃, median standard 195℃, deviation +15℃; actual injection pressure 85MPa, median standard 70MPa, deviation +15MPa; actual injection speed 65mm / s, median standard 50mm / s, deviation +15mm / s. The following values were estimated using the formula "Influence of process deviation = Absolute value of correlation coefficient × Deviation value": Injection temperature has an influence of 0.72 × 15 = 10.8 on flash and 0.68 × 15 = 10.2 on bubbles; Injection pressure has an influence of 0.65 × 15 = 9.75 on flash and 0.52 × 15 = 7.8 on bubbles; Injection speed has an influence of 0.61 × 15 = 9.15 on flash and 0.55 × 15 = 8.25 on bubbles.
[0050] Step S43: Based on the impact of process deviations, prioritize the analysis of the process deviation factors that cause the corresponding defect types for the highest process parameters. At the same time, combine historical optimization cases of similar defect types to supplement the direction and range of process parameter adjustments, so as to generate optimization suggestions for injection molded part process defects. In this embodiment of the invention, by ranking the impact of process deviations, the injection temperature (10.8) has the highest impact on flash defects. Analysis of its process deviation factors reveals: checking the heating coil power output, the actual power was found to be 15% higher than the set value, causing the barrel temperature to exceed the limit; checking the raw material melt index, the actual value was 0.5g / 10min higher than the standard value, indicating excessive fluidity and exacerbating flash formation. The injection temperature (10.2) also has the highest impact on bubble defects, with deviation factors including insufficient raw material drying (moisture content 0.15%, standard ≤0.05%) and incomplete air removal from the barrel. Historical optimization cases of similar defects were retrieved: two months ago, a batch of blush box bases developed flash due to excessive injection temperature; after adjusting the temperature to 195℃ and reducing the heating coil power by 10%, the flash occurrence rate decreased by 80%; another batch developed bubbles due to high raw material moisture content; after extending the drying time by 2 hours and increasing the temperature by 5℃, the bubbles disappeared. Based on the case study, determine the direction and scope of process adjustments: reduce the injection temperature from 210℃ to 190-200℃ (preferably 195℃), and reduce the heating coil power by 10%-15%; extend the raw material drying time from 4 hours to 6 hours, and increase the drying temperature from 80℃ to 85℃; reduce the injection pressure from 85MPa to 70-75MPa, and reduce the injection speed from 65mm / s to 50-55mm / s, generating optimization suggestions for injection molded parts process defects.
[0051] Step S44: Link and store the optimization suggestions for injection molding process defects with the corresponding defect detection results, injection molding part number, mold number and production timestamp in the injection molding part defect type parameter table to generate an injection molding defect detection archive.
[0052] In this embodiment of the invention, the optimization suggestions for process defects of the injection molded part of the cosmetic blush box base (such as adjusting the injection temperature to 190-200℃) are associated with the corresponding information in the defect parameter table of the injection molded part, including the injection molded part number HG001, mold number M05, production timestamp 2024-06-10 14:30:00, defect type (flash: area ratio 4.84%, position (8mm, 10mm); bubble: area ratio 2.1%, position (5mm, 5mm)), key process parameter deviation value (injection temperature +15℃, etc.), and the influence of process deviation (injection temperature affects flash by 10.8, etc.). Organize the data according to the preset format of "Injection part number - Mold number - Production time - Defect type and parameters - Key process deviation - Impact - Optimization suggestions", such as "HG001-M05-2024-06-10 14:30:00-Flash (4.84%, (8mm, 10mm)), Bubbles (2.1%, (5mm, 5mm))-Injection temperature +15℃, Injection pressure +15MPa, Injection speed +15mm / s-Injection temperature for flash 10.8, for bubbles 10.2-Adjust injection temperature to 190-200℃, extend raw material drying time to 6 hours", and store this record in the injection molding defect detection archive. At the same time, link the defect and optimization information of other injection parts in the same batch to form a complete archive chain.
[0053] Furthermore, the estimation of the correlation coefficient between each process parameter and the defect type in step S41 includes the following steps: The process parameter dataset is standardized to map process parameters with different dimensions such as injection temperature, injection pressure, holding time, injection speed and mold temperature to the same numerical range [0,1], thus obtaining a standardized process parameter set; the defect types in the injection part defect type parameter table are encoded, including missing material as 1, flash as 2, bubbles as 3 and cracks as 4, and the area ratio is used as the defect severity index, which is integrated with the encoded defect type into a defect feature vector; In this embodiment of the invention, five process parameters are extracted from the process parameter dataset (containing 100 sets of production data) for the injection molding process of cosmetic blush box base: injection temperature (range 180-220℃), injection pressure (range 50-90MPa), holding time (range 2-6s), injection speed (range 30-70mm / s), and mold temperature (range 40-80℃). The min-max standardization method is used to map the parameters of different dimensions to the [0,1] interval. The standardization formula is "Standardized value = (actual value - minimum value) ÷ (maximum value - minimum value)". For example, in a certain set of data, the injection temperature is 200℃, the standardized value = (200-180) ÷ (220-180) = 0.5; the injection pressure is 70MPa, the standardized value = (70-50) ÷ (90-50) = 0.5; the holding time is 4s, the standardized value = (4-2) ÷ (6-2) = 0.5; the injection speed is 50mm / s, the standardized value = (50-30) ÷ (70-30) = 0.5; the mold temperature is 60℃, the standardized value = (60-40) ÷ (80-40) = 0.5. By processing all the data in this way, a standardized set of process parameters is obtained. The defect types in the defect parameter table of injection molded parts are coded as follows: missing material code 1, flash code 2, bubble code 3, and crack code 4. The defect area ratio is extracted as a severity indicator (e.g., flash area ratio of 4.84% and bubble area ratio of 2.1%). The coded defect types and area ratios are integrated into a defect feature vector. For example, the defect feature vector of the blush box base containing flash and bubbles is [2, 4.84%; 3, 2.1%].
[0054] Furthermore, Pearson correlation analysis was used to estimate the correlation coefficient between each process parameter in the standardized process parameter set and each dimension in the defect feature vector, resulting in a preliminary correlation coefficient matrix. In this embodiment of the invention, Pearson correlation analysis is used to estimate the correlation coefficients between the standardized process parameter set and each dimension of the defect feature vector. Taking standardized injection temperature (0-1) and flash defects (code 2, area percentage 4.84%) as examples, 50 sets of production data containing flash defects are selected, and the product of their covariance and standard deviation is estimated. The correlation coefficient obtained by the Pearson correlation coefficient formula is 0.72. The correlation coefficient between standardized injection pressure and flash defects is estimated to be 0.65; the correlation coefficient between standardized holding time and flash defects is estimated to be -0.58 (a negative correlation indicates that the longer the holding time, the lighter the flash); the correlation coefficient between standardized injection speed and flash defects is estimated to be 0.61; and the correlation coefficient between standardized mold temperature and flash defects is estimated to be 0.45. Similarly, the correlation coefficients between each process parameter and bubble defects (code 3, area percentage 2.1%) were estimated as follows: injection temperature 0.68, injection pressure 0.52, holding time -0.49, injection speed 0.55, mold temperature 0.38; the correlation coefficients with material shortage (code 1) were: injection temperature -0.63, injection pressure -0.71, holding time 0.65, injection speed -0.59, mold temperature -0.42; and the correlation coefficients with cracks (code 4) were: injection temperature 0.58, injection pressure 0.62, holding time -0.51, injection speed 0.53, mold temperature 0.48. These were then used to obtain a preliminary correlation coefficient matrix.
[0055] Furthermore, all defect detection records of the plastic mold in a recent period are obtained, and the occurrence frequency of each defect is counted according to defect type to estimate the occurrence frequency of each defect. Based on the occurrence frequency of each defect, a corresponding defect frequency weight table is generated, and the preliminary correlation coefficient between each defect type and the corresponding process parameter is extracted from the preliminary correlation coefficient matrix. The weight value corresponding to the defect type is matched according to the defect frequency weight table, and the corrected correlation coefficient of the correspondence between each defect and process parameter is estimated by corrected correlation coefficient = preliminary correlation coefficient × weight value. In this embodiment of the invention, by acquiring all defect detection records of the plastic mold for the base of the cosmetic blush box over the past 30 days, totaling 500 records, and counting the occurrence times by defect type: material shortage 80 times, flash 150 times, bubbles 120 times, and cracks 50 times, the occurrence frequency of each defect was estimated as follows: occurrence frequency = occurrence times ÷ total number of records. The frequency of material shortage was 0.16, flash 0.3, bubbles 0.24, and cracks 0.1. A defect frequency weight table was generated (weight = frequency ÷ highest frequency, with flash being the highest frequency at 0.3). The weights for material shortage, flash, and bubbles were 0.16 ÷ 0.3 ≈ 0.53, 0.24 ÷ 0.3 ≈ 0.8, and 0.1 ÷ 0.3 ≈ 0.33. The preliminary correlation coefficients between each defect type and its corresponding process parameter are extracted from the preliminary correlation coefficient matrix. For example, the preliminary correlation coefficient between flash and injection temperature is 0.72, with a matching flash weight of 1.0, and the estimated corrected correlation coefficient is 0.72 × 1.0 = 0.72; the preliminary correlation coefficient between bubbles and injection temperature is 0.68, with a matching bubble weight of 0.8, and the corrected correlation coefficient is 0.68 × 0.8 = 0.54; the preliminary correlation coefficient between shortness of material and injection pressure is -0.71, with a matching shortness of material weight of 0.53, and the corrected correlation coefficient is -0.71 × 0.53 ≈ -0.376; the preliminary correlation coefficient between cracks and injection pressure is 0.62, with a matching crack weight of 0.33, and the corrected correlation coefficient is 0.62 × 0.33 ≈ 0.205. Based on this, the corrected correlation coefficients for all defect-process parameter correspondences are estimated.
[0056] Furthermore, the corrected correlation coefficients are categorized and organized according to defect type and process parameters to generate a corrected correlation coefficient matrix. A significance test is then performed to remove invalid weak correlation coefficients and retain the significantly related correspondence between process parameters and defect types, thereby generating the correlation coefficient between each process parameter and defect type.
[0057] In this embodiment of the invention, all corrected correlation coefficients are categorized and organized according to "defect type - process parameter" to generate a corrected correlation coefficient matrix. The matrix rows represent defect types (shortage, flash, bubbles, cracks), and the columns represent process parameters (injection temperature, injection pressure, holding time, injection speed, mold temperature). The corresponding corrected correlation coefficient is entered into each cell. A t-test is used to test significance, with a significance level of 0.05. The t-value for each corrected correlation coefficient is estimated. If the t-value > 1.96 (the critical value when n-2 = 48 degrees of freedom), it is considered a significant correlation; otherwise, it is considered an invalid weak correlation. For example, the corrected correlation coefficient between material shortage and injection pressure is -0.376, and the estimated t-value is -3.2 (absolute value > 1.96), so it is retained; the corrected correlation coefficient between cracks and injection pressure is 0.205, and the estimated t-value is 1.5 (< 1.96), so it is discarded; the corrected correlation coefficient between bubbles and mold temperature is 0.38 × 0.8 = 0.304, and the estimated t-value is 2.1 (> 1.96), so it is retained; the corrected correlation coefficient between material shortage and mold temperature is -0.42 × 0.53 ≈ -0.222, and the estimated t-value is 1.6 (< 1.96), so it is discarded. After removing ineffective weak correlation coefficients through significance testing, the correspondence between significantly correlated process parameters and defect types is retained, and finally, the correlation coefficient between each process parameter and defect type is generated (e.g., injection temperature and flash 0.72, and with bubbles 0.54; injection pressure and flash 0.65, and with material shortage -0.376, etc.).
[0058] Furthermore, the present invention also provides a plastic mold injection defect detection system, including a processor, a memory, and a computer program stored in the memory and executable on the processor, for performing the plastic mold injection defect detection method as described above.
[0059] The above description is merely an embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of the present invention should be included within the scope of the claims of the present invention.
Claims
1. A method for detecting injection molding defects in a plastic mold, the method comprising: The method comprises the following steps: Step S1: Collecting the surface image and internal tomographic image of the plastic mold injection part through a multi-view industrial camera array, and performing denoising, grayscale processing and image alignment; meanwhile, establishing a mold number-view-image corresponding association index according to the mold cavity number of the plastic mold injection part and the collection view angle, and generating a multi-dimensional image data set corresponding to each injection part; Step S2: Extracting the geometric features including surface flatness, wall thickness uniformity and cavity filling completeness, and the texture features including surface scratch texture and bubble distribution texture from the multi-dimensional image data set corresponding to each injection part, and fusing to generate a geometric texture vector corresponding to each injection part; based on the geometric texture vector corresponding to each injection part and the pre-set defect-free injection part feature template, a similarity determination estimation is performed to generate a defect preliminary determination coefficient corresponding to each injection part; Step S3: Based on the defect preliminary determination coefficient corresponding to each injection part, the suspected defect area of each injection part is determined recursively, and the injection part defect type corresponding to each suspected area is identified and determined, and the area ratio, depth value and position coordinates corresponding to each defect type are estimated to generate an injection part defect parameter table; Step S4: Based on the defect type and parameters in the injection part defect parameter table, and combined with the process parameters of the plastic mold, a defect-process association model is constructed to analyze the process deviation factors leading to the defect type, to generate an injection part process defect optimization suggestion, and to generate an injection defect detection archive in association with the injection part defect parameter table.
2. The method of claim 1, wherein Step S1 comprises the following steps: Step S11: Deploying a multi-view industrial camera array, including surface shooting cameras and tomographic scanning cameras, and setting camera acquisition parameters including exposure time, resolution and shooting angle, and synchronously triggering image acquisition according to the production rhythm of the plastic mold injection part, to obtain the surface image and internal tomographic image of each injection part at different views, and generate a raw image set corresponding to each injection part; Step S12: Gaussian filter denoising is performed on the surface image in the raw image set to eliminate noise points caused by environmental light interference, and edge enhancement is performed on the internal tomographic image to highlight the outline of the internal defect, to obtain a pre-processed image set corresponding to each injection part; Step S13: Grayscale processing is performed on the pre-processed image set corresponding to each injection part to generate a grayscale image set corresponding to each injection part; Step S14: Obtain the reference feature points of the surface image and internal tomographic image in the grayscale image set corresponding to each injection part, and perform geometric alignment on the surface image and internal tomographic image corresponding to different views based on the reference feature points, to ensure the coordinate uniformity of the multi-view images of the same injection part, to generate a reference image set corresponding to each injection part; Step S15: Obtain the mold cavity number corresponding to the plastic mold injection part, and establish the association index of the mold number-view angle-image corresponding to the corresponding shooting angle, and index integration is performed on the reference image set corresponding to each injection part based on the association index of the mold number-view angle-image, to generate a multi-dimensional image data set corresponding to each injection part.
3. The method of claim 1, wherein Step S2 includes the following steps: Step S21: Obtain the injection part surface contour point cloud data for each injection part corresponding surface image, and estimate the Euclidean distance mean value between the contour points and the standard contour to generate the surface contour deviation mean value; obtain the elastic deformation threshold value corresponding to the material of the injection part, and generate the surface flatness corresponding to each injection part based on the ratio between the surface contour deviation mean value and the elastic deformation threshold value; Step S22: Divide the internal tomographic image corresponding to each injection part into a wall thickness region, a cavity filling region and an edge region, and according to the image calibration scale, the minimum wall thickness, the maximum wall thickness and the average wall thickness corresponding to the wall thickness region are counted by depth layer, and the wall thickness uniformity is generated based on the wall thickness uniformity = 1-(maximum wall thickness-minimum wall thickness) / average wall thickness; the pixel ratio of the cavity filling region is counted by depth layer to generate the cavity filling pixel rate, and the edge region filling defect coefficient is obtained according to the edge region, and the cavity filling degree is estimated based on the cavity filling pixel rate and the edge region filling defect coefficient; Step S23: Divide each pixel window for the surface image, and estimate the contrast, correlation and energy value of the pixels in the window using the gray level co-occurrence matrix, select the pixel window area with a contrast higher than the threshold value as the suspected scratch area, and generate the surface scratch texture based on the correlation and energy value of the area to count the texture direction consistency of the area; Step S24: Fuse the geometric features including surface flatness, wall thickness uniformity and cavity filling degree with the texture features including surface scratch texture and bubble distribution texture to generate a geometric texture vector corresponding to each injection part. Step S25: Estimate the defect preliminary judgment coefficient corresponding to each injection part based on the geometric texture vector corresponding to each injection part and the preset defect-free injection part feature template.
4. The method of claim 3, wherein the step of detecting the injection molding defect is performed by using a camera. The edge region filling defect coefficient corresponding to the edge region in step S22 includes the following steps: According to the edge region, the Sobel operator is used to extract the contour pixel points corresponding to the edge region, and the edge contour coordinate set is constructed, and the mold cavity design parameters corresponding to the edge region are associated, including the edge standard width and the curvature radius, to generate the edge region basic data set; Based on the edge region basic data set and combined with the image calibration scale, the actual geometric deviation rate of the edge is estimated; Extract the filling state data corresponding to the edge region, and perform binaryzation processing on the edge region based on the filling state data, wherein the filled region is 1 and the unfilled region is 0, and the number of unfilled pixels in the edge region is counted to generate the edge unfilled pixel ratio, and the number of connected regions and the area average of the unfilled region are analyzed; estimate the edge filling defect dispersion based on the edge unfilled pixel ratio, the number of connected regions and the area average; Based on the actual geometric deviation rate of the edge and the normalized and weighted estimation of the edge unfilled pixel ratio, the corresponding edge filling basic defect value is obtained, and based on the edge filling defect dispersion and the edge filling basic defect value, the edge area filling defect coefficient is estimated by the edge area filling defect coefficient = edge filling basic defect value × (1 + edge filling defect dispersion) to generate the corresponding edge area filling defect coefficient.
5. The method of claim 3, wherein the step of detecting the injection molding defect is performed by using a machine vision system. Step S25 includes the following steps: Step S251: retrieve the preset defect-free injection molded part feature template, which includes the standard geometric feature vector in the defect-free state, including surface flatness, wall thickness uniformity and cavity filling completeness, and the standard texture feature vector, including surface scratch texture and bubble distribution texture, while extracting the corresponding geometric texture vector of the injection molded part to be detected, and constructing the detected vector-standard vector comparison data set; Step S252: estimate the dimension similarity for each dimension in the detected vector-standard vector comparison data set using cosine similarity, and calculate the mean and standard deviation of each dimension similarity in a certain test time region to generate the dimension similarity mean and dimension similarity dispersion value; Step S253: take the dimension similarity mean as the basis similarity, and correct and estimate it by combining the dimension similarity dispersion value to estimate the vector overall similarity between the detected vector and the standard vector by vector overall similarity = ∑ dimension similarity mean × (1-dimension similarity dispersion value); Step S254: obtain the corresponding vector confidence correction parameter based on the corresponding geometric texture vector of the injection molded part to be detected; Step S255: estimate the defect preliminary judgment coefficient corresponding to each injection molded part based on the vector confidence correction parameter and the vector overall similarity between the detected vector and the standard vector, which is specifically defect preliminary judgment coefficient = (1-vector overall similarity) × vector confidence correction parameter.
6. The method of claim 5, wherein: Step S254 includes the following steps: Based on the corresponding geometric texture vector of the injection molded part to be detected, the corresponding generated source data is obtained, including the acquisition device parameter data and the image processing output data, and a vector-source data association table is constructed to clearly show the correspondence between the geometric texture vector and the data of each generation link; Based on the vector-source data association table, estimate the source data quality parameter to estimate the device parameter deviation coefficient based on the acquisition device parameter data; analyze the detail retention rate of the denoised image and the contour accuracy after edge enhancement based on the image processing output data and generate a preprocessing effect score; Estimating the intrinsic stability parameter of the geometric texture vector, performing consistency test on the geometric feature dimension and the texture feature dimension in the geometric texture vector respectively, and generating the vector dimension fluctuation degree by counting the fluctuation amplitude of each dimension data, and estimating the correlation between the dimensions of the vector to generate the dimension correlation coefficient; Based on the source data quality parameter and the intrinsic stability parameter, a confidence base value is generated to normalize the device parameter deviation coefficient and the pre-processing effect score, estimate the source data contribution value, and combine the vector dimension fluctuation degree and the dimension correlation coefficient to estimate the vector contribution value, and then the two contribution values are weighted and summed to obtain the confidence base value; Retrieve the geometric texture vector confidence record of the same type of injection molded part, estimate the deviation rate of the corresponding confidence base value and the historical average value of the injection molded part to be detected to generate the historical deviation correction coefficient, and correct the confidence base value to estimate the vector confidence correction parameter.
7. The method of claim 1, wherein Step S3 includes the following steps: Step S31: Set the recursive trigger threshold of the defect preliminary judgment coefficient, retrieve the multi-dimensional image data set of the injection molded part whose defect preliminary judgment coefficient exceeds the recursive trigger threshold, and perform block processing using a sliding window to estimate the local defect judgment coefficient of each image block, generate an image block local defect coefficient matrix, and preliminarily locate the high-deviation image block as a suspected defect candidate area; Step S32: Based on the local defect coefficient matrix, recursively screen the suspected defect candidate area as the center to expand the window outward, estimate the overall defect coefficient of the expanded area to generate an expanded area overall defect coefficient; if the coefficient still exceeds the recursive trigger threshold, the expanded area is included in the suspected defect area, and the recursive process is repeated until the area coefficient is below the recursive trigger threshold, thereby determining the complete suspected defect area; Step S33: Extract the feature vector of the suspected defect area, including the area flatness deviation, wall thickness mutation value, scratch texture density and bubble texture entropy value, input into the pre-trained defect classification model, the model outputs the matching probability of each defect type, and selects the type with the highest probability as the preliminary judgment result of the defect type; At the same time, estimate the similarity between the feature vector and the standard feature of the defect type to generate the type judgment confidence, if it is lower than the set value, trigger manual review, thereby determining the defect type, including lack of material, flash, bubble and crack; Step S34: Estimate the quantitative parameter corresponding to the defect type, for the determined defect area, combine the image calibration scale to count the pixel area of the defect area, and then compare it with the total pixel area of the corresponding area of the injection molded part to estimate the area ratio corresponding to the defect type; Collect the height data of the defect area by laser profiler to estimate the difference between the highest point and the surrounding normal surface to generate the depth value corresponding to the defect type; Establish a coordinate system with the positioning hole of the injection molded part as the origin to obtain the defect position coordinates by estimating the center point coordinates of the defect area; Step S35: Associate and supplement the injection molded part number, mold number, production timestamp, defect type, area ratio, depth value and position coordinates to the parameter table in the preset format, thereby generating the injection molded part defect parameter table.
8. The method of claim 1, wherein: Step S4 includes the following steps: Step S41: By calling the corresponding process parameters of the plastic mold during the production of the injection molded part from the mold process management system, including injection temperature, injection pressure, holding time, injection speed and mold temperature, a process parameter dataset is generated, and a defect-process correlation model is constructed by extracting the corresponding defect types from the injection molded part defect type parameter table, taking the defect type as the dependent variable and the process parameter as the independent variable, and estimating the correlation coefficient of each process parameter and defect type through correlation analysis; Step S42: Based on the correlation coefficient, determine the key process parameters that affect the defect type, and estimate the deviation value of the actual value of the key process parameter from the standard process parameter range, and estimate the influence degree of each key process parameter on the defect type through process deviation influence degree=absolute value of correlation coefficient x deviation value; Step S43: According to the process deviation influence degree, the highest process parameter is analyzed to cause the corresponding defect type process deviation factor, and the direction and range of process parameter adjustment are supplemented by combining the historical optimization cases of similar defect types to generate injection molded part process defect optimization suggestions; Step S44: The injection molded part process defect optimization suggestions are stored in association with the corresponding defect detection results, injection molded part number, mold number and production time stamp in the injection molded part defect type parameter table to generate an injection defect detection archive.
9. The method of claim 8, wherein: The estimation of the correlation coefficient of each process parameter and defect type in step S41 includes the following steps: Standardize the process parameter dataset to map the different dimension process parameters of injection temperature, injection pressure, holding time, injection speed and mold temperature to the same value interval [0, 1] to obtain a standardized process parameter set; encode the defect types in the injection molded part defect type parameter table, including 1 for lack of material, 2 for flash, 3 for bubble and 4 for crack, and take the area ratio as the defect severity index, and integrate it with the coded defect type as a defect feature vector; Use Pearson correlation analysis to estimate the correlation coefficient between each process parameter in the standardized process parameter set and each dimension in the defect feature vector to obtain a preliminary correlation coefficient matrix; Get all defect detection records of the plastic mold in a period of time and count the occurrence frequency of each defect based on the defect type; generate a defect frequency weight table based on the occurrence frequency of each defect, and extract the preliminary correlation coefficient of each defect type and the corresponding process parameter from the preliminary correlation coefficient matrix, match the weight value corresponding to the defect type according to the defect frequency weight table, and estimate the revised correlation coefficient of each defect-process parameter correspondence through revised correlation coefficient=preliminary correlation coefficient x weight value; Classify and organize the revised correlation coefficient by defect type and process parameter to generate a revised correlation coefficient matrix, and perform significance test to eliminate invalid weak correlation coefficients and retain significant correlation between process parameters and defect types, thereby generating the correlation coefficient of each process parameter and defect type.
10. A plastic mold injection defect detection system, characterized in that, A computer program product comprising a processor, a memory, and a computer program stored on the memory and loadable on the processor for carrying out the method for detecting injection defects in a plastic mold according to any one of claims 1 to 9.
Citation Information
Cited By
Injection molding process data processing method and system, storage medium and program product
CN121765606A
Method and system for detecting surface roughness of automobile injection molded part
CN121883486A