Abstract
The original similarity measurement model is easy to ignore the processing of image details, resulting in poor accuracy of similarity measurement. In the paper, we propose a similarity measurement model for the medical image feature matrix based on the convolutional neural network (CNN). First, the Gaussian convolution kernel is used to obtain the global and local feature data of medical images, and the corresponding data set is formed. Second, the convolution layer of CNN is introduced, and the image feature matrix is obtained by the convolution layer. Finally, the similarity measurement model of the medical image feature matrix is constructed. The results show that the image similarity measurement effect of this model is better when the test process is divided into three parts: global, local, and detail. The highest error rate of the proposed algorithm is only about 0.21, which takes less time, and the overall fitting degree can reach about 91%. Compared with traditional methods, the accuracy of image similarity measurement is higher and the use effect is better.
1. Introduction
With the continuous development of visualization technology and computer graphics, the research on the medical image is also deepening. The basis of medical image research is feature analysis. Therefore, at present, taking medical images as the research object, the integration of research on the extraction method of medical image feature points has become a hot research direction [1]. At the same time, there have been many studies on the similarity measurement of image features, which provide more useful information for the in-depth analysis and application of medical images. Many achievements have been made in medical image feature analysis and similarity measurement at home and abroad. Abdar et al. [2] proposed a medical image classification and fusion model, which mainly uses the binary residual feature fusion method to solve the uncertainty of the algorithm. This method makes a detailed analysis of the medical image features and obtains a good image classification effect. However, this method takes a long time; Shu et al. [3] proposed an initial spatial convolution block to collect the context information related to the decoding stage, extract and accumulate features from different paths and establish associations between structural features and semantic features for medical image segmentation. However, the practical applicability of this method is relatively weak. Poudel and Lee [4] established a multi-scale global feature map and used the attention mechanism to suppress noise and bad features, resulting in the complete recovery of context feature dependence, and completed the feature extraction of medical images, which has a high recall and precision. However, it takes a long time. Wenping et al. [5] proposed an improved random walk node similarity measurement method: a random walk similarity measurement method based on relative entropy. The transition probability distribution of the node is constructed according to the transition probability of the node arriving at the influential node in the network after the multi-step random walk. The relative entropy of the transition probability distribution of two nodes is calculated to obtain the difference score between node pairs in the network. Then the similarity matrix between network nodes is obtained. RE-model algorithm performs well in symmetry, network propagation, and community discovery, but the measurement effect is not ideal. Feng, et al. [6] established the isometric isomorphism model of multi-scale spatial entities from the viewpoint of metric geometry. The geometric and topological similarity measurement of graphics is expressed in multiple scales for planar and linear spatial entities with different complexities. This method can simultaneously take into account the changes in geometry and topology of multi-scale spatial entities and conform to the multi-scale abstraction law of spatial entities, but the similarity measurement takes a long time. Wang et al. [7] proposed a spatiotemporal trajectory similarity measurement method using Hausdorff distance. Starting from the three features of spatiotemporal trajectory, a spatiotemporal trajectory reorganization strategy for similarity measurement is proposed. The traditional idea of similarity measurement with a point as the center is changed to track segment as the center, and the track spatiotemporal clustering experiment is carried out with micro-blog check-in track data and taxi GPS track data. This method can effectively calculate the similarity of spatiotemporal trajectories and meet the needs of spatiotemporal trajectories clustering, but the measurement accuracy is not ideal.
The original similarity measurement method is easy to ignore the analysis of image details, resulting in unsatisfactory calculation results. Therefore, this paper proposes a similarity measurement model of the medical image feature matrix based on CNN. Starting from the global and local, the feature points of the medical image are extracted in an orderly, and CNN is introduced to construct the feature matrix, to complete the construction of the medical image feature matrix similarity measurement model. To ensure the use effect of the similarity measurement model based on CNN designed in this study, after the model is built, the test analysis method is used to verify the model in this paper. The contributions of this paper are as follows: (1) Starting from the global and local, the feature points of medical images are extracted orderly, taking into account the details of medical images, which provides the basis for improving the accuracy of the algorithm calculation; (2) CNN is used to construct the similarity measurement model of the feature matrix to improve the performance of the model; (3) Using different data sets, the performance of this model is tested under different indicators to verify the efficiency of this model.
2. Proposed Model
2.1. Acquired Feature Matrix of Medical Images
Image features can be divided into global features and local features. The former mainly reflects the statistical information of the image, while the latter describes the image as a whole based on local structure, texture, and other details [8, 9]. Aiming at the deficiency of the original similarity measurement model, the acquisition of the image feature matrix is optimized to ensure the effectiveness of acquiring image feature information. In the process of image feature acquisition, scale-invariant feature mode is selected to extract the relevant information in a medical image. This method can deal with translation, rotation, scaling, brightness change, and other external factors. It also maintains certain stability for visual changes and applies to the scaling and rotation changes of human organs in the medical image [10].
A medical image equalization algorithm with segmentation factors is introduced. Firstly, the medical image of the input image is divided into two sub-medical images according to the threshold. In this process, the average brightness of the output image is retained, and the disadvantage of brightness drift of the output image is overcome. Suppose the input image is , the medical image of the grayscale of the input image is defined aswhere is the frequency of the grayscale pixel in the image, and is the highest grayscale in the image. The probability density function of image is
According to the threshold , the medical image grayscale of the input image is divided into two parts: low square and high-quality medical image, which are expressed by and . The range of their grayscale is and . Probability density function of sub medical image and are the total number of pixels in low-quality medical image area and high-quality medical image area. The probability density function of a medical image is shown in (3) and (4):
As mentioned in the introduction, the literature [4] method emphasizes the high-frequency pixels of the image, which is easy to cause the loss of details of the output image, and the phenomenon that the low-frequency pixels are swallowed by the adjacent high-frequency pixels. Through equations (6) and (7), the modified medical image equalization algorithm modifies the low-quality medical image and the high-quality medical image and overcomes the problems of the literature [4] method.
Medical image equalization is the last step to modify the medical image equalization algorithm. The cumulative probability density function for medical image equalization in the literature [4] algorithm is .
The transformation function is used to remap the grayscale k of the input image. The definition of the transformation function is shown in the following equation:where and are the minimum value and the maximum value of the image grayscale. From (9), it can be seen that the grayscale of the input image through the literature [4] method is remapped to the entire dynamic range .
Consistent with the literature [4] method, the sub-medical image equalization equation of the modified medical image equalization algorithm is shown in (10). The medical image of the modified grayscale can be regarded as the cropped pixels that are reassigned to the medical image before the medical image is equalized. Finally, the final enhanced image is obtained by equalizing the sub-medical image.
The modified medical image equalization algorithm enhances the input image through medical image segmentation, correction, and equalization. Compared with the literature [4] algorithm, the modified medical image equalization algorithm has a higher signal-to-noise ratio on the premise of preserving image details.
The image size of the medical image is set under different sizes, which can be obtained by convolution of the original image and Gauss:where is the original position of the image, is the scale spatial factor, is the two-dimensional Gaussian function, is the original medical image, and is the spatial scale of the medical image. When acquiring feature points of medical images, the DoG operator [11] is used to process medical images. The operator can be expressed as
This operator is used to calculate the points on the image, and the calculated values are connected to obtain the eigenvalue curve of the image [12, 13]. Then, the fitting function is used to accurately obtain the position and scale of image feature points, and unstable feature points are removed, to enhance the stability and antimanufacturing ability of image feature points, as shown in Figure 1.

