Inspiration

According to the World Health Organisation, Tuberculosis and Malaria are among the top 10 most deadly diseases worldwide, and TB is the leading cause of death from a single infectious agent. In 2018 alone, there were over 10 million registered cases of TB and 1.5 million deaths due to TB and 228 million cases and 405,000 deaths due to malaria. Unfortunately, over 95% of those deaths were from low income nations in Africa, Asia etc. Even though these diseases are preventable and curable, why do they cause so many deaths? The major cause of this is lack of infrastructure and human resource required in low income nations to diagnose and treat these diseases. We believe that machine learning can be used to combat this global issue and improve the efficiency of the healthcare system, and reduce the dependence on human resources.

What it does

Tuber is a machine learning based diagnostic tool and patient management system targeted towards hospitals and medical clinics, that enables them to instantly diagnose Tuberculosis from chest X-Ray scan images, and malaria from a blood sample image, with a high accuracy. This web app aims to fully replace the diagnosis aspect of doctors in low income nations. This would improve the efficiency of the current system as it is faster and less heavy on resources compared to a human being. Our system collects basic information and an image, and then returns quick and accurate results. We use advanced machine learning algorithms to classify the user uploaded image into Normal or Infected (diagnosed with Tuberculosis or malaria), and then automatically generate a CSV medical report. We also have a patient data management system, as well as a data visualization page, displaying various analytics regarding patients. Lastly, we developed an AI based questions page, where the user can ask any questions about Tuberculosis, and get instant results.

Tuber significantly reduces the human resource and expertise required for diagnosing Tuberculosis and makes the entire system far more efficient and less prone to error. Tuber would have a huge impact in rural areas in continents such as Africa, where there is acute lack of qualified doctors to detect such diseases.

How we built it

  • Python flask for the web app and HTML/CSS/js templates for the front-end.
  • Keras with TensorFlow back-end for the image classification models.
  • TB Model was trained using Shenzen Hospital Tuberculosis X-Ray dataset. link: https://lhncbc.nlm.nih.gov/publication/pub9931 (93.2% accuracy)
  • Malaria model was trained using a free access dataset on IEEE. (95.5 % accuracy)
  • Python NLTK and TF-IDF Vectorizer model for AI search page.
  • Google Firebase for storing patient data.
  • Google charts for data visualization.
  • Heroku free tier for web hosting

Challenges we ran into

The first major challenge we ran into was getting good quality training data for the ML models. After hours of research, we were able to compile a dataset that allowed us to provide fast and accurate classifications. As it was our first time with firebase, we also struggled with integrating fire-base to store patient data. Lastly, hosting web applications with data intensive ML models such as this one was a huge hurdle, which we tried our best to approach using Heroku. Making the NLTK corpora work with Heroku was also a signification challenge.

Accomplishments that we're proud of

We are proud to have developed relatively fast and efficient models to predict with over 95% accuracy on the test dataset. We are proud to have learned firebase in a relatively short amount of time, and to have integrated it with a fully functional firebase database connected to our web app. We are also proud to have integrated a TF-IDF vectorizer and natural language processing model from scratch to build an AI powered question answer engine from scratch. Lastly, we are proud to have created a feature-rich web app and clean UI within the time constraint.

What we learned

We learned how to use TensorFlow and keras for image classification. We also learnt how to make an NLP based search engine feature. Lastly, we learned for the first time how to set up a firebase database and integrate it with a flask web-app.

What's next for Tuber

We hope to develop a login system for specific hospitals to access their patients' data securely. We also want to make a more sophisticated data visualization page, to help provide more detailed analytics. We anticipate getting a domain name for the web app, as well as expanding to a mobile app. Due to memory limitations, we were not able to host our machine learning model, and it only works offline. We would like to change this by using a more premium web service such as AWS or Gcloud. Lastly, we hope to experiment with more robust front-end frameworks such as React.

Share this project:

Updates