As human beings, we love being cared for and asked “How are you?” If we are not feeling well, we definitely appreciate someone recognizing our pain and giving us a helping hand. In this age of heavy traffic and people running around, most fellow travelers have no time for others. If we are not in a position to ask for help, we may end up in a big health dilemma.

As human beings, we hate being ignored and having to wait. When we visit a health clinic, we normally have to wait for a ridiculous amount of time. Most of the time, the clinic staff is so absorbed in their routine tasks that they have no time for greeting us or recognizing our pain. This lack of empathy makes patients feel resentful towards visiting the clinic.

A possible solution for this big problem can be in the form of an Android Robot that can recognize our pain and take appropriate action.

As a precursor to this Android Robot, we have built this Android App.

What it does

This Android app can classify pain position in an image stream, using a classifier model, built by using TensorFlow v2, MobileNet pre-built model, and some images grouped by pain positions.

It can continuously classify image frames received by the Android device's back camera. Inference is performed using the TensorFlow Lite Java API.

How I built it

  • Collected many images related to Abdomen pain, etc.

  • Retrained an image classifier model, using a single line of code. (Experienced the amazing power of TensorFlow v2 and TesnorFlow Hub.)

  • Created Android App in Android Studio, by using labels.txt and model.tflite files generated by the above code.

Challenges I ran into

  • Pain image classification is not so straightforward as flower image classification. A daisy's image cannot be a sunflower's image. However, an abdomen pain's image can also be a waist pain's image. This fuzziness reduces accuracy of pain image classification.

  • Healthcare related reliable images are generally hard to get.

  • Images searched through keyword "abdomen pain" may contain images related to causes and remedies of abdomen pain in addition to images of abdomen pain as such. This necessitates manual cleansing of images to get only relevant images.

Accomplishments that I'm proud of

  • An Android App that includes the power of Deep Learning.

What I learned

  • Learned a lot about various pre-built models available on TensorFlow Hub.

  • Learned to connect TensorFlow and Android.

What's next for PainPose

  • Improve the classifier's accuracy.

  • Extend the app for classifying videos and detecting objects.

Built With

Share this project: