Compensation detection method, device and related equipment based on 3D printing equipment
By using the shooting component and preset training model in the 3D printing device to adjust the extrusion parameters of the nozzle component, the problem of low printing quality is solved, the printing quality and user experience are improved, and the needs of different scenarios are met.
Patent Information
- Application Number
- CN202410546849.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-30
- Publication Date
- 2025-09-23
- Estimated Expiration
- 2044-04-30
AI Technical Summary
The printing quality of existing 3D printing equipment is low, resulting in a poor user experience.
By using a shooting component in a 3D printing device to capture image data of the initial pattern and using a preset training model to process the image data, a compensation value is determined based on the output results of the training model to adjust the extrusion parameters of the nozzle assembly to improve printing quality.
It improves the printing quality and user experience of 3D printing equipment, is suitable for different application scenarios, and avoids the problem of inaccurate compensation values caused by material differences and laser radar scanning blind spots.
Smart Images

Figure CN118322570B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of 3D printing technology, and in particular to a compensation detection method, device and related equipment based on 3D printing equipment. Background Art
[0002] With the rise of concepts like intelligent manufacturing, 3D printing technology is becoming increasingly widespread. 3D printing, first appearing in the mid-1990s, is essentially a state-of-the-art rapid prototyping device utilizing technologies like photocuring and paper lamination. It operates on essentially the same principle as conventional printing: a printer is filled with "printing material" such as liquid or powder. Once connected to a computer, the computer controls the process of stacking the "printing material" layer by layer, ultimately transforming the blueprint on the computer into a physical object. This printing technology is known as 3D printing.
[0003] In the related art, the printing quality of 3D printing equipment is low, resulting in the printed 3D models being difficult to meet user requirements, which in turn leads to a poor user experience. Summary of the Invention
[0004] In view of this, the present application provides a compensation detection method, apparatus and related equipment based on a 3D printing device, which can improve the printing quality of the 3D printing device and thus enhance the user experience.
[0005] The first aspect of the present application provides a compensation detection method based on a 3D printing device, wherein the 3D printing device includes a shooting component, a nozzle component and a printing platform, and the nozzle component is used to extrude printing material onto the printing platform. The method includes: controlling the nozzle component to print an initial pattern on the printing platform according to preset extrusion parameters; controlling the shooting component to shoot image data of the initial pattern, and inputting the image data into a preset training model; wherein the training data used to train the preset training model includes historical image data of historical patterns printed by the 3D printing device, and the historical image data includes annotation data, and the annotation data is used to characterize the corner position and corner uniformity in the historical pattern, and the preset training model is obtained by a model training method of classifying the corner position and the corner uniformity and then regressing; determining the compensation value of the preset extrusion parameter according to the output result of the preset training model, and controlling the nozzle component to print the final pattern on the printing platform according to the compensation value.
[0006] Compared with the related art, the embodiments of the present application have at least the following advantages:
[0007] By using historical image data to train a preset training model, since the historical image data includes annotation data for characterizing the corner positions and corner uniformity in historical patterns, and the model training method of the preset training model is to classify the corner positions and corner uniformity and then regress, the accuracy of the model prediction can be improved, so that the compensation value determined based on the output result of the preset training model can accurately compensate for the preset extrusion parameters, thereby making the final pattern printed by the 3D printing device meet the printing quality requirements, improving the printing quality of the 3D printing device, and thus improving the user experience; in addition, by inputting the image data of the initial pattern into the preset training model to obtain the compensation value, the 3D printing device can be adapted to different application scenarios, avoiding the situation where "when obtaining the compensation value of the preset extrusion parameter through the laser radar, printing materials of different materials will affect the scanning results of the laser radar, and the laser radar has a scanning blind spot, resulting in inaccurate compensation value". This ensures the printing quality of the 3D printing device in different scenarios and further improves the user experience.
[0008] In some possible implementations, the historical pattern includes multiple corners, and the annotation data includes at least the position information and weight value of each corner, and the weight value is used to characterize the corner uniformity corresponding to the corner, wherein the larger the weight value, the more the corner uniformity corresponding to the corner meets the preset uniformity requirement; the head network of the preset training model is a multi-branch classification regression network, and the multi-branch classification regression network includes at least a first branch and a second branch. The preset training model is trained in the following manner: the position information is input into the first branch to obtain the first output value of the first branch; the weight value is input into the second branch to obtain the second output value of the second branch; the first output value and the second output value are regressed to train the preset training model according to the regression result; wherein the second output value uses an attention mechanism when regressing.
[0009] By adopting this technical solution, the ability to acquire pattern detail features can be improved during the model training process, thereby further improving the accuracy of the preset training model.
[0010] In some possible implementations, after regressing the output results of the first branch and the output results of the second branch, the preset training model outputs predicted annotation data of the historical image data; training the preset training model based on the regression results includes: calculating the loss value of the loss function corresponding to the preset training model based on the annotation data and the predicted annotation data; iteratively updating the bias parameters of the preset training model through the backpropagation algorithm and the loss gradient of the loss function to reduce the loss value to meet the preset accuracy requirements; and using the bias parameters corresponding to the final loss value as the final bias parameters of the preset training model.
[0011] By adopting this technical solution, the bias parameters of the preset training model can be optimized, thereby further improving the accuracy of the preset training model.
[0012] In some possible implementations, the historical pattern includes multiple corners, and after regressing the first output value and the second output value, each of the corners corresponds to an initial predicted labeling data; the preset training model outputs the predicted labeling data in the following manner: fitting a Gaussian function to multiple initial predicted labeling data, and taking the initial predicted labeling data corresponding to the maximum value of the Gaussian function as the predicted labeling data.
[0013] By adopting this technical solution, the accuracy and stability of the preset training model can be improved.
[0014] In some possible implementations, the annotation data also includes category information of each of the fold corners, wherein the category information is used to characterize the amount of printing material corresponding to the fold corner; the multi-branch classification regression network also includes a third branch, and the preset training model is trained in the following manner: inputting the category information into the third branch to obtain a third output value of the third branch; regressing the first output value, the second output value, and the third output value to train the preset training model based on the regression results; wherein the second output value uses an attention mechanism when regressing.
[0015] In some possible implementations, the backbone network of the preset training model is a CSP structure, and the intermediate network layer of the preset training model is an SPPF structure or a PAN structure.
[0016] In some possible implementations, the historical image data includes multiple broken lines, each broken line includes at least one broken angle, and each broken angle corresponds to one of the annotation data.
[0017] The second aspect of the present application discloses a compensation detection device based on a 3D printing device, wherein the 3D printing device includes a shooting component, a nozzle component and a printing platform, wherein the nozzle component is used to extrude printing material onto the printing platform, and the device includes: a control module and a preset training model; the control module is used to control the nozzle component to print an initial pattern on the printing platform according to preset extrusion parameters, and the control module is also used to control the shooting component to capture image data of the initial pattern and input the image data into the preset training model; the preset training model is used to output compensation values of the preset extrusion parameters according to the image data, wherein the training data used to train the preset training model includes historical image data of historical patterns printed by the 3D printing device, the historical image data includes annotation data, and the annotation data is used to characterize the corner positions and corner uniformity in the historical patterns, and the preset training model is obtained by a model training method of classifying the corner positions and the corner uniformity and then regressing; the control module is also used to control the nozzle component to print a final pattern on the printing platform according to the compensation value.
[0018] A third aspect of the present application discloses an electronic device, comprising a processor and a memory, wherein the memory is used to store instructions, and the processor is used to call the instructions in the memory so that the electronic device executes the above-mentioned compensation detection method based on a 3D printing device.
[0019] In a fourth aspect, the present application discloses a storage medium including computer instructions. When the computer instructions are executed on an electronic device, the electronic device executes the above-mentioned compensation detection method based on a 3D printing device.
[0020] It can be understood that the compensation detection device based on the 3D printing device of the second aspect provided above, the electronic device of the third aspect, and the storage medium of the fourth aspect all correspond to the method of the first aspect mentioned above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects of the corresponding methods provided above, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without paying any creative work.
[0022] Figure 1 This is a flowchart of a compensation detection method based on a 3D printing device provided in one embodiment of the present application.
[0023] Figure 2 This is a flowchart of a compensation detection method based on a 3D printing device provided in one embodiment of the present application.
[0024] Figure 3 A schematic diagram of the functional modules of a compensation detection device based on a 3D printing device provided in one embodiment of the present application.
[0025] Figure 4 This is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present application. DETAILED DESCRIPTION
[0026] In order to more clearly understand the above-mentioned objectives, features and advantages of the present application, the present application is described in detail below in conjunction with the accompanying drawings and specific embodiments. It should be noted that the embodiments of the present application and the features therein can be combined with each other in the absence of conflict.
[0027] In the following description, many specific details are set forth to facilitate a full understanding of the present application. The described embodiments are only part of the embodiments of the present application, rather than all of the embodiments.
[0028] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application pertains. The terms used herein in the specification of this application are only for the purpose of describing specific embodiments and are not intended to limit this application.
[0029] It should be further noted that, in this document, the terms "comprises," "includes," or any other variations thereof are intended to encompass non-exclusive inclusion, such that a process, method, article, or apparatus comprising a list of elements includes not only those elements but also other elements not explicitly listed, or elements inherent to such process, method, article, or apparatus. In the absence of further limitations, an element defined by the phrase "comprising a ..." does not preclude the presence of other identical elements in the process, method, article, or apparatus comprising the element.
[0030] In this application, "at least one" means one or more, and "more than one" means two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A exists alone, A and B exist simultaneously, and B exists alone. A and B can be singular or plural.
[0031] In the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be interpreted as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner.
[0032] To facilitate understanding, some illustrations of concepts related to the embodiments of the present application are given for reference.
[0033] 3D printing equipment, also known as three-dimensional printers or stereo printers, is a rapid prototyping process that typically uses digital printing technology to create materials. 3D printing equipment is often used to create models or parts in fields such as mold manufacturing and industrial design.
[0034] Please refer to Figure 1 , which is a flow chart of a compensation detection method based on a 3D printing device provided in one embodiment of the present application. This embodiment is applied to a 3D printing device, which includes a camera assembly, a nozzle assembly, and a printing platform. The nozzle assembly is used to extrude printing material onto the printing platform, including the following steps:
[0035] Step 101: Control the nozzle assembly to print an initial pattern on a printing platform according to preset extrusion parameters.
[0036] In some embodiments, the initial pattern may include multiple broken lines, straight lines, and curved lines, etc. This embodiment does not specifically limit the shape of the initial pattern.
[0037] In some embodiments, the 3D printing device receives preset slicing parameters and printing material parameters of the 3D model, and obtains preset extrusion parameters according to the preset slicing parameters and printing material parameters.
[0038] In some embodiments, the 3D printing device is communicatively connected to the 3D printing slicing software, or the 3D printing device is provided with the 3D printing slicing software. Before controlling the nozzle assembly to print the initial pattern, the 3D printing slicing software receives preset slicing parameters and printing material parameters of the 3D model to be printed input by the user. The 3D printing slicing software obtains preset extrusion parameter values based on the preset slicing parameters and printing material parameters. The 3D printing device controls the nozzle assembly to print the initial pattern on the printing platform based on the preset extrusion parameter values.
[0039] Specifically, the preset slicing parameters include, but are not limited to, temperature, layer height, speed, support, and retraction. Temperature refers to the nozzle temperature. When the 3D printing device has a heated bed, the temperature also includes the temperature of the heated bed. Layer height refers to the height of each layer of the 3D model to be printed. The smaller the layer height, the more layers are required for the entire print. Speed generally refers to the movement speed of the print head, and can also include the printing material filling speed, wall speed, etc. Support is the structure that supports the overhanging features on the 3D model to be printed. Retraction includes retraction distance and retraction speed. Retraction determines the amount and speed of the filament being sucked back into the nozzle to prevent material from seeping out before extrusion.
[0040] In some embodiments, printing material parameters include but are not limited to: material type, required quantity, etc.
[0041] In some embodiments, the printing platform includes a formal printing area and an informal printing area, and the 3D printing device controls the nozzle assembly to print an initial pattern in the informal printing area according to preset extrusion parameters.
[0042] In some embodiments, the relative positional relationship between the formal printing area and the informal printing area is not specifically limited. For example, the central area of the printing platform can be used as the formal printing area, and the peripheral area surrounding the central area can be used as the informal printing area. Other areas of the printing platform can also be used as the formal printing area according to actual needs. These will not be detailed here.
[0043] It is understandable that in the subsequent steps, the final pattern is printed in the formal printing area. In this way, the printing of the initial pattern for testing the preset extrusion parameters does not affect the subsequent printing of the final pattern, thereby improving the printing efficiency of the 3D printing device.
[0044] Step 102: Control the shooting component to shoot image data of the initial pattern, and input the image data into a preset training model.
[0045] In some embodiments, the training data used to train the preset training model includes historical image data of historical patterns printed by a 3D printing device, and the historical image data includes annotation data, which is used to characterize the corner positions and corner uniformity in the historical patterns. The preset training model is obtained by a model training method that classifies the corner positions and corner uniformity and then regresses them.
[0046] Specifically, the historical image data corresponding to the historical pattern includes multiple corners, and the annotation data includes the position information and weight value of each corner. The weight value is used to characterize the corner uniformity corresponding to the corner. Among them, the larger the weight value, the more the corner uniformity corresponding to the corner meets the preset uniformity requirements.
[0047] For ease of understanding, the following describes in detail how to set the annotation data in this embodiment:
[0048] Assume that the historical pattern includes three corners, namely corners 1 to 3, which correspond to annotation data A to annotation data C, respectively. Taking corner 1 and annotation data A as an example, annotation data A includes the position information and weight value of corner 1. The position information can be obtained in the following way: draw a border that only includes corner 1 and excludes other corners, and use the center point coordinates, length, and width of the border as the position information of corner 1; determine the amount of printing material at corner 1. If the amount of printing material at corner 1 is moderate, that is, the angle uniformity of corner 1 meets the preset uniformity requirements, then the weight value is set to a larger value. If the amount of printing material at corner 1 is large or small, that is, the angle uniformity of corner 1 does not meet the preset uniformity requirements, then the weight value is set to a smaller value. For example, taking the highest weight value as 1 as an example, when the amount of printing material at corner 1 is moderate, the weight value of the annotation data A is set between 0.9 and 1; when the amount of printing material at corner 1 is more or less, the weight value of the annotation data A is set below 0.5. The lower the weight value, the more or less the amount of printing material at corner 1 is.
[0049] The setting method of the annotation data B and the annotation data C is similar to the setting method of the annotation data A. In order to avoid repetition, it will not be repeated here.
[0050] In some embodiments, the annotation data further includes category information for each fold, where the category information is used to characterize the amount of printing material corresponding to the fold. For example, the category information includes "high material," "low material," and "moderate," and the fold is categorized based on the amount of printing material used at each fold.
[0051] In some embodiments, the backbone network of the preset training model is a CSP structure, and the neck network of the preset training model is an SPPF structure or a PAN structure.
[0052] Specifically, the CSP structure improves the performance of deep neural networks by splitting input features into two parts and then cross-connecting them. In this embodiment, by setting the backbone network of the preset training model to a CSP structure, the input annotation data can be divided into two parts: location information and weight values, thereby improving the performance of the subsequent preset training model.
[0053] It should be noted that the training method of the preset training model in this application is described in detail in subsequent embodiments. In order to avoid repetition, it will not be repeated here.
[0054] Step 103: Determine the compensation value of the preset extrusion parameter according to the output result of the preset training model, and control the nozzle assembly to print the final pattern on the printing platform according to the compensation value.
[0055] In some embodiments, the output of the preset training model is a score value for the initial pattern. A higher score value indicates a greater weight value in the image data, that is, an indication that the angle uniformity of the initial pattern printed using the preset extrusion parameters more closely meets the preset uniformity requirements.
[0056] How to determine the compensation value of the preset extrusion parameter according to the output result of the preset training model is described in detail in subsequent embodiments. In order to avoid repetition, it will not be described again here.
[0057] Compared with the related art, the embodiments of the present application have at least the following advantages: by using historical image data to train a preset training model, since the historical image data includes annotation data for characterizing the corner position and corner uniformity in the historical pattern, and the model training method of the preset training model is to classify the corner position and corner uniformity and then regress, the accuracy of the model prediction can be improved, so that the compensation value determined based on the output result of the preset training model can accurately compensate for the preset extrusion parameters, and thus the final pattern printed by the 3D printing device meets the printing quality requirements, the printing quality of the 3D printing device is improved, and thus the user experience is improved; in addition, by inputting the image data of the initial pattern into the preset training model to obtain the compensation value, the 3D printing device can be adapted to different application scenarios, avoiding the situation where "when obtaining the compensation value of the preset extrusion parameter through the laser radar, printing materials of different materials will affect the scanning results of the laser radar, and the laser radar has a scanning blind spot, resulting in inaccurate compensation value", ensuring the printing quality of the 3D printing device in different scenarios, and further improving the user experience.
[0058] Please refer to Figure 2 , which is a flow chart of a compensation detection method based on a 3D printing device provided in one embodiment of the present application. This embodiment explains the previous embodiment and specifically describes the model training method of the preset training model. By training the preset training model using the model training method of this embodiment, the accuracy and stability of the preset training model can be improved.
[0059] This embodiment is applied to a 3D printing device. The core of this embodiment is: a preset training model is trained based on historical image data of a historical pattern, wherein the historical pattern includes multiple corners, and the annotation data includes at least position information and a weight value of each corner, and the weight value is used to characterize the corner uniformity corresponding to the corner, wherein the larger the weight value, the more the corner uniformity corresponding to the corner meets the preset uniformity requirement; the head network of the preset training model is a multi-branch classification regression network, and the multi-branch classification regression network includes at least a first branch and a second branch.
[0060] The specific process of this embodiment is as follows Figure 2 As shown, the following steps are included:
[0061] Step 201: inputting position information into the first branch to obtain a first output value of the first branch; inputting a weight value into the second branch to obtain a second output value of the second branch.
[0062] In some embodiments, the annotation data further includes category information for each fold, where the category information is used to characterize the amount of printing material corresponding to the fold. For example, the category information includes "high material," "low material," and "moderate." When the category information for a fold is "high material," it indicates that the amount of printing material at the fold is high; when the category information for a fold is "low material," it indicates that the amount of printing material at the fold is low; and when the category information for a fold is "moderate," it indicates that the amount of printing material at the fold is moderate.
[0063] It is understood that when the labeled data also includes category information for each corner, the multi-branch classification regression network also includes a third branch. After the category information is input into the third branch, a third output value of the third branch is obtained. In this way, as many features of the corners as possible can be added during the subsequent model training process, thereby improving the accuracy of model training.
[0064] Step 202: regress the first output value and the second output value so that the preset training model outputs predicted annotation data of the historical image data; wherein, the attention mechanism is used when regressing the second output value.
[0065] It should be noted that, by using the attention mechanism when performing regression through the second output value, the preset training model can automatically learn and selectively focus on the second output value during the regression process. Since the second output value is the output result obtained after the second branch of the weight value input value, it can improve the preset training model's acquisition of the detailed features of the corners in the historical patterns, thereby improving the performance and generalization ability of the preset training model.
[0066] In some embodiments, when the annotation data also includes category information of each corner, the 3D printing device regresses the first output value, the second output value, and the third output value so that the preset training model outputs predicted annotation data of the historical image data; wherein, the second output value also uses the attention mechanism when regressing.
[0067] In some embodiments, the historical pattern includes multiple corners. After regressing the output results of the first branch and the output results of the second branch, each corner corresponds to an initial predicted labeling data; the preset training model outputs the predicted labeling data in the following manner: fitting a Gaussian function to multiple initial predicted labeling data, and taking the initial predicted labeling data corresponding to the maximum value of the Gaussian function as the predicted labeling data.
[0068] For ease of understanding, the following specifically describes how the preset training model in this embodiment outputs predicted annotation data:
[0069] Assume that the historical pattern includes five corners, namely corners 1 to 5. After regressing the output results of the first branch and the output results of the second branch, the preset training model obtains five initial predicted annotation data corresponding to corners 1 to 5, namely initial predicted annotation data 1 to initial predicted annotation data 5. The preset training model fits a Gaussian function to predicted annotation data 1 to initial predicted annotation data 5 and uses the initial predicted annotation data corresponding to the maximum value of the Gaussian function as the predicted annotation data.
[0070] It is understandable that since there are certain fluctuations in the predicted annotation data of historical patterns by the preset training model, and since the initial predicted annotation data of all corners in a historical pattern predicted by the preset training model conform to the normal distribution as a whole, by fitting a Gaussian function to the initial predicted annotation data of all corners, and taking the initial predicted annotation data corresponding to the maximum value of the Gaussian function as the final predicted output of the preset training model, the stability of the prediction of the preset training model can be greatly improved.
[0071] Step 203: Calculate the loss value of the loss function corresponding to the preset training model based on the labeled data and the predicted labeled data.
[0072] Step 204: Update the bias parameters of the preset training model through the back-propagation algorithm and the loss gradient of the loss function to reduce the loss value to meet the preset accuracy requirements; and use the bias parameters corresponding to the final loss value as the final bias parameters of the preset training model.
[0073] In some embodiments, the final bias parameter of the preset training model is obtained in the following manner: after the bias parameter of the preset training model is preset by the back propagation algorithm and the loss gradient of the loss function, it is assumed that the updated bias parameter is bias parameter 1, and then the preset training model with bias parameter 1 is trained by historical image data to obtain predicted annotation data 1 of the preset training model with bias parameter 1, and the loss value 1 is calculated based on the annotation data and the predicted annotation data 1, and whether the loss value 1 meets the preset accuracy requirement is detected, for example, the loss value 1 is less than a certain set value or the number of iterations corresponding to the loss value 1 is greater than the preset number. When the loss value 1 meets the preset accuracy requirement, the bias parameter 1 is used as the final bias parameter of the preset training model; when the loss value 1 does not meet the preset accuracy requirement, the above-mentioned process of iteratively updating the bias parameter 1 of the preset training model through the back propagation algorithm and the loss gradient of the loss function is repeated until the final loss value is reduced to meet the preset accuracy requirement.
[0074] Step 205: Control the nozzle assembly to print the initial pattern on the printing platform according to the preset extrusion parameters.
[0075] Step 206: Control the shooting component to shoot image data of the initial pattern, and input the image data into a preset training model.
[0076] Steps 205 to 206 of this embodiment are similar to steps 101 to 102 of the aforementioned embodiment, and are not described again here to avoid repetition.
[0077] Step 207: Determine the compensation value of the preset extrusion parameter according to the output result of the preset training model, and control the nozzle assembly to print the final pattern on the printing platform according to the compensation value.
[0078] For ease of understanding, the following specifically explains how to determine the compensation value of the preset extrusion parameter based on the output results of the preset training model:
[0079] In the process of using historical image data to train a preset training model, each historical image data is input into the preset training model, and the preset training model will output a historical score value corresponding to the historical image data. For example, assuming that the historical pattern includes three corners, namely corners A to C, the preset training model first obtains three initial predicted annotation data corresponding to corners A to C, namely initial predicted annotation data 1 to initial predicted annotation data 3, and then fits a Gaussian function to the preset training model for predicted annotation data 1 to initial predicted annotation data 3, and uses the maximum value of the Gaussian function as the historical score value corresponding to the historical image data. The initial predicted annotation data corresponding to the maximum value is also the predicted annotation data. Therefore, when the initial pattern is input into the preset training model, the preset training model will output the current score value corresponding to the initial pattern. The preset training model determines the current predicted annotation data that matches the current score value based on the historical score values corresponding to all historical image data obtained during the training process. The output result of the preset training model is also the current predicted annotation data. Since the current predicted annotation data includes the weight value of the corner, the 3D printing device can determine the compensation value of the preset extrusion parameter that matches the weight value.
[0080] Compared with related technologies, the embodiments of the present application have at least the following advantages: by acquiring the three-dimensional point cloud data of the printing platform to obtain a point cloud model of the printing platform, and then obtaining the actual curvature of the point cloud model, it is possible to calculate a compensation value based on the actual curvature and the theoretical curvature, and then perform deformation compensation on the point cloud model based on the compensation value, thereby compensating for the deformation of the printing platform. The entire process is efficient and easy to operate, avoiding the situation where "the shape of the printing platform is deformed, resulting in low printing accuracy of the 3D printing device", improving the printing accuracy of the 3D printing device, and thus improving the user experience. In addition, after the point cloud model is deformed according to the compensation value, a new point cloud model of the printing platform is obtained again, and if the curvature of the new point cloud model still does not meet the requirements, the compensation coefficient is updated, and the new point cloud model is again compensated for deformation to ensure the flatness of the printing platform, further improving the printing accuracy of the 3D printing device, and thus further improving the user experience.
[0081] Please refer to Figure 3 , a schematic diagram of the functional modules of a compensation detection device based on a 3D printing device provided in an embodiment of the present application. The 3D printing device includes a camera assembly, a nozzle assembly, and a printing platform. The nozzle assembly is used to extrude printing material onto the printing platform. The compensation detection device 100 based on the 3D printing device includes: a control module 1 and a preset training model 2.
[0082] The control module 1 is used to control the nozzle assembly to print an initial pattern on the printing platform according to the preset extrusion parameters. The control module 1 is also used to control the shooting assembly to shoot image data of the initial pattern and input the image data into the preset training model; the preset training model 2 is used to output the compensation value of the preset extrusion parameter according to the image data, wherein the training data used to train the preset training model 2 includes historical image data of historical patterns printed by the 3D printing device, and the historical image data includes annotation data, and the annotation data is used to characterize the corner position and corner uniformity in the historical pattern. The preset training model 2 is obtained by a model training method of classifying the corner position and corner uniformity and then regressing; the control module 1 is also used to control the nozzle assembly to print the final pattern on the printing platform according to the compensation value.
[0083] Please refer to Figure 4 , is a schematic diagram of the hardware structure of the electronic device 1000 provided in the embodiment of the present application. Figure 4 As shown, electronic device 1000 may include a processor 1001 and a memory 1002. Memory 1002 is configured to store one or more computer programs 1003. One or more computer programs 1003 are configured to be executed by processor 1001. The one or more computer programs 1003 include instructions that can be used to implement the above-mentioned compensation detection method based on a 3D printing device in electronic device 1000.
[0084] It is understood that the structure shown in this embodiment does not constitute a specific limitation on the electronic device 1000. In other embodiments, the electronic device 1000 may include more or fewer components than shown, or combine or separate some components, or arrange the components differently.
[0085] The processor 1001 may include one or more processing units. For example, the processor 1001 may include an application processor (AP), a modem, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU). Different processing units may be independent devices or integrated into one or more processors.
[0086] Processor 1001 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in processor 1001 is a cache memory. This memory can store instructions or data that have just been used or are being recycled by processor 1001. If processor 1001 needs to use the same instruction or data again, it can directly access it from this memory. This avoids duplicate accesses, reduces the waiting time of processor 1001, and thus improves system efficiency.
[0087] In some embodiments, the processor 1001 may include one or more interfaces. The interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a SIM interface, and / or a USB interface.
[0088] In some embodiments, memory 1002 may include high-speed random access memory and may also include non-volatile memory, such as a hard disk, memory, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), at least one disk storage device, a flash memory device, or other volatile solid-state storage device.
[0089] This embodiment further provides a computer-readable storage medium storing computer instructions. When the instructions are executed on an electronic device, the electronic device executes the above-mentioned related method steps to implement the compensation detection method based on the 3D printing device in the above embodiment.
[0090] Among them, the compensation detection device based on the 3D printing device, the electronic device, and the storage medium provided in this embodiment are all used to execute the corresponding methods provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding methods provided above, and will not be repeated here.
[0091] In practical applications, the above functions can be distributed to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above.
[0092] In the several embodiments provided in this application, the disclosed devices and methods can be implemented in other ways. For example, the device embodiments described above are schematic. For example, the division of the modules or units is a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another device, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0093] The units described as separate components may or may not be physically separate, and the components shown as units may be one physical unit or multiple physical units, that is, they may be located in one place or distributed in multiple places. Some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.
[0094] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0095] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for enabling a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
[0096] The above description is only a specific implementation method of the present application, but the protection scope of the present application is not limited thereto. Any changes or replacements within the technical scope disclosed in the present application should be included in the protection scope of the present application.
Claims
1. A compensation detection method based on 3D printing equipment, characterized in that: The 3D printing device includes a shooting component, a nozzle component, and a printing platform, wherein the nozzle component is used to extrude printing material onto the printing platform. The method includes: Controlling the nozzle assembly to print an initial pattern on the printing platform according to preset extrusion parameters; Controlling the photographing component to photograph image data of the initial pattern and inputting the image data into a preset training model; wherein the training data used to train the preset training model includes historical image data of historical patterns printed by the 3D printing device, the historical image data including annotation data, the annotation data being used to characterize the folding angle positions and folding angle uniformity in the historical patterns, and the preset training model is obtained by a model training method that classifies the folding angle positions and the folding angle uniformity and then regresses them; Determining a compensation value of the preset extrusion parameter according to an output result of the preset training model, and controlling the nozzle assembly to print a final pattern on the printing platform according to the compensation value; The historical pattern includes a plurality of folded corners, and the annotation data includes at least position information and a weight value of each folded corner, wherein the weight value is used to characterize the folded corner uniformity corresponding to the folded corner. The larger the weight value, the more the folded corner uniformity corresponds to the preset uniformity requirement. The head network of the preset training model is a multi-branch classification regression network, which includes at least a first branch and a second branch. The preset training model is trained in the following manner: Inputting the position information into the first branch to obtain a first output value of the first branch; Inputting the weight value into the second branch to obtain a second output value of the second branch; The first output value and the second output value are regressed to train the preset training model according to the regression result; wherein, the second output value uses an attention mechanism when regressing.
2. The compensation detection method based on 3D printing equipment according to claim 1, characterized in that: After regressing the output result of the first branch and the output result of the second branch, the preset training model outputs predicted annotation data of the historical image data; The step of training the preset training model according to the regression result includes: Calculating a loss value of a loss function corresponding to the preset training model based on the labeled data and the predicted labeled data; Iteratively updating the bias parameters of the preset training model through a back-propagation algorithm and the loss gradient of the loss function so as to reduce the loss value to meet the preset accuracy requirement; The bias parameter corresponding to the final loss value is used as the final bias parameter of the preset training model.
3. The compensation detection method based on 3D printing equipment according to claim 2, characterized in that: The historical pattern includes a plurality of folded angles, and after regressing the first output value and the second output value, each of the folded angles corresponds to an initial predicted annotation data; The preset training model outputs the predicted annotation data in the following manner: A Gaussian function is fitted to the plurality of initial predicted labeling data, and the initial predicted labeling data corresponding to the maximum value of the Gaussian function is used as the predicted labeling data.
4. The compensation detection method based on 3D printing equipment according to claim 1, characterized in that: The labeled data further includes category information of each fold, wherein the category information is used to characterize the amount of printing material corresponding to the fold; the multi-branch classification regression network further includes a third branch, and the preset training model is trained in the following manner: inputting the category information into the third branch to obtain a third output value of the third branch; The first output value, the second output value, and the third output value are regressed to train the preset training model according to the regression results; wherein the second output value uses an attention mechanism when regressing.
5. The compensation detection method based on 3D printing equipment according to claim 1, characterized in that: The backbone network of the preset training model is a CSP structure, and the neck network of the preset training model is an SPPF structure or a PAN structure.
6. The compensation detection method based on a 3D printing device according to any one of claims 1 to 5, characterized in that: The historical image data includes a plurality of broken lines, each broken line includes at least one broken angle, and each broken angle corresponds to one of the annotation data.
7. A compensation detection device based on 3D printing equipment, characterized in that: The 3D printing device includes a shooting component, a nozzle component and a printing platform, wherein the nozzle component is used to extrude the printing material onto the printing platform. The device includes: a control module and a preset training model; The control module is used to control the nozzle assembly to print an initial pattern on the printing platform according to preset extrusion parameters, and the control module is also used to control the shooting assembly to shoot image data of the initial pattern and input the image data into the preset training model; The preset training model is used to output the compensation value of the preset extrusion parameter based on the image data, wherein the training data used to train the preset training model includes historical image data of historical patterns printed by the 3D printing device, the historical image data includes annotation data, and the annotation data is used to characterize the folding angle position and folding angle uniformity in the historical pattern, and the preset training model is obtained by a model training method of classifying the folding angle position and the folding angle uniformity and then regressing; The control module is further configured to control the nozzle assembly to print a final pattern on the printing platform according to the compensation value; The historical pattern includes a plurality of folded corners, and the annotation data includes at least position information and a weight value of each folded corner, wherein the weight value is used to characterize the folded corner uniformity corresponding to the folded corner. The larger the weight value, the more the folded corner uniformity corresponds to the preset uniformity requirement. The head network of the preset training model is a multi-branch classification regression network, which includes at least a first branch and a second branch. The preset training model is trained in the following manner: Inputting the position information into the first branch to obtain a first output value of the first branch; Inputting the weight value into the second branch to obtain a second output value of the second branch; The first output value and the second output value are regressed to train the preset training model according to the regression result; wherein, the second output value uses an attention mechanism when regressing.
8. An electronic device, characterized in that: The electronic device includes a processor and a memory, the memory is used to store instructions, and the processor is used to call the instructions in the memory, so that the electronic device executes the compensation detection method based on a 3D printing device according to any one of claims 1 to 6.
9. A storage medium, characterized in that: The method comprises computer instructions, which, when executed on an electronic device, enable the electronic device to execute the compensation detection method based on a 3D printing device according to any one of claims 1 to 6.
Citation Information
Patent Citations
Printing control method, device and system and control equipment
CN110605854A
Processing step detection method of 3D printing equipment, electronic equipment and storage medium
CN117002009A