Inspiration
Research has shown that one of the early warning signs for Parkinson's disease is difficulty writing due to changes in the brain. One way of testing for this is by performing a spiral test on a piece of paper. There tends to be a noticeable difference in the drawings between those who have been diagnosed with Parkinson's disease and those who have not. The goal of this project was to determine this difference through machine learning and give users predictions on spiral drawings that could be performed at home.
What it does
ParkinVision is a responsive web application that allows the user to see a prediction about whether their spiral drawing is representative of an individual with Parkinson's disease. A user can either text an image of their drawing to ParkinVision's phone number or upload an image on the web application. Then, the picture is processed and a prediction is made. Afterwards, the suspected result is outputted to the user either through a text message or on the web application's results page.
How I built it
I used a Flask web application styled with Bootstrap to process and display the predictions of uploaded images. The Twilio MMS API was used for sending text messages as a POST request to my locally hosted web application using ngrok as the middleman. The image processing used OpenCV to modify and convert the image into a NumPy array of features for a machine learning model. Afterwards, the image was evaluated on a trained machine learning model before a response would be returned either through a text message with Twilio's API or through a results web page. The machine learning model was trained on a data set of spiral drawings of patients that had Parkinson's disease and a control group that did not. Scikit-learn classification algorithms were evaluated on the data and GridSearchCV was used to find the optimal parameters for the selected model.
Challenges I ran into
One of the most difficult challenges was finding good data. My original idea was to do handwriting prediction for dementia but I was unable to find any data sets. After searching for a while, I ended up deciding to switch to Parkinson's because there was a lot more publicly available data. However, the data sets I found were very small, which would impact the performance of the models.
Accomplishments that I'm proud of
I am proud to have completed this project by myself in such a short time span. Additionally, it was nice to code both the model and the web application purely in Python. Using the Twilio API to send text messages and get back the model prediction was one of my most favorite parts of the project.
What I learned
One of the most important lessons I learned was that data is often more important than the actual machine learning model. Unlike school environments, data in the real world is messy and not always perfectly designed for a project. Aside from this, I learned many new libraries including Flask and OpenCV, both of which I plan on using much more in the future. Additionally, it was my first time using the Twilio API which I enjoyed and plan to use in future projects.
What's next for ParkinVision
Because this was a solo project with a limited time frame, there were a lot of ideas that I was unable to implement. First, I would use online machine learning to continuously learn from new image submissions although I would have to take into account adversarial examples. Additionally, I would have liked to artificially create more data by performing transformations on the existing data set. I plan on continuing to work on this project to implement these features and add other improvements.

Log in or sign up for Devpost to join the conversation.