SLM printer laser path monitoring method based on high-definition camera technology
By combining a high-definition camera with Canny edge detection and deep learning algorithms, the problem of inaccurate imaging in laser trajectory monitoring in SLM printers has been solved, achieving accurate laser path recognition and rapid imaging.
Patent Information
- Application Number
- CN202310330296.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-03-30
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2043-03-30
AI Technical Summary
In traditional SLM printers, when using high-definition cameras to monitor the laser trajectory, the imaging is not intuitive or accurate, and is affected by sparks and flying feathers and dust, resulting in poor imaging quality.
By combining high-definition camera technology with Canny edge detection algorithm and deep learning algorithm, the laser projection image is acquired by high-definition camera, a mathematical model is established, position correction and image preprocessing are performed, and the laser trajectory is identified by deep autoencoder and backpropagation neural network.
It achieves precise imaging of the laser path, effectively filters out spark noise interference, quickly identifies the laser trajectory path, and produces excellent imaging results.
Smart Images

Figure CN116214915B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The application belongs to the technical field of 3D printing, and particularly relates to a laser path monitoring method for an SLM printer based on high-definition camera technology. BACKGROUND
[0002] In the current traditional SLM printer technology, the trajectory of the laser is monitored by video acquisition, usually by an infrared camera. However, the pictures taken by the infrared camera are not intuitive and accurate enough, and the temperature range of the molten pool and the affected temperature difference area will affect the final imaging. When using a high-definition camera, the camera will be affected by factors such as sparks and flying feathers, resulting in poor final imaging performance. SUMMARY
[0003] The application aims to provide a laser path monitoring method for an SLM printer based on high-definition camera technology, which solves the technical problem of using a high-definition camera, a Canny edge detection algorithm and a deep learning algorithm to accurately image the laser path.
[0004] To achieve the above-mentioned purpose, the application adopts the following technical solutions:
[0005] A laser path monitoring method for an SLM printer based on high-definition camera technology, comprising the following steps:
[0006] Step 1: An image acquisition module captures the processing area of the SLM printer by a high-definition camera, acquires real-time pictures when the laser of the SLM printer is projected onto the processing area, and establishes a time sequence picture set, wherein the time sequence picture set is a group of pictures taken by the high-definition camera according to the time sequence when the laser is projected onto the processing area;
[0007] Step 2: A picture processing module retrieves any one of the first three pictures in the time sequence picture set as a sample picture for position calibration, establishes a mathematical model of the processing area, places the mathematical model of the processing area in a world coordinate system, selects a plurality of points in the mathematical model of the processing area, obtains the coordinates of each point in the world coordinate system, and takes the coordinates of the points in the world coordinate system as the relative coordinates of the points;
[0008] A local coordinate system of the sample picture is established in the sample picture, the positions of each point are calibrated in the local coordinate system of the sample picture according to the relative coordinates of the points, and the points are marked as positioning points in the sample picture;
[0009] Step 3: Place the sample map in the world coordinate system so that all the dots coincide with their corresponding positioning points, thereby obtaining the correction value between the origin of the local coordinate system of the sample map and the origin of the world coordinate system. The picture processing module corrects the position of the local coordinate system of each picture in the time sequence picture set according to the correction value to obtain a positioning time sequence picture set;
[0010] Step 4: Place all pictures in the positioning time sequence picture set in the multiple layers in time sequence from top to bottom. The image processing module combines all the layers to create a single image, which represents the projection trajectory of the laser;
[0011] Step 5: The image processing module pre-processes the image to obtain a pre-processed unidentified image;
[0012] Step 6: The trajectory recognition module calls the unidentified image, extracts the target region in the laser trajectory part of the unidentified image according to the gray value of the pixel, and generates a to-be-recognized region;
[0013] Step 7: The trajectory recognition module performs edge detection on the to-be-recognized region image according to the Canny edge detection algorithm, obtains an edge connection relationship set, constructs a geometric model according to the connection relationship of each adjacent edge in the edge connection relationship set, and calculates the area S of the geometric model and the average value L of the gray values of all pixels in the geometric model;
[0014] According to the deep learning algorithm, a plurality of deep autoencoders, hidden layers and back propagation neural networks BP are constructed, the area S and the average value L are taken as the input feature vector, and all regions representing the laser trajectory are screened out by the deep learning algorithm and combined into a laser trajectory image;
[0015] Step 8: The output module calls the laser trajectory image obtained in step 7 and displays it to the user through the display screen.
[0016] Preferably, when step 5 is performed, the pre-processing includes gray processing, Gaussian filter processing and binaryzation processing of the original image using Otsu adaptive threshold.
[0017] Preferably, when step 6 is performed, when the target region in the laser trajectory part is extracted, the specific steps are as follows:
[0018] Step 6-1: Set a pixel threshold representing laser projection, and according to the pixel threshold, traverse all pixels in the unidentified image to screen out all pixels within the pixel threshold;
[0019] Step 6-2: According to the positional proximity relationship between the pixels, a plurality of to-be-recognized region images are screened out.
[0020] Preferably, when performing step 7, the specific steps are as follows:
[0021] Step 7-1: Call any one of the to-be-recognized region image, and perform smoothing processing on the to-be-recognized region image to remove noise;
[0022] Step 7-2: According to the Canny edge detection algorithm, perform edge detection on the to-be-recognized region image, and set a threshold Q;
[0023] Step 7-3: Delete all edges below the threshold Q, and set all edges reaching the threshold Q as true value edges, to establish a true value edge set for representing the connection relationship of all true value edges;
[0024] According to the connection relationship of the true value edges, construct a geometric model, calculate the area S of all geometric models, and calculate the average value L of the gray values of all pixels in the geometric model;
[0025] Step 7-4: Take the area S and the average value L as input feature vectors, and use a deep learning algorithm to recognize all regions representing laser tracks, and combine them into a laser track image.
[0026] Preferably, when performing step 7, the deep auto-encoder includes an encoder and a decoder, and the encoder uses the following mathematical model for encoding:
[0027] BM=F(x)=P F (Wx+Y j );
[0028] Wherein, x is a feature vector composed of the area of the geometric model and the average value of the gray values of the pixels in the geometric model, W is the weight value of the input vector, Y j is the threshold value of the jth neuron, BM is the obtained hidden layer vector, P F is the activation function of the encoder;
[0029] The decoder uses the following mathematical model for decoding:
[0030] JM=G(BM)=R G (WBM+Y BM );
[0031] Wherein, G(t) is the decoder function, BM is the hidden layer vector calculated by the encoder and used as the input quantity of the decoder, W is the weight vector corresponding to BM, Y BM is a preset threshold value, R G is the activation function of the decoder;
[0032] The training process of the deep auto-encoder is as follows:
[0033] Step S1-1: Area S and average value L are taken as input quantities to construct a feature vector, and a sample set D for training is constructed according to the feature vector;
[0034] Step S1-2: Area S and average value L in the sample set D are input into a deep auto-encoder, and a first encoder is trained unsupervisedly;
[0035] Step S1-3: The output of the first encoder is taken as an input vector to train a next encoder;
[0036] Step S1-4: Step S1-3 is repeatedly executed until training of a preset number of hidden layers is completed;
[0037] Step S1-5: Two types of geometric models, including a laser trajectory and a non-laser trajectory, are taken as outputs, a back propagation neural network BP is added on the last hidden layer to predict the outputs, and weight fine-tuning is performed on the output results.
[0038] The SLM printer laser path monitoring method based on the high-definition camera technology solves the technical problem of finally accurately imaging the laser path by using a high-definition camera, a Canny edge detection algorithm and a deep learning algorithm, has good imaging effect, can well filter out noise interference of sparks, can accurately identify a laser trajectory path pattern, and has fast imaging speed. BRIEF DESCRIPTION OF DRAWINGS
[0039] Figure 1 is a main flowchart of the present application;
[0040] Figure 2 is a flowchart of step 6 of the present application;
[0041] Figure 3 is a flowchart of step 7 of the present application;
[0042] Figure 4 is a flowchart of a training process of a deep auto-encoder of the present application;
[0043] Figure 5 is a mathematical model schematic diagram when a sample is revised in the present application. DETAILED DESCRIPTION
[0044] As shown in Figures 1-5 A SLM printer laser path monitoring method based on a high-definition camera technology includes the following steps:
[0045] Step 1: The image acquisition module captures real-time images of the processing area of the SLM printer using a high-definition camera, and establishes a time-series image set. The time-series image set consists of a set of images captured by the high-definition camera in chronological order when the laser is projected onto the processing area.
[0046] Step 2: The image processing module retrieves the time-series image set, selects any one of the first three images from the time-series image set as a sample image for position calibration, establishes a mathematical model of the processing area, places the mathematical model of the processing area in the world coordinate system, selects several punctuation points in the mathematical model of the processing area, obtains the coordinates of each punctuation point in the world coordinate system, and uses the coordinates of the punctuation point in the world coordinate system as the relative coordinates of the punctuation point;
[0047] Establish a local coordinate system for the calibration sample drawing. Based on the relative coordinates of the punctuation points, mark the position of each punctuation point in the local coordinate system of the sample drawing and record it as a positioning point in the sample drawing.
[0048] Due to inherent errors in the equipment's installation location, the image of the SLM printer's processing area captured by the high-definition camera is slightly offset from the actual processing area's position in the world coordinate system. In this embodiment, for example... Figure 3 As shown, the ideal processing area is represented by a rectangular plane DD1 in the world coordinate system 0XY. However, the local coordinate system O′X′Y′ of the image captured by the high-definition camera is actually offset from the world coordinate system 0XY. This invention selects two points, A and B, in the ideal mathematical model to obtain the coordinates (x, y, y) of point A in the world coordinate system 0XY. a y a ), and the coordinates of point B in the world coordinate system 0XY (x b y b ), will (x a y a ) and (x a y a Using relative coordinates, these are directly placed into the local coordinate system O′X′Y′, thereby locating the positioning point A' corresponding to point A and the positioning point B' corresponding to point B. Finally, the image captured by the high-definition camera is moved so that point A coincides with positioning point A' and point B coincides with positioning point B', thus correcting the position of the image captured by the high-definition camera.
[0049] In this embodiment, the mathematical model of the processing area is an ideal model constructed based on the position parameters of the components of the SLM printer itself. It is regarded as a standard model representing the positional positioning between the various components of the SLM printer. The position parameters of the components are provided by the manufacturer.
[0050] Step 3: Place the sample map in the world coordinate system so that all the dots coincide with their corresponding positioning points, thereby obtaining the correction value between the origin of the local coordinate system of the sample map and the origin of the world coordinate system. The picture processing module corrects the position of the local coordinate system of each picture in the time sequence picture set according to the correction value to obtain a positioning time sequence picture set;
[0051] Step 4: Place all pictures in the positioning time sequence picture set in the multiple layers in time sequence from top to bottom. The image processing module combines all the layers to create a single image, which represents the projection trajectory of the laser;
[0052] Step 5: The image processing module pre-processes the image to obtain a pre-processed unidentified image. The pre-processing includes grayscale processing, Gaussian filter processing, and binaryzation of the original image using Otsu adaptive threshold.
[0053] Step 6: The trajectory recognition module retrieves the unidentified image and extracts the target region of the laser trajectory part in the unidentified image according to the pixel grayscale value to generate a to-be-identified region.
[0054] When extracting the target region of the laser trajectory part, the specific steps are as follows:
[0055] Step 6-1: Set a pixel grayscale threshold representing laser projection. According to the pixel grayscale threshold, traverse all pixels in the unidentified image and filter out all pixels reaching the pixel grayscale threshold.
[0056] Step 6-2: According to the positional proximity relationship between pixels, filter out multiple to-be-identified region images.
[0057] In this embodiment, a neighbor distance threshold is set. When the distance between two pixels is less than the neighbor distance threshold, the two pixels are considered adjacent and are classified into the same to-be-identified region image.
[0058] Step 7: The trajectory recognition module performs edge detection on the to-be-identified region image according to the Canny edge detection algorithm, obtains an edge connection relationship set, constructs a geometric model according to the connection relationship of each adjacent edge in the edge connection relationship set, calculates the area S of the geometric model, and calculates the average value L of the grayscale values of all pixels in the geometric model.
[0059] According to the deep learning algorithm, construct several deep autoencoders, hidden layers, and back propagation neural networks BP, take the area S and the average value L as the input feature vector, and filter out all regions representing the laser trajectory through the deep learning algorithm and combine them into a laser trajectory image.
[0060] The specific steps are as follows:
[0061] Step 7-1: call any one of the to-be-recognized region image, and perform smoothing processing on the to-be-recognized region image to remove noise;
[0062] Step 7-2: perform edge detection on the to-be-recognized region image according to a Canny edge detection algorithm, and set a threshold Q;
[0063] Step 7-3: delete all edges lower than the threshold Q, and set all edges reaching the threshold Q as true value edges, to establish a true value edge set for representing the connection relationship of all true value edges;
[0064] According to the connection relationship of the true value edges, a geometric model is constructed, the area S of all geometric models is calculated, and the average value L of the gray values of all pixels in the geometric model is calculated;
[0065] Step 7-4: take the area S and the average value L as input feature vectors, and recognize all regions representing laser tracks by using a deep learning algorithm, and combine the regions into a laser track image.
[0066] In the execution of step 7, the deep auto-encoder includes an encoder and a decoder, and the encoder encodes by using the following mathematical model:
[0067] BM=F(x)=P F (Wx+Y j );
[0068] Wherein, x is a feature vector composed of the area of the geometric model and the average value of the gray values of the pixels in the geometric model, W is the weight of the input vector, Y j is the threshold value of the jth neuron, BM is the obtained hidden layer vector, P F is the activation function of the encoder;
[0069] The decoder decodes by using the following mathematical model:
[0070] JM=G(BM)=R G (WBM+Y BM );
[0071] Wherein, G(t) is the decoder function, BM is the hidden layer vector calculated by the encoder and used as the input quantity of the decoder, W is the weight vector corresponding to BM, Y BM is a preset threshold value, R G is the activation function of the decoder;
[0072] The training process of the deep auto-encoder is as follows:
[0073] Step S1-1: area S and average value L are taken as input quantities to construct a feature vector, and a sample set D for training is constructed according to the feature vector;
[0074] In this embodiment, area S and average value L are taken as two condition input values to construct the feature vector, and when the feature vector is selected, it is necessary to first determine whether area S and average value L reach the preset threshold value at the same time, and then further processing is performed according to the size of area S and the size of average value L.
[0075] Step S1-2: area S and average value L in the sample set D are input into the deep auto-encoder, and a first encoder is trained unsupervisedly;
[0076] Step S1-3: the output of the first encoder is taken as an input vector to train a next encoder;
[0077] Step S1-4: step S1-3 is repeatedly executed until the training of a preset number of hidden layers is completed;
[0078] Step S1-5: two types of geometric models including laser trajectories and non-laser trajectories are taken as outputs, a back propagation neural network BP is added on the last hidden layer to predict the outputs, and weight fine-tuning is performed on the output results.
[0079] Generally, an area threshold value U and a gray threshold value V are first set to perform first screening on area S and average value L, geometric models with too small area and too low gray value are screened out, then different gray values of the geometric models with fixed area are taken as feature vectors to construct the training set D, and finally, the training is completed according to the two types of geometric models.
[0080] Step 8: the output module calls the laser trajectory image obtained in step 7 and displays it to the user through the display screen.
[0081] The SLM printer laser path monitoring method based on the high-definition camera technology solves the technical problem of finally accurately imaging the laser path by using a high-definition camera, a three-layer neural network training and a Canny edge detection algorithm, has good imaging effect, can well filter out noise interference of sparks, can accurately identify the laser trajectory path pattern, and has fast imaging speed.
Claims
1. A method for monitoring the laser path of an SLM printer based on high-definition video recording technology, characterized in that: Comprising the following steps: Step 1: The image acquisition module captures the processing area of the SLM printer through a high-definition camera, collects real-time pictures when the laser projection of the SLM printer is projected onto the processing area, and establishes a time sequence picture set, wherein the time sequence picture set is a group of pictures taken by the high-definition camera according to the time sequence when the laser projection is projected onto the processing area; Step 2: The picture processing module calls the time sequence picture set, and calls any one of the first three pictures in the time sequence picture set as a sample picture for position calibration. The picture processing module establishes a mathematical model of the processing area, places the mathematical model of the processing area in the world coordinate system, selects a plurality of points in the mathematical model of the processing area, obtains the coordinates of each point in the world coordinate system, and takes the coordinates of the points in the world coordinate system as the relative coordinates of the points; A local coordinate system of the sample picture is established in the sample picture, and the positions of each point are calibrated in the local coordinate system of the sample picture according to the relative coordinates of the points, and are marked as positioning points in the sample picture; Step 3: Place the sample picture in the world coordinate system so that all points coincide with their corresponding positioning points, thereby obtaining the correction value between the origin of the local coordinate system of the sample picture and the origin of the world coordinate system. The picture processing module corrects the position of the local coordinate system of each picture in the time sequence picture set according to the correction value, and obtains a positioned time sequence picture set; Step 4: All pictures in the positioned time sequence picture set are placed in a plurality of layers in time sequence from top to bottom, and the image processing module combines all layers to create a single image, which represents the projection trajectory of the laser; Step 5: The image processing module pre-processes the image to obtain a pre-processed unidentified image; Step 6: The trajectory recognition module calls the unidentified image, extracts the target region of the laser trajectory part in the unidentified image according to the pixel gray value, and generates a to-be-recognized region; When performing step 6, when the target region of the laser trajectory part is extracted, the specific steps are as follows: Step 6-1: Set a pixel gray threshold representing laser projection, and according to the pixel gray threshold, traverse all pixels in the unidentified image, and filter out all pixels within the pixel gray threshold; Step 6-2: According to the position proximity relationship between the pixels, a plurality of to-be-recognized region images are filtered out; Step 7: The trajectory recognition module performs edge detection on the to-be-recognized region image according to the Canny edge detection algorithm, obtains an edge connection relationship set, constructs a geometric model according to the connection relationship of each adjacent edge in the edge connection relationship set, calculates the area S of the geometric model, and calculates the average value L of the gray values of all pixels in the geometric model; According to the deep learning algorithm, a plurality of deep autoencoders, hidden layers and back propagation neural networks BP are constructed, the area S and the average value L are taken as the input feature vector, and all regions representing the laser trajectory are filtered out through the deep learning algorithm, and are combined into a laser trajectory image; When performing step 7, the specific steps are as follows: Step 7-1: Call any one of the to-be-recognized region images, and perform smoothing processing on the to-be-recognized region image to remove noise; Step 7-2: According to the Canny edge detection algorithm, edge detection is performed on the image of the region to be identified, and a threshold Q is set; Step 7-3: All edges below the threshold Q are deleted, and all edges reaching the threshold Q are set as true value edges to establish a true value edge set for representing the connection relationship of all true value edges; According to the connection relationship of the true value edges, a geometric model is constructed, the area S of all geometric models is calculated, and the average value L of the gray values of all pixels in the geometric model is calculated; Step 7-4: The area S and the average value L are taken as input feature vectors, and a deep learning algorithm is used to identify all regions representing laser tracks and combine them into a laser track image; Step 8: The output module calls the laser track image obtained in step 7 and displays it to the user through the display screen.
2. The method of claim 1, wherein the method is a method of laser path monitoring for a SLM printer based on high-definition video recording technology. In step 5, the preprocessing includes gray processing, Gaussian filtering processing, and binaryzation processing of the original image using Otsu adaptive threshold.
3. The method of claim 1, wherein the method is a method of laser path monitoring for a SLM printer based on high-definition camera technology. In step 7, the deep autoencoder includes an encoder and a decoder, and the encoder uses the following mathematical model for encoding: BM = F(x) = P F (W1 · x + Y j ); wherein x is a feature vector composed of an average value of the area of the geometric model and the gray value of the pixels within the geometric model, W1 is a weight value of the feature vector, Y j is a threshold value of the jth neuron, BM is the vector of the obtained hidden layer, P F is an activation function of the encoder; The decoder uses the following mathematical model for decoding: JM = G(BM) = R G (W2·BM+Y BM ); Wherein, G(BM) is a decoder function, BM is an implicit layer vector calculated by an encoder and used as an input of the decoder, W2 is a weight of the BM vector, Y BM is a preset threshold, R G is an activation function of the decoder; The training process of the deep autoencoder is as follows: Step S1-1: Take the area S and the average value L as input quantities to construct a feature vector, and construct a sample set D for training according to the feature vector; Step S1-2: Input the area S and the average value L in the sample set D into the deep autoencoder to train the first encoder unsupervisedly; Step S1-3: Take the output of the first encoder as an input vector to train the next encoder; Step S1-4: Repeat step S1-3 until the training of the preset number of hidden layers is completed; Step S1-5: Take the two types of geometric models as output, add a back propagation neural network BP to the last hidden layer to predict the output, and then weight fine-tune the output result; the two types of geometric models include laser tracks and non-laser tracks.
Citation Information
Patent Citations
Real-time monitoring method, device and system for selective laser melting
CN109277568A
Deep learning-based molten pool image geometric feature extraction method and system
CN113554587A