# Mathematical Modeling for Ceramic Shape 3D Image Based on Deep Learning Algorithm

Authors: Lijian Zhang; Guangfu Liu
Journal: Advances in Mathematical Physics
 (2021)

---

## Abstract

Ceramic image shape 3D image modeling focuses on of ceramic that was obtained from the camera imaging equipment such as 2D images, by normalization, gray, filtering denoising, wavelet image sharpening edge enhancement, binarization, and shape contour extraction pretreatment processes such as extraction ceramic image shape edge profile, again, according to the image edge extraction and elliptic rotator ceramics phenomenon. The image distortion effect was optimized by self-application, and then the deep learning modeler was used to model the side edge contour. Finally, the 3D ceramic model of the rotating body was restored according to the intersection and central axis of the extracted contour. By studying the existing segmentation methods based on deep learning, the automatic segmentation of target ceramic image and the effect of target edge refinement and optimization are realized. After extracting and separating the target ceramics from the image, we processed the foreground image of the target into a three-dimensional model. In order to reduce the complexity of the model, a 3D contextual sequencing model is adopted to encode the hidden space features along the channel dimensions, to extract the causal correlation between channels. Each module in the compression framework is optimized by a rate-distortion loss function. The experimental results show that the proposed 3D image modeling method has significant advantages in compression performance compared with the optimal 2D 3D image modeling method based on deep learning, and the experimental results show that the performance of the proposed method is superior to JP3D and HEVC methods, especially at low bit rate points.


---

## Body

## 1. Introduction

At present, the classification, origin, and date identification of ceramics still rely mainly on traditional artificial identification and modern scientific identification. With the rapid development of society, economy, and culture, it is difficult to meet the urgent demand for accurate identification of ceramics from all walks of life under the background of the rapid development of modern society. In recent years, with the rise of deep learning technology [1], new technologies and methods emerge in an endless stream, constantly breaking through people’s imagination, and deep learning technology has been integrated into different fields of all walks of life. At present, the application of deep learning technology in ceramic identification has gradually become a research focus, and the maturity of computer technology provides new opportunities and methods for scientific and objective identification of ceramics.In multivariate ceramic artifact information at the same time and porcelain ware with distinctive times and regional features, the porcelain ware plays an incomparable role in the cultural relic appraisal [2], especially in today’s information age, and the digital porcelain ware can not only do through the feature extraction and analysis but summarizes the various historical periods; different kiln mouths implement the structure characteristics. The discovery of the inheritance and evolution law of ceramic ware forms provides a reference for the origin and age of ceramic ware and the identification of authenticity. It also has a profound influence on the indepth study of the relationship between the artistic characteristics of ceramic ware forms and culture and aesthetics and even the analysis of the relationship between ceramic ware forms and metal and glass ware forms. Strengthening the research on ceramic artifacts can deduce the historical process from the perspective of ceramics, excavate the cultural rules of various times, and promote the modern people’s understanding and inheritance of history, culture, and art. However, due to the diversity and complexity of ceramic products, it is difficult and inefficient to accurately extract ceramic products, and it is often difficult to obtain accurate parameters of ceramic products by conventional measurement methods. And largely ceramic real is stored in the museum and private collectors, for reasons of security or privacy, and the owner of these ceramic products or unit is generally not willing to accept its expensive ceramics equipment scanning and data collection, even if reluctantly agreed to also must pass through the complex procedures, making ceramic 3D scanning data. All these result in a serious shortage of digital ceramic data in the era of big data with information expansion, which seriously restricts the research process of big data. Therefore, using machine vision technology to accurately restore two-dimensional image information to the three-dimensional model, continuously expand ceramic image database, promote the improvement of ceramic digital data, and become a hot research direction of ceramics.This paper proposes a deep learning-based three-dimensional image three dimensional end-to-end modeling method, the model using the encoder to the three dimensional input image transformation of low dimension space, and then uses the super prior model and context model as the office coding model, to estimate the probability distribution of the hidden space in order to improve the coding efficiency. Meanwhile, a 3D nonlocal attention model is introduced to take advantage of the global correlation of the input image. In order to reduce the complexity of the model, a 3D ConvLSTM-based context-dependent encoding model is used to encode hidden spatial features sequentially along the channel dimension to extract the causal correlation between channels. Each module in the compression framework is optimized by a rate distortion loss function. Machine vision technology is applied to ceramic image processing. Through the processing of single form eye image, the information type of cultural relics is extracted image, the ceramic cultural relic recovery type of the 3D model, and various distortion correction algorithm modelings, which promotes the development of digital model base of cultural relics.


## 2. Related Work

In recent years, there have been many 3D image modeling methods based on deep learning. Most of these methods adopt autoencoder structure to transform the input image into a hidden space with lower dimension through the encoder and then encode in the hidden space using the correlation between space and channel dimensions [3]. For 3D image modeling, convolutional deep learning has some advantages compared with traditional compression methods (such as JPEG2000). First, stacked convolutional deep learning can realize nonlinear forward and inverse transformations more flexibly, which is conducive to image encoding and decoding. Secondly, the deep learning-based method can optimize each part of the compression framework end-to-end, while each part of the traditional method is optimized independently, which makes it difficult to achieve overall optimization [4]. Finally, the method based on deep learning can realize adaptive to different kinds of image content.It is explored that the self-encoder structure can be used as a feasible method for image end-to-end compression [5, 6], but the deep learning-based compression method has not surpassed the traditional compression efficiency and the compression performance of the traditional encoding method. A variable bitrate compression method based on cyclic convolution deep learning (RNN) is proposed [7]. Based on the autoencoder structure, the method encodes images through multiple iterations of the network, so as to achieve variable bitrate coding and progressive coding. It has good compression performance in images with small resolution (32×32). It exceeds traditional compression methods such as JPEG2000, WEBP, and BPG [8]. Two iterations of the method are shown. The first iteration is to encode the original image, and the second iteration is to encode the residual between the reconstructed image and the original image. In order to compress images with larger resolution, an autoencoder structure-based on cyclic deep learning (RNN) is adopted to achieve end-to-end variable bit rate 3D image modeling [9], and a binary RNN structure is adopted in the state of the state encoding to take advantage of the long-term dependence between images. This is the first deep learning 3D image modeling method that outperforms JPEG compression efficiency at every bit rate point. However, the compression method cannot achieve arbitrary bit rate point compression, and the decoding process needs to be performed during the coding process to calculate the residual graph that needs to be compressed in the next iteration; so, the compression process is very time-consuming [10].Modeling framework end-to-end three-dimensional images is proposed, and this method adopts the convolutional encoder deep learning [11], including the analysis of nonlinear transformation, the quantizer, and nonlinear integrated transformation, in order to ensure that the training network gradient can reverse conduction, uniform quantizer adopts additive noise instead of integer quantization directly, and the entire model through a rate-distortion loss function is optimized. This method exceeds JPEG and JPEG2000 standard compression methods in terms of visual quality [12]. Later, researchers have done a lot of research on 3D image modeling based on autoencoder structure. The proposed decoder adopts subpixel operation for upsampling, which reduces the computational complexity of the network [13] and shows its structure. A soft-to-hard vector quantization method was proposed to solve the problem that quantization could not be differentiated in the end-to-end 3D image modeling model. As the local content of the image changes with the spatial position, a compression method is proposed to adjust according to the image content [14], and the importance map is introduced to assign different bit rates to different regions, so that the resulting image has clearer texture and edge.In recent years, three-dimensional structure modeling of monocular images has also been developing continuously. For example, the lightness method is used to derive three-dimensional structure based on the difference of light and shade of imaging objects on different surfaces at different distances under certain light intensity [15]. The breadth stereo vision method is based on the relationship between the gray value of each pixel in the image and the reflectivity, light source vector, and surface normals of the object surface [16]. The contour method reconstructs the structure model of the object by extending the camera light center at multiple angles to the line segment of the object contour in the picture to generate overlapping regions [17]. In addition, there are texture method, focal length method, and motion method [18]. However, most of the above monocular 3D image modeling methods still need multiple images for joint analysis; so, it is difficult to restore the object 3D structure from a single image of monocular image. Even after many refinements, such as the light and shade method, there is still a need for extremely high levels of illumination. Therefore, the existing monocular 3D structure modeling method is difficult to be directly applied to the shape modeling of single ceramic image. However, with the continuous development of image processing, combined with the characteristics of ceramic image shape, color, and decoration, many scholars have been deeply engaged in ceramic image analysis for many years. Traditional researches on ceramic image processing mainly focus on cultural relic intelligent recognition and key information extraction of ceramic image. For example, on ceramic surface often portrayed with history, art and social activities related to the grain proposed a method of automatic extraction of cultural relics of the colored drawing or pattern design, by extracting principal component images of cultural relics, and based on its target detection to extract the principal component striking image of the image, choose the maximum average gradient filter best principal component images and colored drawing or pattern of cultural relic of true color image fusion for the image [19]. A method based on visible spectral images of color cultural relics to realize the extraction of painting boundaries and analysis of pigment components is proposed to realize the function of extracting painting boundaries from images. This method accelerates the replication efficiency of mogao Grottoes cultural relics in Dunhuang and improves the quality of restoration [20]. Through the segmentation and processing of ceramic image, the texture feature information in the image is obtained, and the segmentation and extraction of ceramic texture feature are realized by using principal component analysis and morphological digital image processing methods, which lays a foundation for the management of digital museum and the extraction of ceramic decoration feature. Cui xuefei’s team combined digital image processing and pattern recognition to extract the color, texture, and other features of blue and white porcelain glaze and decoration and combined with the classifier to achieve the feature classification of blue and white porcelain decoration [21, 22]. In view of the difficulty in determining and measuring ceramic fragments by traditional archaeological methods, a dimensional analysis method based on the geometric and morphological characteristics of fragments was proposed to assist the restoration of ceramic fragments [23]. Through computer coding ceramic structure data [24], the Chinese ceramic structure database can be initially seen, but the sample size is small at present, which needs further improvement. The digital representation of the shape characteristics of skimming bowls was analyzed, and the structural information was extracted to provide auxiliary information for ceramic recognition and value recognition [25]. Combined with Kirsch operator and Canny operator, the detection of ceramic bowl surface defects is realized instead of manual detection, and the sorting accuracy of the designed sorting system reaches 95.3%. Meanwhile, the 3D reconstruction matching method based on multiple images is proposed to realize the 3D modeling of cultural relic surface, which has certain reference significance for cultural relics restoration [26]. Digital analysis means are used to make certain contributions to the convenience of image enhancement and instrument type edge extraction and curve fitting and further promote the process of ceramic scientific identification [27]. In addition, ergodic ceramic contour is used as the pattern feature combined with the pattern feature under the action of histogram to achieve specific classification by machine learning [28]. The slicing method was used to digitally model the bowl shape, and the multivariate statistical method was first used to determine the classification index of the bowl shape [29].According to ceramic image research status, there is no temporary systematic for single ceramic image analysis of the shape of 3D modeling in full research-related; therefore, this article learns from predecessors to image processing applications in ceramic, combined with the characteristics of ceramic artifact shape further mining realize ceramic image shape 3D high precision modeling of feasible research.


