# Fuzzy Logic with Deep Learning for Detection of Skin Cancer
## 3 Proposed Method
### Classification  
#### 3.3.1 YOLO  
In this rapidly advancing technological era, the field of medical vision has experienced significant growth, leading to the development of impressive and capable strategies to handle various complexities. Object detection algorithms in computer vision encompass innovative ideas for identifying and locating multiple targets within an image [31]. On the other hand, classification algorithms focus on determining the presence of a specific subject in an image. These classification algorithms employ CNN classifiers passed through predefined boxes, effectively removing the need for complex processes and enhancing the performance of the image analysis. In contrast, object detection algorithms employ a more advanced technique involving deep learning, which simplifies the process by directly conceiving the boxes encompassing the entire image rather than focusing on individual segments. As a result, this algorithm provides faster processing compared to the previous approach. YOLO [32] is an exceptional and ground-breaking approach in the field of computer vision, specifically designed for real-time object detection. Researchers have prioritized passing classifiers over the entire image instead of fragmented sections, enabling YOLO to process data at a remarkable rate of 45 video frames per second. YOLO incorporates CNN layers with collapsing and merging techniques, yielding unparalleled speed in object detection. This is achieved using regression and neural network techniques during the initial learning phase. The YOLO algorithm's effectiveness is further enhanced by leveraging the knowledge of diagnostic tensors, which can be expressed mathematically as an equation. \[(M\times M)*B*(5+C) \tag{7}\]  
In this context, (\(M\times M\)) refers to the non-overlapping grid cells obtained by dividing the specific image. The bounding boxes, denoted as \(B\), rely entirely on the grid cells for their predictions and calculation of confidence scores. The confidence score is represented by C. By examining the confidence score, we can determine the presence or absence of an object within the bounding box. If there is no prior existence of the object, the confidence score will be zero. This can be expressed as follows:  
\[\text{C}=\text{Presence (Object)}*\text{IoU}^{\text{groundtruth}}\underset{ \text{predicted}}{\text{Predicted}} \tag{8}\]  
According to the Google-Net YOLO architecture, there is a convolution layer with a total of 24 counts, resulting in tensors of size (7, 7, 1024). These tensors serve as the final output shape. Following this, there is a fully connected layer with two parameters, producing 7 \(\times\) 7 \(\times\) 30 parameters, which are reshaped as (7, 7, 30). This indicates that there are two boundary boxes for each location. The workflow of YOLO is summarized in Figure 8, where an input image of size \(M\times M\) is depicted in Figure 8a. Bounding boxes are generated in Figure 8b. Probabilistic mapping of classes is shown in Figure 8c, and the final detection of the lesion is presented in Figure 8d. Figure 8: The classification process performed by YOLO is depicted using a skin lesion image, where (**a**) represents the input grid of size \(M\times M\). In (**b**), bounding boxes are generated based on the confidence score. (**c**) illustrates the mapping of class probabilities, and (**d**) shows the detection of the lesion. To determine the arrangement of numerous bounding boxes within each grid cell, YOLO utilizes the Intersection over Union (IoU) metric to identify the highest value. The loss function in YOLO encompasses the classification loss, localization loss, and confidence loss, calculated using the sum squared error technique. YOLO also prioritizes spatial diversity to minimize false positives during its operation. The YOLO algorithm has undergone several versions, including YOLO v1, YOLO v2, and YOLO v3, each addressing limitations from previous iterations and offering effective solutions.