Artificial Intelligence Algorithm in Classification and Recognition of Primary Hepatic Carcinoma Images under Magnetic Resonance Imaging

This study aimed to discuss the application value of the bias field correction algorithm in magnetic resonance imaging (MRI) images of patients with primary hepatic carcinoma (PHC). In total, 52 patients with PHC were selected as the experimental group and divided into three subgroups: mild (15 cases), moderate (19 cases), and severe (18 cases) according to pathological grading. Another 52 patients with hepatic nodules in the same period were included in the control group. All the patients underwent dynamic contrast-enhanced (DCE) MRI examination, and the image qualities of MRI before and after bias field correction were compared. The DCE-MRI perfusion parameters were measured, including the transport constant Ktrans, reverse rate constant Kep, extravascular extracellular volume fraction (Ve), plasma volume (Vp), microvascular density (MVD), hepatic artery perfusion index (HPI), mean transit time of contrast agent (MTT), time to peak (TTP), blood volume (BV), hepatic arterial perfusion (HAP), full perfusion (FP), and portal venous perfusion (PVP). It was found that the sensitivity (93.63%), specificity (71.62%), positive predictive value (95.63%), negative predictive value (71.62%), and accuracy (90.01%) of MRI examination processed by the bias field correction algorithm were all significantly greater than those before processing (P < 0.05). The Ktrans, Kep, Ve, Vp, and MVD of patients in the experimental group were significantly larger than those of the control group, and severe group> moderate group> mild group (P < 0.05). HPI, MTT, TTP, BV, and HAP of patients in the experimental group were also significantly greater than those of the control group, which was shown as severe group > moderate group > mild group (P < 0.05). FP and PVP of the experimental group were significantly lower than those of the control group, and severe group < moderate group < mild group (P < 0.05). It was suggested that in MRI images of patients with PHC, the bias field correction algorithm could significantly improve the diagnosis rate. Each perfusion parameter was related to the pathological grading, which could be used to evaluate the prognosis of patients.


Introduction
Primary hepatic carcinoma (PHC) is one of the common malignant tumors in humans, and its mortality has been high [1]. According to the Global Cancer Report 2014 issued by World Health Organization, the deaths due to liver cancer in China account for about 51% of that globally. It ranks second in the mortality of malignant tumors in rural areas in China and ranks the third in cities [2]. Hepatic carcinoma mostly occurs in the context of hepatitis and liver cirrhosis in China. Hepatitis, cirrhosis, and liver cancer are three steps experienced by many patients. Due to the poor reserve function of the liver, the antitumor immune function of the body is low, and the prognosis is also poor. erefore, early diagnosis and effective treatment are the keys to improving the prognosis of patients with hepatic carcinoma [3,4].
It has been shown that the histopathological grading of PHC is related to its degree of infiltration and distant metastasis and is the main influencing factor for its prognosis [5].
us, early diagnosis, accurate pathological grading, and timely treatment of PHC are the keys to prolonging the survival time of patients with liver cancer [6]. A hepatic biopsy is currently the gold standard for pathological grading of PHC. In addition to sampling errors, this invasive procedure may bring certain risks to patients, such as infection, hemorrhage, and even the spread of cancer cells. erefore, it is particularly important to find a noninvasive, repeatable, and highly accurate examination method for clinical diagnosis and treatment. e most common diagnostic method for PHC is imaging examination. Currently, there are realtime ultrasound, histopathological examination, computed tomography (CT), magnetic resonance imaging (MRI), angiography, radionuclide imaging, and so on [7,8].
Histopathological examination is the gold standard for the diagnosis of liver cancer, but it is necessary to combine it with clinical evidence in the pathological diagnosis. is is to comprehensively understand hepatitis B virus (HBV) and hepatitis C virus (HCV) infections in patients, the detection results of other tumor markers, and the imaging features of hepatic space occupying lesions [9]. With the rapid development of imaging technology, ultrasound and CT have become the common methods for clinical diagnosis, with easy operations and affordable cost. But if the imaging features of the hepatic space occupying lesions are not typical, it may be missed or misdiagnosed. MRI showed more and more prominent advantages in the diagnosis of PHC. Its good resolution of tissues, multisection, multiparameter observation, relatively nontoxic contrast agent, no radiation, nontrauma, and other characteristics make MRI the optimal choice for imaging diagnosis of PHC [10]. In the past, the diagnosis of PHC by MRI mainly focused on morphological changes according to the imaging features of the tumor, such as T2 weighted imaging (T2WI) hyperintensity, diffusion-weighted imaging (DWI) hyperintensity, pseudocapsule sign, and rapid wash-in and wash-out enhancement. ereby, tumors can be easily distinguished from nontumor nodules, but the degree of pathological differentiation of tumors cannot be accurately inferred. With the continuous development of functional MRI technology, it can not only reflect histological characteristics such as microcirculation state and cell density of tumors but also reflect cell metabolism and biochemical information of tumors [11,12]. is makes it possible to assess the pathological grading of PHC accurately using MRI.
Dynamic contrast-enhanced (DCE) imaging technology is a three-dimensional volumetric thin-slice scanning on the ground of the T1 weighted imaging (T1WI) sequence. e magnetic resonance contrast agent is injected into the venous bolus for repeated, multistage, and rapid scanning, which allows MRI to detect the situation of blood perfusion in internal organs and tissues and obtain multiple perfusion parameter information through relevant analysis by the processing software [13]. DCE-MRI can quantitatively evaluate the properties of blood vessels in tissues. It has been reported that this technique can accurately assess the level of tumor tissue microcirculation, as well as capillary permeability and hepatic artery blood supply ratio in hepatic malignant tumor tissues [14].
With the development and application of deep learning, deep learning models can replace traditional machine learning algorithms to automatically extract lesion features and achieve lesion classification and identification [15]. Hepatic MRI bias field correction is mainly to deal with image grayscale inhomogeneity caused by radiofrequency field inhomogeneity and other factors. e bias field correction algorithm utilized the estimation of the bias field and the corresponding spatial information, which could well deal with the impact of the image bias field on the segmentation. A hepatic bias field correction algorithm was put forward on the basis of grayscale preservation, which ensured that the corrected image retained the grayscale information of the original image to the greatest extent. Hepatic tissue segmentation was performed on the corrected images, and evaluation parameters like segmentation were used to reflect the performance of the bias field correction algorithm [16,17]. To sum up, the hepatic MRI images of patients were processed under the bias field correction algorithm. e correlation was analyzed between multiphase DCE-MRI perfusion parameters and microvascular density (MVD) and pathological grading of PHC patients, which was to provide a certain theoretical basis for the diagnosis of PHC.

General Data of Patients.
In this study, 52 patients with PHC admitted to the hospital from July 2019 to July 2021 were included in the experimental group. Another 52 patients with benign hepatic nodules admitted during the same period were chosen as the control group. e inclusion criteria of patients were as follows. e clinical symptoms and histopathological examination results of the patients were in line with the diagnostic criteria for PHC formulated in PHC Diagnosis and Treatment Standards (Edition 2011) [18]. e patients were willing to undergo a DCE-MRI examination, and they all had the first-time onset. All the patients and their families fully understood the situation and signed the informed consent, and this study was approved by the ethics committee of the hospital. e exclusion criteria below were followed. Patients had cancer tissue infiltration or metastasis to other tissues or organs. Patients had dysfunction of other important organs, such as heart, lung, and kidney. Patients were complicated with severe immune system diseases, infectious diseases, or infectious diseases. Patients had contraindications to DCE-MRI.
e general data of the two groups of patients are shown in Table 1 for details. ere was no significant difference in gender, age, and average age between the two groups (P > 0.05), which made the research was of comparability. e patients underwent a DCE-MRI examination after respiratory function training. en 1.5 T MRI instrument was used, and the abdominal phased array coil was set to 8 channels. e abdominal belt was used to adjust the breathing state of the patients. Dynamic, fast, and enhanced scanning were performed, respectively. For scanning parameters, the field of view (FOV) was set to be (350 × 320) mm, time of echo (TE) was 1.5 ms, time of repetition (TR) was 4.2 ms, the interlayer spacing was 0, the layer thickness was 3.6 mm of the (320 × 195) matrix, and the number of excitations was 1. Only the flip angles (3°, 9°, and 25°) needed to be adjusted; during enhanced scanning, a total of 50 dynamic cycles were scanned, each cycle lasted about 6 seconds with 30 layers, and the whole process lasted about 5 minutes. e scanning parameters were set as follows: FOV � (215 × 284) mm, TE � 1.35 ms, TR � 3.2 ms, slice thickness � 3.24 mm, the matrix was sized as 521 × 521, and the number of excitation was 2. In the second scanning, the contrast agent gadolinium diamine of 0.2 mL/kg was injected from the median cubital vein at a rate of about 4 mL/s. In total, 20 mL of normal saline was injected at the same rate after the injection. DCE scanning required the patients to hold their breath throughout the procedure, with only light and rapid ventilation.

Bias Field Correction
Algorithm. MRI bias field correction was an algorithm model under local coherence, global intensity, and spatial continuity information. It could keep the grayscale of images consistent before and after correction. Its objective function was shown as follows: (1) . Ω represents the whole hepatic MRI image with background noise removed. O k represents the local area of the grayscale value of the k-th pixel in the image. e membership template function was expressed as V � [v ik ], which was used to describe the degree to which the pixel belonged to a certain cluster. g kp ∈ [0, 1] refers to the local spatial continuity weight, which stands for the influence of domain pixels. T i (r), i � 1, 2, . . . , d; r � 1, 2, . . . , m represents the label function, which was the intensity information for this image and guided the correct clustering. I kp is the filtered image after background noises were removed, and it was obtained by multiplying the membership template with the original image. U � u 1 , u 2 , . . . , u d is the clustering center. α(0 ≤ α ≤ 1) stands for a positive value to balance global intensity with local intensity. Parameter n > 1, d represents the number of clusters, and m is the total number of pixels in the image.
e weighted function K(r − k) also represents a truncated Gaussian kernel function, which reflects the influence of the center pixel r on the surrounding pixels, and its value decreased as the distance from the center r to the neighbor pixels k increased. c > 0 is to balance the effects of the intensity and intensity-preserving constraints mentioned above.
In the energy minimization equation, to the global intensity of the image, which was to ensure the correct clustering of each pixel in the image. e term r∈O k K(r − k)‖I kp − h r u i ‖ 2 is used to guarantee the smoothness of the bias field under the local intensity of the image. m k�1 (1 − h k ) 2 is the constraint term proposed to ensure the grayscale of the image after bias field correction, ensuring the grayscale consistency of the image before and after bias field correction; that is, the corrected image (I/h) and the original image have the same grayscale. g kp ∈ [0, 1]s indicates the local spatial continuity weight, which was the influence of neighbor pixels. In the image space domain, a pixel k had a spatial coordinate (n k , m k ), and a pixel p in the neighborhood had a spatial coordinate (n p , m p ), then the local spatial weight information could be expressed as follows: In this equation, where k represents a constant and δ kp is the same when the image pixel value was multiplied by a constant. e parameters V, U, and h could be obtained by minimizing the energy function A our . In this process, when solving one parameter, the other two parameters could be kept unchanged, which was the same as the standard D-means clustering method. erefore, the parameters V, U, and h could be obtained by making the first derivative of the objective function A our equal 0, respectively. e iteration of parameters was applied to estimate the bias field h, and the corrected image of the bias field could be obtained by I/h. Since the energy function A our was a convex function to its variables, the method proposed here was robust to initialize parameters. e membership function was solved at first. e first-order partial derivative of the energy function A our to the parameter V was computed, and the result was made equal to 0. en the following equation was worked out: e variable v ik was determined by the following equation: Because V in the energy function A our needed to satisfy the constraint term d i�1 v ik � 1, v ik ∈ [0, 1], the following equation was obtained: Next, the clustering center was solved. e first-order partial derivative of the energy function A our to the parameter U was solved, and the result was made equal to 0, then the following equation was obtained: e variable u i was determined by the following equation: en the solution of u i was calculated through the following equation: In the equation, the symbol * refers to the convolution operator. I � p∈M k (ω kp · I kp )/ p∈M k ω kp , and I is the hepatic MRI image after background noises were removed. I k represents the grayscale value of the k-th pixel in the filtered image I.
Finally, the bias field estimation was performed. e energy function A our was utilized to find the firstorder partial derivative of the bias field parameter h, and it was set equal to 0, then equation equation could be worked out: e variable h k was determined by the following equation: erefore, the bias field h k could be expressed as follows: In the equation (12), and v i represents the membership degree of category i. e experimental steps of this method are described in Figure 1.
(1) Parameters V, U, and h and other parameters were initialized. (2) e membership template function I mask was calculated. (3) e membership matrix was updated by multiplying equation (6) and the membership template function I mask . (4) e global variable T i (r) was updated. (5) e cluster center was updated via equation (9). (6) e bias field was updated through equation (12). (7) It was judged whether the convergence condition ‖U new − U old ‖ < ε was satisfied, where ε is a very small number. If it was satisfied, the calculation was stopped; if not, the calculation was continued with steps (3) to (6).