## 3. Ceramic Image Dating and 3D Image Modeling Scheme Based on Deep Learning

### 3.1. Design of 3D Image Modeling Scheme for Ceramic Ware

In the overall scheme design, both must consider image detection algorithm robustness and accuracy, also want to consider a 3D image modeling software platform of human-computer interaction problems, such as the operation should not only visually display three-dimensional shape reduction process, and also want to consider performance that is concise and convenient operation; thus, for ceramic modeling of 3D images, a comb design in the following general scheme is shown in Figure1. It includes hardware image acquisition, algorithm research, and software implementation.Figure 1
Overall scheme structure of ceramic image shape 3D image modeling.The image acquisition module is used for the 3D image modeling by acquiring various ceramic images. The image data is generally provided by users, and the sources are not limited to the rotating ceramic images obtained by cameras, mobile phones, and other imaging devices. The robustness of the proposed algorithm is verified by testing image data at different shooting distances and angles. During the test, the algorithm is analyzed by reading images from users, and the corresponding 3D model is generated by software interaction. Algorithm part mainly from all the key steps of 3D image modeling process, the technical difficulties, combining with the above design, satisfies the requirement of reduction of image processing algorithms, including image preprocessing, image distortion correction, shape contour line modeling and porcelain ware four steps, and 3D image modeling of ceramic two-dimensional image of three-dimensional shape extraction process. In this paper, MATLAB is used as the algorithm research platform to complete the algorithm part of the simulation problem to verify the feasibility and rationality of the overall algorithm.


### 3.2. Design of 3D Image Modeling Scheme for Ceramic Ware

Pixel CNN network has achieved good performance in image generation and image restoration by predicting the probability distribution of image pixels. Pixel CNN decomposed the probability density distribution t of image X into conditional probability distribution, which can realize more flexible conditional probability function.(1)ft=ft1∗ft2∗⋯ft∣i−1t1,t2⋯ti.In pixel CNN, the dependent order between pixels adopts raster scan order, that is, scan row by row and scan pixel by pixel within each row. The probability distribution of each pixel depends only on the pixels above and to the left of it, not on any other pixels. The generator converts the random noise matrix into an image. The goal is to generate results as close to the original data as possible to deceive the discriminator. The discriminator’s goal is to distinguish the generator’s composite image from the actual training sampleft. The two networks work in an interactive mechanism, generator. In this way, generator and discriminator form a dynamic game process, and the relation between generator C and discriminator F can be defined as
(2)maxVC,F=Exlogxft+EC−1logx1−CF.To model the entropyfz of each subband coefficient, we decompose the probability distribution Pz of the subband coefficients into the product of conditional probability distributions.
(3)fz=∏tnfzi∣zi−1.The scanning order of the coefficients of the three-dimensional wavelet subband is raster scanning order. We use the outputFz of the 3D context entropy coding model to estimate each term:
(4)fi,lz=fzl=cl∣zi⋯z1.The coding rate required is the crossentropy between the real distribution of the coefficient and the estimated distribution. The distribution is the output of the 3D context entropy coding network using the sum of crossentropy to calculate the coding code length of each subband.(5)Csum=∏ilnfzi∣z1,⋯,zi−1.For each subband wavelet coefficientP, we design a network that the entropy of each subband coding model is not shared, by P output calculation of each subband code length, and then calculate all subband code; the sum of all the code is divided by the total number to obtain the sum of all the coding required rate, where n said subband indexes, H, W, and D are the height, width, and depth of the input image, respectively. Given the wavelet transform coefficient of 3D brain map, the entropy coding network P in the subband is optimized by finding the minimum value, so as to reduce the bit rate required to encode the wavelet transform coefficient as much as possible, thus improving the compression efficiency of JP3D.
(6)R=∑i=1nCsumiH−1⋅D−1⋅2W.The above is a dichotomous problem in two-dimensional plane space. Assuming that the dividing line to solve the problem cannot be found in two-dimensional space, it will be extended to three-dimensional space, and an appropriate classification method will be found by establishing the dividing surface. If the classification cannot be achieved in three-dimensional space, it will be extended to higher-dimensional space until a hyperplane is found to achieve the classification purpose. Inn-dimensional space, hyperplane D is defined as
(7)D=∑i=1nfixi.The ultimate goal is to find a hyperplane that is the same distance from one side of the boundary as the closest point on the other side. Inn-dimensional space, the distance from the point to the hyperplane is calculated as follows:
(8)W=∑i=1nfixi∑i=1nfi2.After the coordinates and coefficients of each point are vectorized, the distance formula is(9)D=1W∣wx+b∣.The next step is to find the hyperplane with the largest boundary. The specific idea is to transform into a limited convex optimization problem and then use KKT condition and Lagrange formula to deduce(10)dX=∑ixififT+Bi.In the coordinates and coefficients of each pointz, the new decision hyperplane mapping is
(11)DW=WZ+B0.


### 3.3. 3D Image Modeling Algorithm for Ceramic Image

See Figure2. Firstly, the 2D ceramic images captured by the camera are preprocessed based on machine vision technology, the image is denoised, and the edge is extracted. At the same time, according to the perspective image distortion phenomenon by reductive true under the relative size of the image distortion correction algorithm view, after extracting the lateral boundary of the image information, the use of a fitting method obtains rotator porcelain ware edge contour model, and each point on the contour model located rotates to obtain three-dimensional model and generates the corresponding three-dimensional digital model.Figure 2
3D image modeling algorithm flow of ceramic shape deep learning.In practice, the nearest neighbor interpolation method only takes the pixel nearest to the sampling point as the pixel value of the sampling point without considering the influence of the surrounding pixels, which is easy to cause the discontinuous change of the gray value of the image after the image size normalization, resulting in the serious loss of image quality, such as Mosaic and sawtooth. And the bilinear interpolation method is based on sampling points around the pixel do a weighted average of four pixels, overcomes the nearest neighbor interpolation method of gray discontinuity problems, but only consider the four adjacent points, not considering the gray value of each between adjacent points influence each other, and will cause the kind of low-pass filtering effect, after the scaling of the high frequency component images have a certain loss. The edge position and contour position of the image have a certain fuzzy effect, which is also not conducive to subsequent processing. Law of double three interpolation uses sampling point around 16 pixels of the pixel rate and bilinear relation common calculating the pixel values of sample points, while increasing the amount of calculation of the algorithm, to a certain extent, but it can be completely overcome in the nearest neighbor interpolation and bilinear interpolation method, the deficiencyz of the image edge smooth, and has the highest calculation accuracy at the same time. Therefore, the image size normalization method based on bicubic interpolation algorithm is adopted in this paper. Its corresponding function is
(12)fz=z+2z2−z+3z3+z+5z5.Obtain the weight coefficients ofi,j against x,y and apply the same method to other fifteen neighboring pixels to obtain the weight coefficients of all sixteen adjacent pixels relative to the sampling points, and then the final weighted sum formula is expressed as
(13)fx,y=∑i∑jKi,jfi−t,j−t.According to the relationship between noise and research object, noise signal can be divided into additive noise and multiplicative noise. Here, the superposition formula of the two types of noise is directly given:(14)Wi,j=gi,j+Ni,j.Among them, LOG can solve the problem that the second derivative will also respond obviously to noise, which can reduce the interference of noise while eliminating better sharpening effect. The principle is to use smoothing filter to smooth the noisy image and then sharpen the edges and details. Therefore, the Gaussian smoothing operator with excellent performance in the smoothing field is combined with the Laplace operatort with outstanding performance r in the sharpening field to obtain the Gauss Laplace operator ht, and the specific form is as follows:
(15)ht=t2−γ2γ4eγ2.The target subject and background position of the resulting mask image obtained by preliminary processing are basically accurate; so, it only needs to further refine and optimize the edge part of the image. In order to protrude the edge area, the initial mask image is processed into a three-color map, the foreground background is separated again, and the uncertain edge part is separately classified as gray area. After obtaining the mask image, an improved image matting method based on the closed solution algorithm is carried out to optimize the effect of target edge segmentation.The network updates the weight of the network according to the errorE between the real data and the predicted data. When the error reaches the set range, the network calculation is finished, and a trained network structure is generated. The deep learning fitting effect is good, but its network model represents the corresponding relationship between input and output through weight parameters, and cannot obtain the expression of fitting curve, which is not conducive to digital expression of ceramic shape structure. The above three curve fitting algorithms each have their own advantages and application limitations. After comprehensive analysis in this paper, the fitting algorithm based on the least square method is finally determined to build the best ceramic side edge contour model, and the specific process is as follows:First, standard data acquisition: after pretreatment, the angle of view of ceramic side edge has been corrected to obtain accurate ceramic side edge data, which is used as the real data of ceramic type.The specific data processing process is as follows:In the first step, the ellipse information of the upper bottle mouth and lower foot of the ceramic has been detected. The blue dots in the figure are the four ends of the ellipse, which are taken as the starting and ending points of the side edge contour.The second step is to calculate the midpoint of the upper and lower line segments by using the coordinates of the four endpoints. The straight line segment connecting the two midpoints is the central axis of the rotating ceramic.Finally, the line with the central axis is taken as the horizontal axis of the edge contour, and the radius data of the half-side ceramics is selected as the vertical axis data.


## 3.1. Design of 3D Image Modeling Scheme for Ceramic Ware

In the overall scheme design, both must consider image detection algorithm robustness and accuracy, also want to consider a 3D image modeling software platform of human-computer interaction problems, such as the operation should not only visually display three-dimensional shape reduction process, and also want to consider performance that is concise and convenient operation; thus, for ceramic modeling of 3D images, a comb design in the following general scheme is shown in Figure1. It includes hardware image acquisition, algorithm research, and software implementation.Figure 1
Overall scheme structure of ceramic image shape 3D image modeling.The image acquisition module is used for the 3D image modeling by acquiring various ceramic images. The image data is generally provided by users, and the sources are not limited to the rotating ceramic images obtained by cameras, mobile phones, and other imaging devices. The robustness of the proposed algorithm is verified by testing image data at different shooting distances and angles. During the test, the algorithm is analyzed by reading images from users, and the corresponding 3D model is generated by software interaction. Algorithm part mainly from all the key steps of 3D image modeling process, the technical difficulties, combining with the above design, satisfies the requirement of reduction of image processing algorithms, including image preprocessing, image distortion correction, shape contour line modeling and porcelain ware four steps, and 3D image modeling of ceramic two-dimensional image of three-dimensional shape extraction process. In this paper, MATLAB is used as the algorithm research platform to complete the algorithm part of the simulation problem to verify the feasibility and rationality of the overall algorithm.


## 3.2. Design of 3D Image Modeling Scheme for Ceramic Ware