Following the above process, feature points of medical images are extracted orderly, and the feature points in the images are integrated and stored in the medical image database [14].
2.2. Modeling of Similarity Measurement for the Constructing Medical Image Feature Matrix
According to the medical image features acquired in 2.1, the CNN is used to construct the medical image feature matrix, which is used as the basis of the measurement model.
In this study, CNN is used to classify the extracted feature points. This part is mainly related to the convolution layer of the neural network [15]. Therefore, the image data processing process of the convolution layer in this model is set as follows:where and refer to the image information to be processed, and is the convolution calculation symbol. To improve the accuracy of feature classification, a Gaussian convolution [16, 17] check is used to process the image data in this part, and the classification results of feature points are obtained. The processing results are output in the form of a matrix.
Suppose the output feature points matrix is set as a set, then , in which refers to the number of medical images [18], and refers to the feature matrix corresponding to the medical image . Then the similarity measurement equation of the image matrix can be obtained by using Mahalanobis distance:where is the measurement time, is the corresponding feature vector in the image , , is the distance from image to image . The more similar the two are, the smaller the value of is. In this model, is the similarity measurement matrix of two images [19]. To ensure the validity of its numerical value, it is set as a symmetric positive definite matrix .where is the feature quantity of image classification.
Then the characteristics of the above equation can be reflected as
Integrate (14) and (16) to obtain the following similarity measurement model, as follows:
To prevent the above equation from overfitting during image processing [20], it is rewritten aswhere is the model constraint, is the measurement model component. Then the final model processing equation iswhere is the optimal similarity measurement model, is constraint condition of the subject, is the constraint condition of the main feature, and is regular constraint. For the optimization of this model, it is necessary to solve many of the above items. Therefore, in the process of calculation, the above equation should be used for nonlinear problem planning, to obtain the optimal similarity measurement model.
This part is connected with the abovementioned medical image feature extraction part to complete the construction process of the feature similarity measurement model of the medical image. So far, the similarity measurement model of the medical image feature matrix based on CNN has been designed, as shown in Figure 2.

3. Experimental Analysis and Results
3.1. Data Sets and Evaluating Indicator
MURA data set and MRNet data set were used for analysis. MURA data set: one of the largest X-ray database at present, there are a large number of muscle and bone X-ray images, including shoulder, humerus, elbow, forearm, wrist, palm, and fingers. The images in this dataset are manually marked by doctors. MRNet data set: this data set is the MRI data of the knee joint, including 1370 MRI images and 1104 abnormal examination images such as anterior cruciate ligament tear and meniscus tear, which is suitable for the analysis and research of medical image features. From the above two data sets, one thousand medical image data are selected as the data source. First, the selected data are preprocessed to avoid noise, redundant information, and other interference, and then two thousand data are divided into 4 points for cross-validation. The performance of this model is fully verified through many experiments.
The test platform used in this test consists of two parts. Because of the particularity of the signal of the medical image acquisition site, the medical image acquisition equipment cannot take real photos. Therefore, it only shows the same prototype as the test equipment. To ensure the effectiveness of this test, the first step of this experiment is the global similarity measurement of medical images. In the second part, the local comparison is used to improve the detail of the design model test in this paper.
Error rate: in the calculation of medical image feature data, the function objective is optimized through spatial constraints. To verify the accuracy of the proposed method, the error rate is selected as an index for comparative analysis.
Measurement time: to verify the classification efficiency of the proposed method, the classification time in different iteration times is selected as the indicator.
Fitting degree of measurement: to verify the accuracy of the method, a section of data is input and different methods are selected for fitting degree analysis. The fitting degree directly determines the classification performance of the method.
3.2. Results and Discussion
In this test, any image is selected as the key image of similarity measurement, and the methods in Literature [2], Literature [3], Literature [4], and the design model in this paper are used to perform similarity measurement on the images in the image database and obtain similar images. Through the image extraction results, the differences between the methods in Literature [2], Literature [3], Literature [4], and the design model in this paper are obtained, as shown in Figure 3.

Through the above settings, the image extraction results of literature [2] method, literature [3] method, literature [4] method, and the design model in the paper are shown in Figure 4.

(a)

(b)

(c)

(d)
According to the above experimental results, the simulation measurement accuracy of the design model in this paper is better than that of the methods in Literature [2], Literature [3], and Literature [4]. Similar medical images with high accuracy can be obtained by using the model designed in this paper. The methods in Literature [2], Literature [3], and Literature [4] have poor accuracy for image similarity measurement and cannot extract all medical images with feature information in the database.
The universal joint graph is selected as the test sample for local test. It is known that there are 150 images with the following joint characteristics in the database. The design model in this paper and the methods in Literature [2], Literature [3], and Literature [4] are used to perform similarity measurement on the image data in the database to extract images with the same features. In this part of the test, the above step is repeated for a total of 5 times, and the accuracy of image extraction is calculated, as shown in Figure 5.

The following test results are obtained through multiple experiments. To ensure the effectiveness of the test results, only two decimal places of the calculation results are reserved, as shown in Table 1.
According to Table 1. In the local similarity measurement test, the image extraction accuracy of the design model in this paper is better than that of the methods in Literature [2], Literature [3], and Literature [4]. It has a high similarity measurement ability for the images in the medical image database. By integrating the experimental results of the above two parts, it can be seen that the similarity measurement model of the medical image feature matrix based on CNN designed in this paper can achieve good results in both global similarity measurement and local similarity measurement. Therefore, the similarity measurement model of the medical image feature matrix based on CNN designed in this paper is better than the methods in Literature [2], Literature [3], and Literature [4] and has higher measurement accuracy, as shown in Figure 6.