Pathological Judgment Standards.
e patients in the experimental group were graded with Edmondson-Steiner's tumor pathological grading method [19]. e pathological grading was performed according to the size and morphology of tumor cells, nuclear size, basophilic cytoplasmic staining, nuclear staining depth, and cytoplasmic ratio. Differentiation grade I referred to the tumor cells arranged in fascicles; grade II referred to the tumor cells that were shown eosinophilic with rich cytoplasm, large nuclei, and dark staining. Grade III meant that the nuclear staining degree was deeper than that of grade II, and tumor giant cells appeared. For grade IV, the tumor cells were shown with less cytoplasm, larger nuclei, darker staining, lacking of intercellular connections, and low differentiation. According to the grading of pathological conditions, grade I belonged to the mild group, grades II-III were in the moderate group, and grade IV was in the severe group.

Observation Indicators.
After the DCE-MRI scanning, processing software was used to analyze the measurement results as the two-chamber Tofts model was selected. During the period, necrotic tissue and blood vessel areas were avoided. e maximum microvascular density (MVD) was selected under a low power lens, while the number of microvessels was calculated under a high power lens. Double-blind counts were performed by two experienced radiologists, respectively; then the average value of MVD was taken. ree regions of interest were selected to measure the plasma volume (Vp), the extravascular extracellular volume fraction (Ve), and the transport constant Ktrans from intracellular to extracellular space. e reverse rate constant Kep from extracellular to intravascular space, hepatic artery perfusion index (HPI), mean transit time (MTT) of contrast agent, time to peak (TTP), blood volume (BV), full perfusion (FP), hepatic arterial perfusion (HAP), and portal venous perfusion (PVP) were used to determine the mean value of the three fields of view.
e enumeration data were expressed as a percentage (%). e measurement data Ktrans, Kep, Ve, Vp, MVD, HPI, MTT, TTP, BV, FP, HAP, and PVP were expressed as mean ± standard deviation (x( ) ±s). e differences in the measurement data among the three groups were analyzed by variance analysis. e t-test and Pearson method were adopted to analyze the differences in measurement data between two groups. When P < 0.05, the difference was statistically significant. Figure 2 shows the MRI images of a 64-year-old male patient with hepatic carcinoma. In Figure 2 below, the images a, b, c, and d were the MRI images of the PHC patient before being processed by the bias field correction algorithm, while images e, f, g, and h were the MRI images after the bias field correction algorithm processing. Images a and e were the MRI images, images b and f were the T1WI images, images c and g were the T2WI images, and images d and h were the DWI images.

MRI Results of Liver Cancer Patients.
After being processed by the bias field correction algorithm, the sensitivity, specificity, positive predictive value, negative predictive value, and accuracy of MRI examination were 93.63%, 71.62%, 95.63%, 71.62%, and 90.01%, respectively.
ese were all significantly greater than those before processing (P < 0.05), and the differences were of statistical significance, which could be discovered in Figure 3 for details.

Comparison of Ktrans, Kep, Ve, Vp, and MVD in Patients between the Two Groups.
Ktrans, Kep, Ve, Vp, and MVD of patients in the experimental group were significantly greater than those in the control group (P < 0.05), suggesting that the differences were statistically significant. e details are shown in Figure 4.

Comparison of Ktrans, Kep, Ve, Vp, and MVD among Subgroups of Patients in the Experimental Group.
With the pathological judgment standards, the patients in the experimental group were divided into three subgroups, namely, the mild group (15 cases), the moderate group (19 cases), and the severe group (18 cases). Ktrans, Kep, Ve, Vp, and MVD of the severe group > those of the moderate group > those of the mild group (P < 0.05), and all the differences were considered to be statistically significant. Figure 5 shows the comparisons in detail.

Comparison of HPI, MTT, TTP, BV, FP, HAP, and PVP
between the Two Groups of Patients. HPI, MTT, TTP, BV, FP, HAP, and PVP of patients were compared between the experimental group and the control group. HPI, MTT, TTP, BV, and HAP of patients in the experimental group were significantly higher than those of the control group (P < 0.05). FP and PVP of the experimental group were significantly lower than those of the control group (P < 0.05), which were all displayed in Figures 6 and 7  Contrast Media & Molecular Imaging those in the moderate group > those in the mild group, P < 0.05. FP and PVP in the severe group < those in the moderate group < those in the mild group, P < 0.05. All the differences were of statistical significance, as observed in Figures 8 and 9.

Correlation Analysis of Hepatic DCE-MRI Perfusion Parameters and MVD in PHC Patients in Experimental Group.
Hepatic DCE-MRI perfusion parameters Ktrans, Kep, Ve, Vp, HPI, MTT, TTP, BV, and HAP were positively correlated with MVD in the experimental group (P < 0.05). FP and PVP were negatively correlated with MVD in the group (P < 0.05). e differences were suggested to be statistically significant, as shown in Figure 10 in detail.

Discussion
DCE-MRI is a noninvasive imaging technique. It is to inject a paramagnetic contrast agent into the blood vessel after the T1 is shortened. If the imaging is repeated, the change in the signal intensity in the tissue can be measured. As the diffusion time of the contrast agent increases, the peripheral tissues are monitored. After being processed by professional software, the quantitative parameter technology can be applied to measure the pathological changes in blood perfusion, and this technology has been increasingly used to evaluate the vascular permeability and the tumor microcirculation [20,21]. e level of MVD can reflect the formation of new blood vessels in tumor tissues. e permeability of new blood vessels in immature tumors is higher, and the permeability of new blood vessels is related to the dynamic enhanced detection method of DCE-MRI [22]. It has been reported that with the increase of the tumor tissue volume and the degree of differentiation of PHC, the arterial blood supply also increases accordingly, and the hepatic sinusoids may present a capillary state. Because the morphological basis of tumor tissue growth and infiltration lies in blood vessels, the new tumor tissues and blood vessels can provide nutrients. If the blood vessels are immature, their permeability is higher; the contrast agent injected in DCE-MRI examinations has a small molecular weight and is easy to exudate from blood vessels into the extracellular space [23,24]. It was found in this research that the sensitivity, specificity, positive predictive value, negative predictive value, and accuracy of MRI diagnosis processed by the bias field correction algorithm were 93.63%, 71.62%, 95.63%, 71.62%, and 90.01%, respectively. All of the results were remarkably greater than those before processing as P < 0.05, which indicated that compared with the simple MRI images, the diagnostic performance of MRI under the bias field correction algorithm was more excellent. e blood flow velocity, which can be reflected as Ktrans on the vascular permeability, is used to indicate the permeability of the microvessels in the cancer tissues. e rate of contrast agent infiltration from the extracellular space to the intravascular space of the blood vessels is regarded as Kep. e volume ratio of contrast agent leaks into the extravascular interstitial space to the extracellular volume is denoted as Ve. Ktrans, Kep, and Ve increase if the vascular permeability around the tumor tissue increases [25]. It was found that Ktrans, Kep, Ve, Vp, and MVD of the experimental group were significantly higher than those of the control group, P < 0.05 with statistically significant differences. In the subgroups, Ktrans, Kep, Ve, Vp, and MVD of the severe group > those of the moderate group > those of the mild group, and P < 0.05, indicating the differences were statistically significant. It was suggested that the quantitative perfusion parameters of PHC patients by DCE-MRI examination were greatly related to the MVD and lesion severity of patients, which was similar to the results of Liu and Qian [26].
Some scholars have reported that the hepatic lobular structure is damaged in patients with PHC, regenerative nodules and a large number of fibrous tissue hyperplasia are shown, and even the blood circulation path is changed [27]. e portal vein reflux is not smooth, the hepatic arteriovenous shunt occurs, the hepatic blood flow resistance increases, and the PVP can be reduced. Under the action of fibrous cords, hepatic veins and portal vein branches in patients with PHC are occluded and narrowed, and a large number of collagen fibers are deposited in the intercellular space of hepatocytes. e flow time of the contrast agent in the liver is prolonged, which increases MTT and TTP. As blood flow resistance increases, the blood flow through the portal vein decreases and the proportion of hepatic artery blood flow in the total hepatic circulation increases, resulting in a decrease in FP and an increase in HPI [28]. It was found that HPI, MTT, TTP, BV, and HAP of the experimental group were significantly higher than those of the control group (P < 0.05), while FP and PVP were significantly lower (P < 0.05); the differences were computed to be statistically significant. e levels of HPI, MTT, TTP, BV, and HAP in patients were shown that those of the severe group > the moderate group > the mild group (P < 0.05). In FP and PVP, those of the severe group < the moderate group < the mild group (P < 0.05); the differences were all of statistical significance. It could be suggested that the quantitative perfusion parameters of PHC patients by DCE-MRI were significantly related to the incidence of portal vein thrombosis in patients. With the aggravation of PHC lesions, the risk of portal vein thrombosis increased, HPI, MTT, TTP, BV, and HAP increased, while FP and PVP decreased. ese results were exactly similar to the findings of Song et al. [29].

Conclusion
e hepatic MRI images of the patients were processed under the bias field correction algorithm. e correlation was also analyzed between the perfusion parameters of multiphase DCE-MRI and MVD and pathological grades of PHC patients to assist the clinical diagnosis of PHC. e results showed that the sensitivity, specificity, positive predictive value, negative predictive value, and accuracy of MRI were significantly improved after processing the bias field correction algorithm. DCE-MRI could evaluate the microcirculation status of PHC patients objectively and quantitatively, and the changes of quantitative perfusion parameters were significantly correlated with MVD and pathological grades. Quantitative perfusion parameters detected by DCE-MRI could evaluate MVD level and pathological grading, which was worthy of further promotion. However, only 52 cases with PHC were included in this work, the sample size was small and the source was single, which might affect the results. e image processing performance of the bias field correction algorithm also needed to be further analyzed. e research would need to be expanded in the future so as to verify the conclusion with more clinical experiments.

Data Availability
e data used to support the findings of this study are available from the corresponding author upon request.

Conflicts of Interest
e authors declare no conflicts of interest.

Authors' Contributions
Zehua He and Qingqiang Huang contributed equally to this work.