Pixel CNN network has achieved good performance in image generation and image restoration by predicting the probability distribution of image pixels. Pixel CNN decomposed the probability density distribution t of image X into conditional probability distribution, which can realize more flexible conditional probability function.(1)ft=ft1∗ft2∗⋯ft∣i−1t1,t2⋯ti.In pixel CNN, the dependent order between pixels adopts raster scan order, that is, scan row by row and scan pixel by pixel within each row. The probability distribution of each pixel depends only on the pixels above and to the left of it, not on any other pixels. The generator converts the random noise matrix into an image. The goal is to generate results as close to the original data as possible to deceive the discriminator. The discriminator’s goal is to distinguish the generator’s composite image from the actual training sampleft. The two networks work in an interactive mechanism, generator. In this way, generator and discriminator form a dynamic game process, and the relation between generator C and discriminator F can be defined as
(2)maxVC,F=Exlogxft+EC−1logx1−CF.To model the entropyfz of each subband coefficient, we decompose the probability distribution Pz of the subband coefficients into the product of conditional probability distributions.
(3)fz=∏tnfzi∣zi−1.The scanning order of the coefficients of the three-dimensional wavelet subband is raster scanning order. We use the outputFz of the 3D context entropy coding model to estimate each term:
(4)fi,lz=fzl=cl∣zi⋯z1.The coding rate required is the crossentropy between the real distribution of the coefficient and the estimated distribution. The distribution is the output of the 3D context entropy coding network using the sum of crossentropy to calculate the coding code length of each subband.(5)Csum=∏ilnfzi∣z1,⋯,zi−1.For each subband wavelet coefficientP, we design a network that the entropy of each subband coding model is not shared, by P output calculation of each subband code length, and then calculate all subband code; the sum of all the code is divided by the total number to obtain the sum of all the coding required rate, where n said subband indexes, H, W, and D are the height, width, and depth of the input image, respectively. Given the wavelet transform coefficient of 3D brain map, the entropy coding network P in the subband is optimized by finding the minimum value, so as to reduce the bit rate required to encode the wavelet transform coefficient as much as possible, thus improving the compression efficiency of JP3D.
(6)R=∑i=1nCsumiH−1⋅D−1⋅2W.The above is a dichotomous problem in two-dimensional plane space. Assuming that the dividing line to solve the problem cannot be found in two-dimensional space, it will be extended to three-dimensional space, and an appropriate classification method will be found by establishing the dividing surface. If the classification cannot be achieved in three-dimensional space, it will be extended to higher-dimensional space until a hyperplane is found to achieve the classification purpose. Inn-dimensional space, hyperplane D is defined as
(7)D=∑i=1nfixi.The ultimate goal is to find a hyperplane that is the same distance from one side of the boundary as the closest point on the other side. Inn-dimensional space, the distance from the point to the hyperplane is calculated as follows:
(8)W=∑i=1nfixi∑i=1nfi2.After the coordinates and coefficients of each point are vectorized, the distance formula is(9)D=1W∣wx+b∣.The next step is to find the hyperplane with the largest boundary. The specific idea is to transform into a limited convex optimization problem and then use KKT condition and Lagrange formula to deduce(10)dX=∑ixififT+Bi.In the coordinates and coefficients of each pointz, the new decision hyperplane mapping is
(11)DW=WZ+B0.


## 3.3. 3D Image Modeling Algorithm for Ceramic Image

