## 3 Methodologies
### Image Enhancement Technique  
The original images downloaded from the source given above contains noise as it is the knee X-ray images obtained from the X-ray machine available at the hospital. Normally, there are chances that these images contain noise. Hence, we used the OpenCV library for image enhancement techniques, which will further enhance the results of classification using a neural network. Image enhancement techniques, e.g., contrast enhancement, contour detection using canny edge detection methods, image blur, and image sharpening, were attempted for research purposes. When we tried the above combination, we achieved improved results with the image sharping process. Anterior knee joint view (ROI) was taken from the original X-ray images at baseline, which have previously been cropped. They're 224 \(\times\) 224 pixels in size. Images are split into train, test, and validation data. However, for our research, this split must match the ratio (80:20) in the other models using clinical data according to the division of clinical data For this reason, we re-arrange all images using a high-level file operation, shutil library in Python. Image sharpening is used to decrease noise and equalize histograms in a customizable function first. These approaches include rotating photos 15 degrees, zooming to the nearest 0.1, shear mapping images, and turning half of the images horizontally. Pictured in Figure 4 is an example of what a picture after using the augmentation approach looks like. Segmentation  
To classify images of human knee OA, we employ the most recent unsupervised medical image segmentation technique based on the computation of the two-dimensional (2D) local center of mass (LCM) proposed by [22; 24]. Step 1: Computation of CM (Centre of MASS)  
The term \"center of mass\" refers to the value calculated from a cluster of pixels or a section of a curve based on their average intensity. The intensity value is used to determine the weights. The cluster's centroid will be its central, most intense pixel. The formula for N-by-N intensity samples in a one-dimensional picture is f: R, where: = 1,..., N. Each pixel's local center of mass (CM) is determined, and then pixels are clustered together into non-contiguous clusters: C: \(\Omega\rightarrow\mathbb{R}\). Centre of mass is calculated as:  
\[C_{n}=\sum_{n=1}^{N}\!{}_{W_{n,n}}\!m/\!\sum_{n=1}^{N}\!{}_{W_{n,n}} \tag{1}\]  
Step 2: Weight Calculation  
An image's intensity can be used to calculate the weight parameter required by Equation 1. A positive value, Wm,n is modest when the n-th and m-th pixels are in different regions and high when they are in the same region. The pixels from the same area should all be placed in the same cluster, as indicated by their shared center of mass C. Therefore, the evidence contained in the whole region is used to cluster the signal, rather than just the pixels immediately adjacent to it. The total cost of computing C (Cn l n ) is (N2). Figure 4: Images of the knee X-ray after-processing. Step 3: Initialization of Parameters  
In order to perform the segmentation using the LCM method, some initial parameters must be determined, such as the iteration limit for LCM, which is set to 2000, and the computational parameters, which include and p, which are fixed based on the optimal results achieved via trial and error. A built-in Sobel operator [25] in the Watershed method is used to segment the first edges. Step 4: Computing LCM  
Images are broken down into groups according to their center of gravity. The iterative procedure is carried out until the specified goals have been met. The whole segmentation procedure used in this study is depicted in the flowchart in Figure 5. The procedure begins with the import of knee X-ray pictures, followed by an initial quality screening, pre-processing of an image for noise removal, setup of parameters for the segmentation process, computing LCMs, and lastly segmenting the region of image based on CMs. Figure 5: Flowchart representing the complete LCM segmentation process of Segmentation.