![]() Initially, I had plans to use VGG16 or Resnet50 but when I saw this article on Efficientnet, I changed my mind in the favor of Efficientnet. Computer Vision is a quickly evolving field and new models keep getting developed at a fast pace. Pre-Trained Model: Coming to the question of which pre-trained model to use I came across an interesting article on the Google AI Blog that compared the accuracy on the Imagenet dataset vs the number of parameters in the model for several pre-trained models. I thank the authors for the leads that I got from their study.Ī complex field like Deep Learning is never a lone wolf endeavor and we all stand on the shoulders of each other, not just the giants, to look ahead. I started with a lower learning rate (lr=0.0001 as aginst 0.001) that turned out to the better choice later and went with the rule of thumb of setting the batch size as 32 which is quite common in deep learning practice. The authors experimented with various learning rates and batch sizes for the VGG16 CNN. The interplay of Learning Rate, Batch Size, and Accuracy has been explored well in this paper. Out of these two batch sizes, the batch size of 32 led to the lowest error rates with a learning rate of 10e-4. I experimented with learning rates of 10e-3, 10e-4, and 10e-5 and found that 10e-4 led to the lowest error rates for the test dataset.īatch Size: On increasing the batch size to 256 or even down to 64, I ran into memory issues and therefore had to opt for a lower batch size. A higher learning rate, on the other hand, can lead to the algorithm overshooting the optimal set of weights. The issue could be that the algorithm has not yet learned the set of weights that lead to the lowest error for the test set. Learning Rate: A lower learning rate leads to better convergence but not necessarily the best test accuracy. I will now describe how I went about selecting each of the hyperparameters and what I learned in the process. One does not know most of the answers when starting out and has to learn by experimentation. I will describe it more in detail later in this article.Ĭlimbing the Performance Ladder - Steps and MisstepsĪ deep learning algorithm has many moving parts and I found that training a high-performing model is as much an art as it is math. From the benefit of hindsight, it turned out to be not the best starting point but one must start with what one has and in this case, it was the training dataset. Initially, I started with the imbalanced training dataset as it is. In other words, it will label everyone as being Covid-free and attain an ‘accuracy’ of 90% even though about 10% of the people actually have Covid. The problem with significantly imbalanced sets is that even a naive learning algorithm that simply outputs the class of the majority class as the output will attain high accuracy. I found that the training dataset is significantly imbalanced with about 90% of the images being of the non-Covid class. The test dataset consists of 400 such images coming from the same distribution. The training dataset consists of 15264 (512x512 pixel) images that have been classified by an expert radiologist. The images shown below from the competition website are of people without (negative) and with (positive) Covid-19.Ĭhest X-Ray Images of People without (left) and with (right) Covid-19 (Source: Competition Website: ) Such a model can help health care professionals diagnose COVID-19 cases much more quickly than a radiologist having to go through each scan one by one especially in situations where a large number of people need to be tested in a short time window. We have a set of supervised X-ray images that have been carefully labeled by radiologists on which the model must be trained. Given an input chest X-ray image, the algorithm must detect whether the person has been infected with Covid-19 or not. You can find my complete code on GitHub here. ![]() While working on this problem, I experienced the truth first-hand in the saying “Enjoy the process, the result will take care of itself”! ![]() and Masters students of Statistics and Computer Science departments! Instead of moving straight to results, I will mention the challenges that I faced while I developed and trained the model and how I found ways to resolve them. I was happy to learn from the final competition Leaderboard that I stood 1st in the competition amongst 40 participating Ph.D. I developed this algorithm while participating in an In-Class Kaggle competition for a Ph.D. In this post, I will share my experience of developing a Convolutional Neural Network algorithm to predict Covid-19 from chest X-Ray images with high accuracy. Leveraging Efficientnet architecture to achieve 99%+ prediction accuracy on a Medical Imaging Dataset pertaining to Covid19 High-Accuracy Covid 19 Prediction from Chest X-Ray Images using Pre-Trained Convolutional Neural Networks in PyTorch
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |