3D printing device-based detection method, device, equipment and storage medium
By using deep learning models to detect the printing status of 3D printing equipment, the high detection cost and privacy and security issues in existing technologies are resolved, achieving low-cost and accurate abnormal printing detection, and improving the reliability of the equipment and the user experience.
Patent Information
- Application Number
- CN202411391802.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-30
- Publication Date
- 2025-10-24
- Estimated Expiration
- 2044-09-30
AI Technical Summary
Current 3D printing equipment inspection methods rely on third-party apps for online inspection, which poses a risk of user privacy data leakage and is costly, failing to effectively protect user privacy and security.
A detection method based on a deep learning model is adopted to determine the printing status by obtaining the printing data of the nozzle or feed tube and the label association value of the preset label set, thereby realizing the anomaly detection of 3D printing equipment.
It reduces detection costs, improves detection accuracy and privacy security, enables timely detection and handling of abnormal printing situations, and enhances the reliability and stability of 3D printing equipment.
Smart Images

Figure CN119189307B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of 3D printing, and particularly relates to a detection method and device based on a 3D printing device, equipment and a storage medium. BACKGROUND
[0002] 3D printing is a technology that uses powder-like metal or plastic and other materials that can be bonded to construct objects through layer-by-layer printing based on digital model files. The main technologies include stereolithography, selective laser sintering and fused deposition modeling.
[0003] In related technologies, a 3D printing device detects whether an abnormal situation occurs in a printing process by using detection software or installing a detection tool on the 3D printing device, and using data detected by the detection tool. The 3D printing detection software mostly uses a third-party APP for online detection, and data is stored in the cloud, which may cause risks such as user video data leakage and cannot effectively protect the privacy and security of users. Installing an additional detection tool increases the detection cost. SUMMARY
[0004] Therefore, the present application provides a detection method and device based on a 3D printing device, equipment and a storage medium, which can accurately detect whether an abnormal printing situation occurs in a printing process of a 3D printing device and reduce the detection cost.
[0005] The first aspect of the present application provides a detection method based on a 3D printing device, the 3D printing device comprising a nozzle and a hot bed, the nozzle being configured to spray printing material to the hot bed. The detection method based on the 3D printing device comprises: obtaining a plurality of printing data of the nozzle within a preset time length during a printing process of the 3D printing device; calculating a label correlation value between each printing data and a preset label set, wherein the preset label set comprises a plurality of labels, and the plurality of labels at least comprise an empty printing label and a non-empty printing label, and the label correlation value is used to represent an association degree between the printing data and each label; determining a label corresponding to each printing data according to the label correlation value; and obtaining a detection result of the 3D printing device according to the label corresponding to each printing data.
[0006] Compared with related technologies, the embodiments of the present application have at least the following advantages:
[0007] The label correlation between each print data and the plurality of labels is calculated to determine the relationship between the plurality of labels and the print head when printing each print data, so as to obtain the label corresponding to each print data, and determine the printing condition of the print head when printing each print data. The detection result of the 3D printing equipment is determined based on the label, and the printing state of the print head in the 3D printing process is obtained based on the detection result, so as to determine whether abnormal printing occurs in the 3D printing process.
[0008] In some possible implementation manners, the calculating of the label correlation value of each print data and the preset label set comprises: performing convolution on the plurality of print data to obtain convolution feature data; and performing forward feature processing and backward feature processing on the convolution feature data based on the preset label set to obtain the label correlation value.
[0009] In some possible implementation manners, the determining of the label corresponding to each print data according to the label correlation value comprises: obtaining the label correlation value with the maximum correlation degree between the current print data in the plurality of print data and the plurality of labels; and determining the label corresponding to each print data according to the label correlation value with the maximum correlation degree.
[0010] In some possible implementation manners, the obtaining of the detection result of the 3D printing equipment according to the label corresponding to each print data comprises: performing label classification on the plurality of print data according to the label corresponding to each print data to obtain a plurality of classified print data; and determining the detection result of the 3D printing equipment based on the plurality of classified print data.
[0011] In some possible implementation manners, the method detects the printing condition of the 3D printing equipment by using a deep learning model; and a training process of the deep learning model comprises: determining a first time length, a second time length, a first label and a second label, wherein the first label at least comprises the empty printing label, and the second label at least comprises the non-empty printing label; controlling the print head to perform abnormal printing in the first time length, and obtaining first print data of the print head in the first time length, wherein the abnormal printing represents the empty printing condition of the print head; marking the first print data as the first label; controlling the print head to perform normal printing in the second time length, and obtaining second print data of the print head in the second time length, wherein the normal printing represents the non-empty printing condition of the print head; marking the second print data as the second label; and training the deep learning model based on the first print data and the second print data.
[0012] In some possible implementation manners, the training of the deep learning model based on the first printing data and the second printing data comprises: training the deep learning model by using part of the first printing data and part of the second printing data; obtaining historical gradient information; inputting another part of the first printing data and another part of the second printing data into the trained deep learning model; determining a loss value of the trained deep learning model based on the historical gradient information; and updating all parameters of the deep learning model based on the loss value until the deep learning model converges, to obtain the trained deep learning model.
[0013] The second aspect of the present application discloses a detection method based on a 3D printing device, the 3D printing device comprising a nozzle and a material delivery pipe, the material delivery pipe being used to deliver printing material to the nozzle; the detection method based on the 3D printing device comprising: obtaining a plurality of material delivery length data of the material delivery pipe within a preset time length during a printing process of the 3D printing device; obtaining a label association value of each of the material delivery length data and a preset label set, wherein the preset label set comprises a plurality of labels, the label association value being used to represent an association degree between the material delivery length data and each of the labels, and the plurality of labels at least comprising a non-printing label and a non-empty printing label; determining the label corresponding to each of the material delivery length data according to the label association value; and obtaining a detection result of the 3D printing device according to the label corresponding to each of the printing data.
[0014] The third aspect of the present application discloses a detection device based on a 3D printing device, comprising: an obtaining module configured to obtain a plurality of printing data of the nozzle within a preset time length during a printing process of the 3D printing device; a calculating module configured to calculate a label association value of each of the printing data and a preset label set, wherein the preset label set comprises a plurality of labels, the plurality of labels at least comprising a non-printing label and a non-empty printing label, and the label association value being used to represent an association degree between the printing data and each of the labels; a determining module configured to determine the label corresponding to each of the printing data according to the label association value; and a detection module configured to obtain a detection result of the 3D printing device according to the label corresponding to each of the printing data.
[0015] The fourth aspect of the present application discloses an electronic device, comprising a processor and a memory, the memory being used to store instructions, and the processor being used to call the instructions in the memory, so that the electronic device executes the above-mentioned detection method based on a 3D printing device.
[0016] The fifth aspect of the present application discloses a computer storage medium comprising computer instructions, which, when executed on an electronic device, cause the electronic device to perform the above-mentioned detection method based on a 3D printing device.
[0017] It can be understood that the detection device based on a 3D printing device of the third aspect, the electronic device of the fourth aspect, and the computer storage medium of the fifth aspect provided above all correspond to the method of the first aspect, and thus the beneficial effects achieved thereby can refer to the beneficial effects of the corresponding method provided above, which will not be described here again. BRIEF DESCRIPTION OF DRAWINGS
[0018] 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 some embodiments of the present application, and therefore should not be considered as limiting the scope. For those skilled in the art, other related drawings can also be obtained without creative labor on the basis of these drawings.
[0019] Figure 1 The step flow chart of the detection method based on a 3D printing device provided by an embodiment of the present application.
[0020] Figure 2 The step flow chart of training a deep learning model provided by an embodiment of the present application.
[0021] Figure 3 The structural schematic diagram of the detection device based on a 3D printing device provided by an embodiment of the present application.
[0022] Figure 4 The hardware structural schematic diagram of the electronic device of an embodiment of the present application.
[0023] Explanation of main element symbols
[0024] Detection device based on a 3D printing device 200
[0025] Acquisition module 210
[0026] Computing module 220
[0027] Determination module 230
[0028] Detection module 240
[0029] Electronic device 1000
[0030] Processor 1001
[0031] Memory 1002
[0032] Computer program 1003 DETAILED DESCRIPTION
[0033] In order to more clearly understand the above objectives, features and advantages of the present application, the following describes the present application in detail with reference to the attached drawings and specific embodiments. It should be noted that the embodiments of the present application and the features in the embodiments can be combined with each other without conflict.
[0034] In the following description, numerous specific details are set forth in order to provide a thorough understanding of the present application. The described embodiments are merely part of the embodiments of the present application, but not all the embodiments.
[0035] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs. The terminology used in the description herein is for describing particular embodiments only and is not intended to be limiting of the present application.
[0036] Further, it should be pointed out that herein, the terms “comprising”, “containing” or any other variants thereof are intended to cover non-exclusive containing, so that a process, method, article or device including a series of elements not only includes those elements, but also includes other elements not explicitly listed or inherent to such a process, method, article or device. Without more limitations, the element defined by the phrase “comprising a” does not exclude the presence of additional identical elements in the process, method, article or device including the element.
[0037] In the present application, “at least one” means one or more, and “multiple” means two or more than two. “And / or” describes the relationship between the associated objects, which means that there can be three relationships, for example, A and / or B can represent the following cases: A exists alone, A and B exist together, and B exists alone, where A and B can be singular or plural.
[0038] In the embodiments of the present application, the words “exemplary” or “for example” are used to mean serving as an example, instance, or illustration. Any embodiment or design scheme described as “exemplary” or “for example” in the embodiments of the present application should not be construed as being more preferred or advantageous than other embodiments or design schemes. Rather, the use of the words “exemplary” or “for example” is intended to present relevant concepts in a concrete manner.
[0039] For the convenience of understanding, some explanations of concepts related to the embodiments of the present application are given by way of example for reference.
[0040] 3D printing equipment, also known as three-dimensional printer or stereoscopic printer, is a process equipment of rapid prototyping, which is usually realized by printing materials with digital technology. The 3D printing equipment is often used for manufacturing models or parts in the fields of mold manufacturing and industrial design.
[0041] Please refer to Figure 1 A step flow chart of the detection method based on the 3D printing equipment provided in an embodiment of the present application, the embodiment is applied to the 3D printing equipment, the 3D printing equipment includes a nozzle, a first acquisition part and a hot bed, the nozzle is used for spraying printing materials to the hot bed, and the first acquisition part is used for collecting printing data of the nozzle under the extrusion force of the printing materials. The detection method based on the 3D printing equipment uses a pre-trained deep learning model to detect the printing condition of the 3D printing equipment, so as to determine whether the 3D printing equipment appears abnormal printing condition in time. In the embodiment, the first acquisition part is a pressure sensor. The embodiment only uses the pressure sensor often arranged in the 3D printing equipment to obtain the printing data of the nozzle. The cost of data acquisition is reduced. The detection method includes the following steps:
[0042] Step 101: In the printing process of the 3D printing equipment, a plurality of printing data of the nozzle within a preset time length is obtained.
[0043] In some embodiments, the preset time length can be set to 1 min, 2 min, etc.
[0044] It should be noted that in the process of 3D model printing of the 3D printing equipment, the empty printing phenomenon may occur. The empty printing is a common problem in printing, and the reasons are various, for example, the printing materials are used up, the printing materials are not clean or poor in quality, the printing temperature is not suitable, the printing speed is affected, etc., which leads to the problem of nozzle blockage in the printing process, causing the occurrence of empty printing. The occurrence of the empty printing phenomenon not only wastes the user's time and affects the user experience, but also may cause serious damage to the 3D printing equipment for a long time.
[0045] It should be further noted that in the process of 3D model printing of the 3D printing equipment, the nozzle wrapping phenomenon may occur. The nozzle wrapping (nozzle blob) phenomenon occurs due to the reasons such as nozzle blockage or unstable material temperature, which leads to the phenomenon that the molten plastic continuously accumulates in the printing process, a large amount of molten plastic is gathered around the nozzle, which may cause irregular protrusions or block-shaped objects on the surface of the printed object, or stick to the extrusion head, which is called "blob", causing quality defects of the printed object, affecting the quality of the printed object, and even may cause serious damage to the printer.
[0046] Therefore, by acquiring the plurality of printing data of the nozzle during the 3D model printing by the 3D printing device, and performing anomaly detection based on the plurality of printing data in the subsequent step, the 3D printing device can be stopped immediately when the nozzle is in abnormal printing during the printing of the to-be-printed object, thereby further improving the reliability of the 3D printing device.
[0047] Step 102: Calculate the label association value between each printing data and the preset label set.
[0048] In some embodiments, the preset label set includes a plurality of labels. In this embodiment, the plurality of labels at least includes a non-empty printing label and an empty printing label. In other embodiments, the plurality of labels can also include a nozzle wrapping label and a nozzle unwrapping label. The label association value is used to represent the association degree between the printing data and each label. In other embodiments, if other abnormal printing conditions also need to be detected, the preset label set can also include other labels in addition to the non-empty printing label, the empty printing label, the nozzle wrapping label and the nozzle unwrapping label.
[0049] Specifically, the association degree between each printing data and the plurality of labels is calculated respectively. The association data between each printing data and the plurality of labels is taken as the label association value. For example, the association degree between each printing data and the non-empty printing label is calculated, the association degree between each printing data and the empty printing label is calculated, the association degree between each printing data and the non-nozzle wrapping is calculated, and the association degree between each printing data and the nozzle wrapping is calculated.
[0050] In some embodiments, a pre-trained deep learning model is used to calculate the label association value of each printing data with the preset label set. The deep learning model includes a convolution layer, a bidirectional long short-term memory network and a fully connected layer. Among them, the plurality of printing data is convolved based on the convolution layer to obtain convolution feature data. The convolution feature data is forwardly and backwardly processed based on the preset label set to obtain the label association value. The training steps of the deep learning model are described in detail below, and will not be repeated here.
[0051] After the convolution feature data is forwardly and backwardly processed based on the preset label set, the association degree between each data in the convolution feature data and the non-empty printing label and the empty printing label can be obtained.
[0052] Specifically, the convolution layer uses a convolutional neural network (CNN). CNN can capture key features in data. That is, CNN extracts local features in input data through convolution operation. Convolution operation is a linear operation, which performs point-by-point multiplication and accumulation on input data, thereby capturing key features.
[0053] Further, the convolution feature data is subjected to forward feature processing and backward feature processing based on a preset label set and a bidirectional long short-term memory network to obtain target feature data. The bidirectional long short-term memory network (Bi-directional Long Short-Term Memory, BiLSTM) is an improved recurrent neural network (Recurrent Neural Network, RNN) specially designed for processing sequence data. BiLSTM can capture bidirectional dependencies in sequence data by combining the outputs of the forward and reverse long short-term memory networks. BiLSTM runs two independent long short-term memory networks at each time step, one from the beginning to the end of the sequence data (forward long short-term memory network), and the other from the end to the beginning of the sequence data (backward long short-term memory network). The outputs of the two long short-term memory networks are combined together, so that BiLSTM considers both past and future information, so that the model can better capture the context information in the sequence data. Thus, accurate time sequence feature correlation data is obtained to ensure the accuracy of subsequent classification of time sequence feature data.
[0054] Step 103: Determine the label corresponding to each print data according to the label association value.
[0055] In some embodiments, the label association value with the maximum association degree between the current print data in the plurality of print data and the plurality of labels is obtained. The label corresponding to each print data is determined according to the label association value with the maximum association degree. For example, if the plurality of labels includes an empty printing label and a non-empty printing label, the association degree between the current print data and the empty printing label is determined to be 0.8, and the association degree between the current print data and the non-empty printing label is determined to be 0.2. Since the maximum association degree between the current print data and the plurality of labels is 0.8, the label corresponding to the current print data is the empty printing label. In other embodiments, if the plurality of labels includes an empty printing label, a non-empty printing label, a nozzle wrapping label, and a nozzle unwrapping label, the association degree between the current print data and the empty printing label is determined to be 0.6, the association degree between the current print data and the non-empty printing label is determined to be 0.2, the association degree between the current print data and the nozzle wrapping label is determined to be 0.1, and the association degree between the current print data and the nozzle unwrapping label is determined to be 0.1. The maximum association degree between the current print data and the plurality of labels is 0.6, so the label corresponding to the current print data is the empty printing label.
[0056] Step 104: Obtain the detection result of the 3D printing equipment according to the label corresponding to each print data.
[0057] In some embodiments, the plurality of printing data are classified based on the preset label set to obtain a plurality of classified printing data. The detection result of the 3D printing device is determined based on the classified data. In this embodiment, the plurality of printing data are classified based on the preset label set using a full connection layer to obtain a classification result. The full connection layer uses a Dense layer. The Dense layer connects all neurons of a previous layer and all neurons of a current layer, and can help the deep learning model better understand the input data, thereby improving the accuracy of the deep learning model.
[0058] In some embodiments, the detection result of the 3D printing device includes abnormal printing and normal printing. Based on the classified data, a data set with a null label in the plurality of printing data is obtained. If the difference between each data in the data set with the null label is relatively small, the nozzle has an empty printing phenomenon during printing, and the detection result of the 3D printing device is abnormal printing. Similarly, if the plurality of labels further include a nozzle wrapping label and a nozzle unwrapping label, based on the classified data, a data set with the nozzle wrapping label in the plurality of printing data is obtained. If the difference between each data in the data set with the nozzle wrapping label is relatively small, the nozzle has a nozzle wrapping phenomenon during printing, and the detection result of the 3D printing device is also abnormal printing. Conversely, it is proved that the nozzle does not have an empty printing phenomenon or a nozzle wrapping phenomenon within a preset time period, and the detection result of the 3D printing device is normal printing.
[0059] When the detection result of the 3D printing device is abnormal printing, the 3D printing device will immediately stop printing. After the 3D printing device stops printing, it will also send warning information to the user to remind the user of the printing abnormality, so that the user can handle it in time, thereby improving the stability of the 3D printing device. The types of warning information include but are not limited to voice reminders, text reminders, etc. The user can set the type of warning information according to actual needs.
[0060] In some embodiments, the printing situation of the 3D printing device can also be detected by other means. The specific content is as follows:
[0061] The 3D printing device further includes a second acquisition member and a material delivery pipe. The material delivery pipe is connected to the nozzle, and is used to deliver printing material to the nozzle. The second acquisition member is used to acquire the length of the printing material in the material delivery pipe. The second acquisition member can be a distance sensor. In other embodiments, the second acquisition member can also be arranged in a material tank tray in the 3D printing device. The second acquisition member is used to acquire the length of the printing material in the material tank tray.
[0062] In the printing process of the 3D printing device, a plurality of feeding length data of the feeding pipe within a preset time length is acquired. A label association value of each feeding length data and a preset label set is acquired. The preset label set includes a plurality of labels, and the label association value is used to represent the association degree between the feeding length data and each label. The plurality of labels at least includes an empty printing label and a non-empty printing label. According to the label association value, a label corresponding to each feeding length data is determined. According to the label corresponding to each printing data, a detection result of the 3D printing device is acquired.
[0063] When the nozzle appears the empty printing condition, it proves that there is no printing material in the nozzle, and the feeding pipe may also not contain the printing material or the feeding pipe does not deliver the printing material to the nozzle. Therefore, the feeding length data of the nozzle when the nozzle appears the empty printing condition is different from the feeding length data of the nozzle when the nozzle does not appear the empty printing condition.
[0064] Similarly, if the plurality of labels includes a nozzle wrapping label and a nozzle unwrapping label, when the nozzle appears the nozzle wrapping condition, it proves that the printing material at the nozzle appears accumulation, which causes the printing material in the feeding pipe to also appear accumulation. Therefore, the feeding length data of the nozzle when the nozzle appears the nozzle wrapping condition is different from the feeding length data of the nozzle when the nozzle does not appear the nozzle wrapping condition.
[0065] Based on the plurality of feeding length data of the feeding pipe within the preset time length, the accurate detection result of the 3D printing device can also be determined.
[0066] It should be noted that the steps of determining the detection result of the 3D printing device based on the plurality of feeding length data of the feeding pipe within the preset time length are the same as steps 101 to 104, and the present application will not be repeated.
[0067] Compared with the related art, the embodiments of the present application have at least the following advantages: only the printing data of the nozzle is acquired by the first acquisition component or only the plurality of feeding length data of the feeding pipe is acquired by the second acquisition component, which reduces the additional acquisition device and reduces the cost of data acquisition. The association degree between each printing data or each feeding length data and the plurality of labels is calculated to determine the printing state of the nozzle or the feeding pipe in the 3D printing process, so as to obtain the detection result of the 3D printing device. On the one hand, the association between each printing data or each feeding length data and the preset label set can be accurately calculated by the deep learning model, which facilitates accurate detection of abnormal printing. On the other hand, the nozzle can be detected in time to occur abnormal printing condition, which facilitates the user to process the abnormal printing condition in time.
[0068] Please refer to Figure 2 The step flow chart for training the deep learning model provided by an embodiment of the present application.
[0069] The specific process of the embodiment is as followsFigure 2 As shown, the method comprises the following steps:
[0070] Step 201: determining a first time length, a second time length, a first label and a second label.
[0071] In some embodiments, the first label at least comprises an empty printing label, and the second label at least comprises a non-empty printing label. In other embodiments, the first label can further comprise a nozzle wrapping label, and the second label can further comprise a nozzle unwrapping label.
[0072] In order to ensure accurate detection of abnormal printing in the 3D printing process, the deep learning model needs to be trained before formal printing. The time length of the first time length can be equal to the time length of the second time length, or the time length of the first time length can not be equal to the time length of the second time length. For example, the first time length can be 1 min, and the second time length can also be 1 min, or the second time length can be 70 s.
[0073] Step 202: controlling the nozzle to perform abnormal printing in the first time length, and obtaining first printing data of the nozzle in the first time length.
[0074] In some embodiments, the abnormal printing represents that the nozzle performs empty printing or the nozzle appears nozzle wrapping during printing. In this embodiment, the two cases of nozzle empty printing and nozzle non-empty printing are explained.
[0075] Specifically, the nozzle is controlled to perform empty printing, and the first printing data of the nozzle in the first time length is obtained.
[0076] It should be noted that the printing condition when the nozzle appears nozzle wrapping phenomenon during printing is the same as the printing condition when the nozzle performs empty printing, and the present application will not be repeated.
[0077] Step 203: marking the first printing data as the first label.
[0078] In this embodiment, the first printing data is marked as an empty printing label. When the nozzle appears nozzle wrapping phenomenon during printing, the first printing data is marked as a nozzle wrapping label.
[0079] Step 204: controlling the nozzle to perform normal printing in the second time length, and obtaining second printing data of the nozzle in the second time length.
[0080] In some embodiments, the normal printing represents that the nozzle performs non-empty printing or the nozzle does not appear nozzle wrapping during printing.
[0081] In this embodiment, the nozzle is controlled to perform non-empty printing, and the second printing data of the nozzle during non-empty printing is obtained.
[0082] Step 205: marking the second printing data as the second label.
[0083] In the embodiment, the second printing data is marked as a non-empty marking label. When the nozzle wrapping phenomenon does not occur when the nozzle is printing, the second printing data is marked as a nozzle non-wrapping label.
[0084] The first printing data and the second printing data are stored. For example, the first printing data and the second printing data can be stored in a DataFrame data structure. The DataFrame is a table type data structure, which contains a set of ordered columns, and each column can be of different value types (numeric, string, Boolean value). At the same time, various functions are provided to perform data access, filtering, splitting, merging, reshaping, aggregation, and conversion operations. In other embodiments, the first printing data and the second printing data can also be stored in other data structures, which are not limited by the present application.
[0085] Step 206: training a deep learning model based on the first printing data and the second printing data.
[0086] In some embodiments, part of the first printing data and part of the second printing data are used as training data, and another part of the first printing data and another part of the second printing data are used as test data. For example, 70% of the first printing data and 70% of the second printing data are used as training data, and 30% of the first printing data and 30% of the second printing data are used as test data. Alternatively, 80% of the first printing data and 80% of the second printing data are used as training data, and 20% of the first printing data and 20% of the second printing data are used as test data. Alternatively, 70% of the first printing data and 80% of the second printing data are used as training data, and 30% of the first printing data and 20% of the second printing data are used as test data.
[0087] In some embodiments, the deep learning model is trained based on the training data. The test data is input into the trained deep learning model, and the loss value of the trained deep learning model is determined. All parameters of the deep learning model are updated based on the loss value until the deep learning model converges, and a trained deep learning model is obtained.
[0088] Specifically, after training the deep learning model based on the training data, the historical gradient information when the deep learning model is trained based on the training data is obtained. The test data is input into the trained deep learning model, and the loss value of the trained deep learning model is determined based on the historical gradient information. Then, all parameters of the deep learning model are updated based on the loss value until the deep learning model converges, and a trained deep learning model is obtained. The loss value of the trained deep learning model is determined using a BCE loss function (Binary Cross Entropy). The BCE loss function is a prior art, and will not be described again.
[0089] In this embodiment, after training the deep learning model based on the training data, the historical gradient information when the deep learning model is trained based on the training data is obtained using an adaptive optimizer (Adam). The test data is input into the trained deep learning model, and the loss value of the trained deep learning model is determined based on the historical gradient information.
[0090] It should be noted that the Adam optimizer can adaptively adjust the learning rate of the model according to the historical gradient information. A larger learning rate is used in the early stage of model training to enable the model to converge quickly. A smaller learning rate is used in the later stage of model training to more accurately find the minimum loss value. The deep learning model optimized based on the Adam optimizer can improve the accuracy of the deep learning model in detecting abnormal printing of the nozzle.
[0091] It should also be noted that the framework used by the deep learning model is the pytorch framework. The pytorch framework is an open source deep learning framework for machine learning and deep learning. When designing the model, the structure of the model can be dynamically modified at runtime, providing greater flexibility for the model. The deep learning model is converted into an ONNX format file through the ONNX open source library, which helps to better deploy the model and quickly exchange and port between different frameworks and platforms, improving the utility and availability of the model. The ONNX format file is then converted into an inference file format required by the embedded end of the 3D printing device through NCNN or ONNXRunTime. For example, the inference file format can be bin format. Finally, the converted deep learning model is deployed to the 3D printing device.
[0092] Compared with the related art, the embodiments of the present application have at least the following advantages: by controlling the ejection head to perform abnormal printing in the first time length and non-abnormal printing in the second time length, the first printing data in the abnormal printing condition and the second printing data in the non-abnormal printing condition are obtained. Then, the first printing data and the second printing data are used to train the deep learning model, and at the same time, the process of training is optimized by using the Adam optimizer in the training process. The model with precise detection effect is obtained, thereby improving the accuracy of abnormal printing detection.
[0093] Please refer to Figure 3 The structural schematic diagram of the detection device based on the 3D printing equipment provided by an embodiment of the present application.
[0094] The detection device based on the 3D printing equipment 200 is applied to the 3D printing equipment. The detection device based on the 3D printing equipment 200 includes an acquisition module 210, a calculation module 220, a determination module 230 and a detection module 240. The acquisition module 210 is configured to acquire a plurality of printing data of the ejection head in a preset time length during the printing process of the 3D printing equipment. The calculation module 220 is configured to calculate a label correlation value of each printing data and a preset label set, wherein the preset label set includes a plurality of labels, and the plurality of labels at least include an empty printing label and a non-empty printing label, and the label correlation value is used to represent the correlation degree between the printing data and each label. The determination module 230 is configured to acquire a detection result of the 3D printing equipment according to the label corresponding to each printing data.
[0095] Please refer to Figure 4 The hardware structural schematic diagram of the electronic device 1000 provided by an embodiment of the present application. As shown in Figure 4 The electronic device 1000 can include a processor 1001 and a memory 1002. The memory 1002 is configured to store one or more computer programs 1003. The one or more computer programs 1003 are configured to be executed by the processor 1001. The one or more computer programs 1003 include instructions, which can be used to implement the detection method based on the 3D printing equipment in the electronic device 1000.
[0096] It can be understood that the structure illustrated in the embodiment does not constitute a specific limitation on the electronic device 1000. In other embodiments, the electronic device 1000 can include more or fewer components than those shown, or combine certain components, or split certain components, or different arrangement of components.
[0097] The processor 1001 can include one or more processing units, for example: the processor 1001 can 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), etc. Different processing units can be independent devices or integrated in one or more processors.
[0098] The processor 1001 can also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 1001 is a cache memory. The memory can hold instructions or data that the processor 1001 has just used or recycled. If the processor 1001 needs to use the instructions or data again, it can be directly called from the memory. This avoids repeated access and reduces the waiting time of the processor 1001, thus improving the efficiency of the system.
[0099] In some embodiments, the processor 1001 can include one or more interfaces. The interfaces can 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, etc.
[0100] In some embodiments, the memory 1002 can include a high-speed random access memory, and can also include a non-volatile memory, for example, a hard disk, a memory, a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, at least one disk storage device, a flash memory device, or other volatile solid-state storage device.
[0101] The embodiment further provides a computer readable storage medium, which stores computer instructions, and when the instructions are run on an electronic device, the electronic device is caused to execute the above related method steps to implement the detection method based on the 3D printing device in the above embodiment.
[0102] In the embodiment, the detection device based on the 3D printing device, the electronic device and the storage medium are used to execute the corresponding method provided above, and thus the beneficial effects achieved by the above corresponding method can be referred to, and will not be described here.
[0103] In practical applications, the above functions can be completed by different functional modules according to needs, that is, the internal structure of the device is divided into different functional modules to complete all or part of the functions described above.
[0104] In the several embodiments provided in the present application, the disclosed device and method can be implemented in other ways. For example, the device embodiments described above are illustrative, and the division of the modules or units is a logical function division, and there can be another division manner in actual implementation, for example, a plurality of units or components can be combined or integrated into another device, or some features can be ignored or not executed. In addition, the coupling or direct coupling or communication connection between the units shown or discussed can be indirect coupling or communication connection through some interface, device or unit, and can be electrical, mechanical or other forms.
[0105] The units described as separate components can or can not be physically separate, and the components shown as units can be one physical unit or multiple physical units, that is, can be located in one place, or can be distributed in multiple different places. Some or all of the units can be selected according to actual needs to achieve the purpose of the embodiment.
[0106] In addition, each functional unit in each embodiment of the present application can be integrated in one processing unit, or each unit can exist physically, or two or more units can be integrated in one unit. The integrated unit can be realized in the form of hardware or in the form of a software functional unit.
[0107] The integrated unit, if implemented in the form of a software function unit and sold or used as an independent product, can be stored in a readable storage medium. Based on such understanding, the technical solutions of the embodiments of the present application essentially or say the part that contributes to the prior art or the whole or part of the technical solutions can be embodied in the form of a software product. The software product is stored in a storage medium, including a number of instructions to make a device (which can be a single-chip microcomputer, a chip, etc.) or a processor execute all or part of the steps of the method described in various embodiments of the present application. The aforementioned storage medium includes: a U disk, a mobile hard disk, a read-only memory (Read-Only Memory, ROM), a random access memory (Random Access Memory, RAM), a magnetic disk or an optical disk, and various media that can store program codes.
[0108] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any change or replacement within the technical scope disclosed in the present application should be covered within the protection scope of the present application.
Claims
1. A detection method based on a 3D printing device, characterized by, The 3D printing device comprises a nozzle and a hot bed, and the nozzle is used to spray printing material to the hot bed; The detection method based on the 3D printing device comprises: During the printing process of the 3D printing device, a plurality of printing data of the nozzle within a preset time length is acquired; The label correlation value of each printing data and a preset label set is calculated, wherein the preset label set comprises a plurality of labels, and the plurality of labels at least comprise an empty printing label and a non-empty printing label, and the label correlation value is used to represent the correlation degree between the printing data and each label; According to the label correlation value, the label corresponding to each printing data is determined; According to the label corresponding to each printing data, the detection result of the 3D printing device is acquired; The calculation of the label correlation value of each printing data and a preset label set comprises: Based on the convolution layer, the plurality of printing data is convolved to obtain convolution feature data; Based on the preset label set and the bidirectional long short-term memory network, the convolution feature data is processed forward and backward to obtain the label correlation value. 2.The 3D printing device-based detection method of claim 1, wherein, According to the label correlation value, the label corresponding to each printing data is determined, which comprises: The label correlation value with the maximum correlation degree between the current printing data in the plurality of printing data and the plurality of labels is acquired; According to the label correlation value with the maximum correlation degree, the label corresponding to each printing data is determined. 3.The 3D printing device-based detection method of claim 1, wherein, According to the label corresponding to each printing data, the detection result of the 3D printing device is acquired, which comprises: According to the label corresponding to each printing data, the plurality of printing data is classified by label to obtain a plurality of classified printing data; Based on the plurality of classified printing data, the detection result of the 3D printing device is determined. 4.The 3D printing device-based detection method of claim 1, wherein, The method utilizes a deep learning model to detect the printing condition of the 3D printing device; The training process of the deep learning model comprises: A first time length, a second time length, a first label and a second label are determined, wherein the first label at least comprises the empty printing label, and the second label at least comprises the non-empty printing label; The nozzle is controlled to perform abnormal printing within the first time length, and the first printing data of the nozzle within the first time length is acquired, wherein the abnormal printing represents the empty printing condition of the nozzle; The first printing data is marked as the first label; The nozzle is controlled to perform normal printing within the second time length, and the second printing data of the nozzle within the second time length is acquired, wherein the normal printing represents the non-empty printing condition of the nozzle; The second printing data is marked as the second label; The deep learning model is trained based on the first printing data and the second printing data. 5.The 3D printing device-based detection method of claim 4, wherein, The training of the deep learning model based on the first printing data and the second printing data comprises: Part of the data in the first printing data and part of the data in the second printing data are used to train the deep learning model; Historical gradient information is acquired; inputting another part of data in the first print data and another part of data in the second print data into the trained deep learning model; determining a loss value of the trained deep learning model based on the historical gradient information; updating all parameters of the deep learning model based on the loss value until the deep learning model converges, to obtain the trained deep learning model.
6. A detection method based on a 3D printing device, characterized by, The 3D printing equipment comprises a nozzle and a material conveying pipe for conveying printing material to the nozzle. The 3D printing equipment-based detection method comprises: In the printing process of the 3D printing equipment, a plurality of material conveying length data of the material conveying pipe within a preset time length are acquired; acquiring a label association value of each of the material conveying length data and a preset label set, wherein the preset label set comprises a plurality of labels, and the plurality of labels at least comprise an empty printing label and a non-empty printing label, and the label association value is used to represent an association degree between the material conveying length data and each of the labels; determining the label corresponding to each of the material conveying length data according to the label association value; acquiring a detection result of the 3D printing equipment according to the label corresponding to each of the material conveying length data; wherein the label association value of each of the material conveying length data and the preset label set is determined by the following method, comprising: performing convolution on a plurality of the material conveying length data based on a convolution layer to obtain convolution feature data; performing forward feature processing and backward feature processing on the convolution feature data based on the preset label set and a bidirectional long short-term memory network to obtain the label association value.
7. A 3D printing apparatus-based detection device, characterized by, comprising: an acquisition module: configured to acquire a plurality of printing data of a nozzle within a preset time length in a printing process of a 3D printing equipment; a calculation module: configured to calculate a label association value of each of the printing data and a preset label set, wherein the preset label set comprises a plurality of labels, the label association value is used to represent an association degree between the printing data and each of the labels, and the plurality of labels at least comprise an empty printing label and a non-empty printing label; a determination module: configured to determine the label corresponding to each of the printing data according to the label association value; a detection module: configured to acquire a detection result of the 3D printing equipment according to the label corresponding to each of the printing data; wherein the calculation module calculates the label association value of each of the printing data and the preset label set, comprising: performing convolution on a plurality of the printing data based on a convolution layer to obtain convolution feature data; performing forward feature processing and backward feature processing on the convolution feature data based on the preset label set and a bidirectional long short-term memory network to obtain the label association value.
8. An electronic device, comprising: The electronic device comprises 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 3D printing equipment-based detection method in any one of claims 1 to 6.
9. A computer storage medium, characterized in that Computer program comprising computer instructions which, when the computer instructions are executed on an electronic device, cause the electronic device to perform the detection method based on a 3D printing device as claimed in any one of claims 1 to 6.
Citation Information
Patent Citations
3D printing anomaly analysis method and system based on associated nozzle flow
CN118650884A
3D printing anomaly analysis method and system based on flow data
CN118664909A