Detection of Breast Cancer Using Convolutional Neural Network

Detection of Breast Cancer Using Convolutional Neural Network

Now a days, Women are highly threatened by breast cancer with morbidity and mortality issues and theses ratio has been increasing year by year. As per the latest reports by the National Breast cancer  foundation, (NBCF-USA) [1]. In USA there were 276,480 new cases registered in 2020.

That means 1 in 8 women in the United States will develop breast cancer in her lifetime & out of which estimated 42,170 women died from breast cancer. [2] As per the Indian Council of Medical Research, in India, we had 205,424 new cases registered in 2020. That means 1 in 29 women will develop breast cancer.

With this increasing ratio, we are lacking with the prognosis models, which results in difficulty for doctors to prepare a treatment plan that may prolong patient survival time. Hence, there was requirement of time to develop a model in such a way that it can assist our doctors in predicting whether the patient is suffering from the malignant or benign types of breast cancer with the highest accuracy.

The Case study mainly focuses on the Convolution Neural Networks (CNN) approach in order to extract the features from the image type of dataset and classifies the type OF breast cancers. This case study is carried out to predict the highest accuracy.

The future research can be made to predict the other different parameters and breast cancer with its different categorizes.

This blog is divided in multiple steps for your understanding:

Step 1: Understanding of cancers & its types (useful for feature extraction)

Step 2: Methodology

Section 1: Pre-processing of an image

Section 2: Convolutional Neural Network

Step 3: Conclusion and its future scope in Medical firms

Understanding of Cancers:

The dataset is divided into two main groups: benign tumors and malignant tumors. Histologically benign is a term referring to a lesion that does not match any criteria of malignancy – e.g., marked cellular atypia, mitosis, disruption of basement membranes, metastasize, etc. Normally, benign tumors are relatively “innocents”, presents slow growing and remains localized. Malignant tumor is a synonym for cancer: lesion can invade and destroy adjacent structures (locally invasive) and spread to distant sites (metastasize) to cause death. This type of procedure, compared to any methods of needle biopsy, removes the larger size of tissue sample and is done in a hospital with general anaesthetic.



This case study was implemented in two major sections:

  • Section 1: Pre-Processing an image
  • Section 2: The Extracted features are used further for classification using SVM
Section 1

Pre-Processing an image In this section the mainly the images are converted to the vectors and further resized to fixed size. In this case study the image is resized to (115,175). Once the process is done, the cleaned and pre-processed images are appended to the training & testing datasets.

Section 2

Convolutional Neural Network Topology Our proposed CNN topology is given below and it comprises five convolutional layers followed by two fully connected layers.

✓ 1st convolutional layer with filter size 3 _ 3 and 64 feature maps.

✓ 2nd convolutional layer with filter size 3 _ 3 and 96 feature maps.

✓ 3rd convolutional layer with filter size 3 _ 3 and 128 feature maps.

✓ 4th convolutional layer with filter size 3 _ 3 and 256 feature maps.

✓ 5th convolutional layer with filter size 3 _ 3 and 256 feature maps.

✓ Fully connected layer with 2000 hidden units.

✓ Fully connected layer with number of hidden units equal to the number of classes.

✓ Softmax layer.

We have applied the RELU layer to all convolutional and fully connected layers to make fast the convergence learning and to introduce the non-linearity. We have also used max pooling for the first two convolutional layers and the fifth layers and it has not applied for the third and the fourth layers. The max pooling layer is applied after RELU layer to reduce the spatial dimension with a filter of 3×3 and a stride of the length equal to two. Dropout layer was applied after the fully connected layer with keep probability of p = 0.5 which improved the performance of the network. The CNN model is iterated with 20 epochs.

breast cancer detection using cnn

Conclusion & Future Scope

The CNN i.e., Convolution Neural Networks approach has been successfully utilized and implemented in our proposed approach. The accuracy levels on the training dataset were obtained as 95% whereas on the testing dataset as 93.86%. The models seem prettier good in terms of accuracy level. Based on the Exploratory data analysis, it was found that the ratio of patients having benign cancers are more when compared to Malignant.

Recently Published

Popular Newsletters

Most Viewed


contact us for complete code