- PyCharm
- PyTorch
- Python
- Convolutional Neural Network (CNN)
This project used PyTorch to build a CNN model to recognize all types of cells that are present in the given images. These cell types are: red blood cell, difficult, gametocyte, trophozoite, ring, schizont, and leukocyte. The best model in the seven-day data challenge competition yielded a loss score of 4.54085.
The training set contains 929 rectangular cell images of varied size, 929 txt files with the corresponding string labels, and 929 json files with the cell detection bounding boxes. During the course of the seven-day competition, only the raw images and the txt files were used to train the model. Since the dataset is unbalanced and the raw data (.png and .txt) cannot be directly used to train the network, the following steps were performed to preprocess the data.
- Image Resizing
- Data Augmentation
- Labeling
- Loading Data using DataLoader
(Detailed description of the data preprocessing steps is provided in the project report under the Report folder.)
This project built a network that contains 12 layers. As illustrated in Figure 1, the model follows the block design pattern, where one convolutional layer (filters of size 3 X 3), one max pooling layer (factor 2), and one ReLU activation layer are stacked as a single learning block. The whole model is formed by four learning blocks, followed by three fully connected layers, and lastly following by a sigmoid activation function to render the probabilities of each class independently for classification. Adam was chosen as the model optimizer and BCELoss as the function loss.