AasanAI - Your Personal Yoga Trainer

AasanAI - Your Personal Yoga Trainer

An ecosystem for Yogasanas. AasanAI is a Deep Learning-powered Web and Mobile application to help you during your yoga workouts. It detects your Yogasana position and helps you perfect your Yogasana.

The problem AasanAI - Your Personal Yoga Trainer solves

Theme

Healthcare, Open Innovation

Problem Statement

Countries all over the world implemented lockdowns to counteract COVID-19. These lockdowns heavily limited people’s exercise possibilities. Statistics show that the level of physical activity was significantly reduced during the social distancing period. Yoga emerged as a solid alternative to exercise at home. However, meeting Yoga experts and assembling for Yoga wasn't possible during this. A digital solution for this can improve this situation.

Our Solution - AasanAI

AasanAI is a Deep Learning-powered Web and Mobile application to help you during your yoga workouts. AasanAI detects your Yogasana position and helps you perfect your posture by getting visual feedback. It uses a Movenet Model for classification of the yoga pose by detecting keypoints of the various body parts.
The key features of AasanAI:

  • Timer for each Aasana - A timer which keeps a track of your current and best times helps you gradually progress in your workout
  • Maintain your workout history - AasanAI maintains a history of your Yoga workout sessions thereby allowing you to improve gradually. The history is saved on your account, allowing you to use either the web or the mobile application anytime as per your convenience.
  • Participate in events and competitions - AasanAI aims to gamify this ecosystem to allow yoga events and competitions to take place virtually. This builds the basis for the future scope of this project and also opens a business potential.

Currently we recognize 4 yogasanas using the Movenet Model:

We eventually plan to include more asanas, and also an entire Suryanamaskar regime

Challenges we ran into

Challenges while communicating with Firebase

Since the project involved both a web and mobile application, we faced multiple challenges of the same nature while communicating with the Firebase project.

  • The website initially had issues writing to Firestore, and also had issues navigating the nested collections stored in Firestore. This was eventually solved by modifying the structure (schema) of how we stored the documents inside Firestore collections. The mobile app had to modify its existing communication with Firestore to follow these changes.

  • Another major issue in Firebase connection came during Authentication in the mobile application. When we switched from a sample Firebase project to the current Firebase project, we had issues of establishing connection with the new Firebase project. Even when the Firebase config files were changed and Firebase SDKs were reinstalled, the app still communicated with the older project. This was solved by entirely rebuilding the app again.

Challenges while integrating the Movenet Model

Coming to the Movenet model integration part, the challenges faced by the web and mobile applications were different.

  • The web application had difficulties of maintaining the Aasan timer which would give us a wrong duration while changing the Aasan tabs. This was solved by improving the state management in the React application and improving the model and timer setup.
  • In the mobile application, although the TFLite model was imported to the

    assets

    folder, the app still didn't recognize the model with the camera. The camera blacked out abruptly and even when it started, the model still didn't detect the Aasan. We solved this by adding some missing dependencies and restructuring the

    assets

    folder
    .

Discussion