See Figure2. Firstly, the 2D ceramic images captured by the camera are preprocessed based on machine vision technology, the image is denoised, and the edge is extracted. At the same time, according to the perspective image distortion phenomenon by reductive true under the relative size of the image distortion correction algorithm view, after extracting the lateral boundary of the image information, the use of a fitting method obtains rotator porcelain ware edge contour model, and each point on the contour model located rotates to obtain three-dimensional model and generates the corresponding three-dimensional digital model.Figure 2
3D image modeling algorithm flow of ceramic shape deep learning.In practice, the nearest neighbor interpolation method only takes the pixel nearest to the sampling point as the pixel value of the sampling point without considering the influence of the surrounding pixels, which is easy to cause the discontinuous change of the gray value of the image after the image size normalization, resulting in the serious loss of image quality, such as Mosaic and sawtooth. And the bilinear interpolation method is based on sampling points around the pixel do a weighted average of four pixels, overcomes the nearest neighbor interpolation method of gray discontinuity problems, but only consider the four adjacent points, not considering the gray value of each between adjacent points influence each other, and will cause the kind of low-pass filtering effect, after the scaling of the high frequency component images have a certain loss. The edge position and contour position of the image have a certain fuzzy effect, which is also not conducive to subsequent processing. Law of double three interpolation uses sampling point around 16 pixels of the pixel rate and bilinear relation common calculating the pixel values of sample points, while increasing the amount of calculation of the algorithm, to a certain extent, but it can be completely overcome in the nearest neighbor interpolation and bilinear interpolation method, the deficiencyz of the image edge smooth, and has the highest calculation accuracy at the same time. Therefore, the image size normalization method based on bicubic interpolation algorithm is adopted in this paper. Its corresponding function is
(12)fz=z+2z2−z+3z3+z+5z5.Obtain the weight coefficients ofi,j against x,y and apply the same method to other fifteen neighboring pixels to obtain the weight coefficients of all sixteen adjacent pixels relative to the sampling points, and then the final weighted sum formula is expressed as
(13)fx,y=∑i∑jKi,jfi−t,j−t.According to the relationship between noise and research object, noise signal can be divided into additive noise and multiplicative noise. Here, the superposition formula of the two types of noise is directly given:(14)Wi,j=gi,j+Ni,j.Among them, LOG can solve the problem that the second derivative will also respond obviously to noise, which can reduce the interference of noise while eliminating better sharpening effect. The principle is to use smoothing filter to smooth the noisy image and then sharpen the edges and details. Therefore, the Gaussian smoothing operator with excellent performance in the smoothing field is combined with the Laplace operatort with outstanding performance r in the sharpening field to obtain the Gauss Laplace operator ht, and the specific form is as follows:
(15)ht=t2−γ2γ4eγ2.The target subject and background position of the resulting mask image obtained by preliminary processing are basically accurate; so, it only needs to further refine and optimize the edge part of the image. In order to protrude the edge area, the initial mask image is processed into a three-color map, the foreground background is separated again, and the uncertain edge part is separately classified as gray area. After obtaining the mask image, an improved image matting method based on the closed solution algorithm is carried out to optimize the effect of target edge segmentation.The network updates the weight of the network according to the errorE between the real data and the predicted data. When the error reaches the set range, the network calculation is finished, and a trained network structure is generated. The deep learning fitting effect is good, but its network model represents the corresponding relationship between input and output through weight parameters, and cannot obtain the expression of fitting curve, which is not conducive to digital expression of ceramic shape structure. The above three curve fitting algorithms each have their own advantages and application limitations. After comprehensive analysis in this paper, the fitting algorithm based on the least square method is finally determined to build the best ceramic side edge contour model, and the specific process is as follows:First, standard data acquisition: after pretreatment, the angle of view of ceramic side edge has been corrected to obtain accurate ceramic side edge data, which is used as the real data of ceramic type.The specific data processing process is as follows:In the first step, the ellipse information of the upper bottle mouth and lower foot of the ceramic has been detected. The blue dots in the figure are the four ends of the ellipse, which are taken as the starting and ending points of the side edge contour.The second step is to calculate the midpoint of the upper and lower line segments by using the coordinates of the four endpoints. The straight line segment connecting the two midpoints is the central axis of the rotating ceramic.Finally, the line with the central axis is taken as the horizontal axis of the edge contour, and the radius data of the half-side ceramics is selected as the vertical axis data.


## 4. Example Verification

Based on MATLAB platform, the simulation and debugging of 3D image modeling algorithm of rotary ceramic image are realized. Taking the two-dimensional image of the common jade pot spring vase as the restoration object, the complete restoration process of ceramics from two-dimensional image to three-dimensional model is displayed in detail. Through the steps of contour noise reduction, sharpening, and enhancement, angle distortion correction, side edge contour curve modeling, and 3D rotation modeling, the 3D image modeling of ceramic shape was completed. Restore steps are shown in Figure3.Figure 3
Steps of three-dimensional image modeling of jade pot spring bottle.Due to the strong information independence among all feature quantities and the differences in the time distinction of each feature quantity, the fusion of all feature quantities is helpful to give full play to the distinguishing advantages of each feature quantity. Figure4 shows the time distinction of each feature quantity in the form of establishing spatial scatter diagram. It can be seen from the figure that the extracted characteristic parameters have a good ability to distinguish the Yuan, Ming, and Qing dynasties. Therefore, on the premise of ensuring the independence and completeness of the feature quantity, the fusion of multidimensional features is helpful to improve the accuracy of dating.Figure 4
Scatter diagram of characteristic parameters of Yuquan bottles in Ming and Qing Dynasties.
(a)
Ming(b)
QingAccording to the distribution differences of various features in different dynasties shown in Figure4, it can be found that the shape structure of Jutong spring bottles has a development law from the slender body in Yuan Dynasty to the beautiful and graceful, round, and comfortable in Ming and Qing dynasties. Specifically, the minimum radius and the height of the neck of Yuhuchun in Yuan Dynasty are the minimum; that is, the neck is long and thin, which reflects the characteristics of the bottle shape of Yuhuchun in Yuan Dynasty. Compared with the Yuan Dynasty, the mouth diameter of the Ming Dynasty jade huochun bottles was smaller, while the size of other characteristics was larger than that of the Yuan Dynasty, reflecting the overall shape of the Ming Dynasty jade Huochun bottles rounded, tended to be rich characteristics. Compared with the Ming Dynasty, the shape of the spring vase in Qing Dynasty did not change much, but the minimum radius of the neck and the maximum radius of the abdomen were larger than that in Yuan and Ming dynasties; so, the abdomen of the spring vase in Qing Dynasty was more round, showing the overall shape characteristics of bulging abdomen, short, and thick.CNN network was trained with 1240 ceramic sample images of four categories, and the training process was iterated 2400 times. In order to reduce GPU computing pressure, the loss function of the training set and verification set loss (and the accuracy of the verification set) are calculated every 12 iterations, and the ratio of the correct number of tags to the total number of tags is predicted. The results are shown in Figure5:Figure 5
Loss and accuracy curves.As can be seen from Figure5, the curve of train loss (train loss) of the training set rapidly attenuated and stabilized at about 0.04, and the verificationsetloss<valloss finally stabilized at about 0.13, which was not much different from the training set, indicating that CNN network had a good convergence effect and strong ability to inhibit overfitting. At the same time, the classification and dating accuracy of the CNN network obtained from the verification set can reach 97.17%.Due to the limitation of GPU memory, the 3D ceramic image of original size was cut into 1060 image cubes of128×128×32 as the test data of the compression method proposed in this paper. The contents of the test images with the two resolutions were identical. The original JP3D compressed brain images could be obtained by stitching the brain image cube with the resolution of 128×128×32. JP3D has higher compression efficiency in large-size original resolution images. As can be seen from Figure 6, JP3D’s compression efficiency in large-size images is better than that in small-size images. Figure 6 shows PSNR results at the same bit rate, and Figure 6 shows SSIM results at the same bit rate. We compare the performance of JP3D on raw size images with that of 3D image compression based on deep learning on small size image cubes.Figure 6
Rate distortion curves of JP3D compression on two image sizes.For the training data of the 2D image compression method based on deep learning, we adopt the same training data as that of the 3D compression method, but disassemble the 3D training data of the 3D method into 2D image data. The test data is obtained in the same way, and the image content of the test data is exactly the same as that of the 3D compression method. As shown in Figure7, compared with the 3D image compression method, the PSNR value of the 2D image compression method at lower bit rate points decreased by more than 1 dB, and SSIM measurement index also decreased greatly, because the 3D convolution and other operations of the 3D image compression method can make use of the correlation of depth dimension direction in the 3D image. The experimental results prove the effectiveness of the 3D image compression method and the necessity of extending the 2D image compression method based on deep learning to 3D.Figure 7
Comparison of results of 3D and 2D image modeling methods based on deep learning.


## 5. Conclusion

A 3D image modeling algorithm based on ceramic image shape was proposed. According to the process steps of image processing and the characteristics of rotating ceramic imaging, a targeted image processing algorithm was designed. In the preprocessing stage, the image shape edge contour is extracted accurately by filtering and denoising, wavelet enhancement, and morphological processing. Then, the angle distortion is corrected adaptively for the upper and lower ellipses extracted from the ceramic contour of the rotating body. Then, the BP neural network modeling was used to extract the side edge contour. Finally, the ceramic shape 3D model was obtained according to the four corner points determined by the contour curve and the central axis rotation. The experiment proved that the algorithm in this paper has high accuracy compared with the standard data of 3D scanner point cloud. The image segmentation technology is studied to realize the automatic segmentation of the target image, the edge of the target image is optimized, then the 3D geometric feature information of the image is extracted by mathematical method, and finally, the process of the 3D model is reconstructed by mathematical method according to the obtained feature information. A set of methods and strategies for 3D reconstruction of target ceramic images are summarized for ceramic manufacturing industry. Based on deep study of ancient ceramic cohort model based on the training sample image enhancement processing parameter optimization, although the overall cohort accuracy is higher, but the training sample and types is relatively short, follow-up still needs further accumulation of ancient ceramic digital sample library, expands rich sample space, and further improves the generalization capability of the feedforward neural network model and the actual ground push algorithm application.



---

*Source: 4343255-2021-10-29.xml*