The features extracted in this test are shown in the circle in Figure 6. Through the above settings, the methods in Literature [2], Literature [3], Literature [4], and the image extraction results of the design model in this paper are shown in Figure 7.

(a)

(b)

(c)

(d)
It can be seen from the above experimental results that the detail processing effect of the design model in this paper is better than that of the methods in Literature [2] and Literature [3]. The image of small details can be effectively obtained by using the model designed in this paper. The methods in Literature [2] and Literature [3] have a poor effect on obtaining the details of the image and cannot obtain the image consistent with the details of the test image.
To test the accuracy of this method in similarity measurement of medical image features, the proposed method is compared with the traditional methods in Literature [2], Literature [3], and Literature [4]. With 200 medical images used in the database, four methods are used to analyze the error rate, As shown in Figure 8.

As can be seen from Figure 8, the error rate of the method proposed in this paper is smaller than that of the other three methods in different iteration times. The highest error rate is only about 0.21, and the minimum error rate can be 0.01. The decrease in error rate is the largest. The minimum error rate of literature [2] method, literature [3] method, and literature [4] method is also between 0.03 and 0.05. Therefore, the proposed method has obvious advantages in the accuracy of image feature detection.
To further verify the measurement efficiency of the proposed method, the measurement time is taken as the experimental index to compare the four methods. In the experiment, 200 medical images in the database are selected, and the number of iterations is 30, as shown in Figure 9.

According to Figure 9, the measurement time of the method proposed in this paper is the lowest at the 10th iteration, only about 25 s, and the highest at the 25th iteration, about 43 s. However, the minimum time of the method in Literature [2], Literature [3], and Literature [4] is 73 s, 71 s, and 43 s, respectively, which are higher than the maximum time of the proposed method. And the measurement time variation of this method is smaller than that of the other three methods. Therefore, it can be considered that the proposed method has high measurement efficiency.
Taking the fitting degree as the test index, the comparative experiments of the four methods are performed. The experimental results obtained according to the experimental indexes in Section 3.1 are shown in Figure 10.

Figure 10 shows that the fitting degree of the proposed method in this paper is the highest among the four methods, which can reach about 91%, and it reaches 100% when the fitting degree is the highest. However, the fitting degree of the methods in Literature [2], Literature [3], and Literature [4] is relatively low. In particular, the fitting degree of the methods in Literature [2] is only about 15%, and the fitting degree of the methods in Literature [3] and Literature [4] is about 51% and 71%, respectively, which is quite different from the fitting degree of the methods in this paper. Therefore, it can be seen that the method proposed in this paper has obvious advantages in fitting degree and meets the actual needs.
4. Conclusion
With the continuous development of medical image imaging technology, there are gradually more ways to obtain medical images. Medical image has the advantages of low cost, simple operation, and easy preservation, as well as enhancing people’s health awareness, thus it has been widely used in medical treatment in recent years. To further analyze medical images and obtain more useful information, this paper proposes a similarity measurement model of medical image feature matrix based on CNN. The global and local information of the medical image is analyzed, the image feature points are extracted orderly, and the CNN is input to construct the feature matrix. Based on the CNN operation, the similarity measurement model of the medical image feature matrix is constructed, and the model design is completed. The results show that the proposed model has a good similarity measurement effect in global, local, and detailed aspects, and the maximum error rate of this model is only about 0.21, the minimum operation time is only about 25 s, and the overall fitting degree can reach about 91%, which has significantly superior performance compared with traditional methods.
In the research of medical images, it is an important direction for the development of medical images in the future to realize the diagnosis of disease according to the different locations and the similarity of location. In future research into medical images, it is necessary to not only focus on medical knowledge but also learn from the corresponding model recognition and bionics knowledge, to integrate multiple patterns, obtain better similarity measurement methods, and make more breakthroughs. In this study, we only optimize the insufficient use of the previous model, and the research depth is insufficient. In the future, we need to continue to find better calculation methods to improve the use effect of the similarity measurement model.
Data Availability
The data used to support the findings of this study are available from the corresponding author upon request.
Conflicts of Interest
The author declares that there are no conflicts of interest.