Inspiration

Approximately 1.5 million people every year in the United States suffer from a heart attack. In most cases, the person is unaware that they may be prone to suffering from a heart attack at some points in their lives. Smart watch technology can monitor your heart rate as well as other medical attributes that may be useful to predicting a heart attack. One thing it cannot do is provide an accurate prediction of when a person may have a heart attack based on their medical history. We made it our goal to create a web application that uses machine learning technology to provide an accurate prediction when someone may suffer from a heart attack based on their medical information. In this way we can save more lives with our application.

What it does

Our application takes in data that the user provides about their medical history and provides an accurate prediction about how likely the user is to suffer from a heart attack.

How we built it

Using supervised machine learning, we trained a model with datasets that we found online to detect the early onset of a heart attack using features such as age, gender, cholesterol, blood pressure, and more. After testing the dataset, we were able to use it to detect whether or not a heart attack was imminent in the patient using algorithms such as support vector and random forest classifiers. Using the outputs produced by these algorithms, we used bag and boost ensembles to make our results most accurate. To create a more user friendly experience, we used Django to create a website to enter specific features; this website then runs the machine learning program to predict if the person will have a heart attack.

Challenges we ran into

One big challenge that we ran into was connecting the front end to the backend which consisted of several machine learning models. To solve this problem, we pickled the files and ran them all on an online IDE. By doing this, we were able to use the training of machine learning and form a program that tests the inputted values from the website.

Accomplishments that we're proud of

We are very proud of the fact that we were able to make this website work especially because neither of us has ever had any experience with machine learning in the past. To learn enough for this project, we used multiple online resources and packages that were made by others. Overall though, the code that we put out was our own and it functioned as intended.

What we learned

We learned about machine learning and how machine learning can be implemented into the medical field as well as smart watch technology so that it can save more lives by providing accurate predictions.

What's next for Heart Attack Detection

As mentioned earlier, smart watches can track heart rate, which is very helpful to determine whether or not there will be a heart attack, but other attributes are equally important for our machine learning algorithm to give the best possible output. For this reason, in the future, we plan on making smart watches which can track cholesterol based on food intake, amount of exercise, and maximum heart rate while also allowing the user to input values such as age, sex, and medical history. This will allow the smart watch to directly predict a heart attack before it happens and could save a life.

Built With

Share this project:

Updates