Inspiration

Starting out in the gym can be overwhelming, especially without proper guidance. Many people struggle with the fear of putting in effort without seeing the desired results or, worse, risking injury due to incorrect form. The gym can feel intimidating when you're unsure if you're performing exercises optimally. With personal trainers being a luxury that not everyone can afford, we realized there was a gap for those who needed personalized feedback but couldn't access it easily. RepRepair was born from this struggle—we wanted to provide everyone with a tool that could offer real-time, actionable criticism on their workouts without the need for a human coach. Our goal was to make fitness training smarter and safer by leveraging technology to guide people toward their goals with confidence.

What It Does

RepRepair is a workout assistant that uses computer vision to analyze the effectiveness of exercises by tracking your body’s movements. It focuses on joint angles and movement patterns during each rep, comparing them to ideal ranges of motion for specific exercises. After a workout, RepRepair breaks down your performance by identifying which reps were done correctly and which were not. Beyond just identifying mistakes, it provides detailed feedback on how to improve your form, ensuring that users know exactly what adjustments to make in future sets. Whether it's a slight adjustment in posture or a major form correction, RepRepair ensures that users have personalized, easy-to-understand guidance to optimize their workouts.

How We Built It

We built RepRepair using a combination of modern technologies. On the frontend, we utilized React and Next.js for a responsive user interface that is easy to navigate, with TypeScript for ensuring code reliability. For the backend, we relied on Express.js to handle server-side logic and API calls, making the app scalable and efficient. To handle video analysis, we integrated Flask with OpenCV, which allowed us to process the user's workout videos, detect joints, and calculate joint angles using computer vision techniques. Finally, we used Python to build out the data processing logic that compares user movements to optimal exercise form, providing real-time feedback. All these technologies came together to create a seamless, cross-platform solution that offers instant and precise workout analysis.

Challenges We Ran Into

The biggest challenge we encountered was managing the complexity of our middleware and ensuring smooth communication between different layers of the app. We needed to make sure our API calls between the frontend, backend, and OpenCV processing were reliable and efficient. This required robust error handling and optimization to avoid any service interruptions, especially during real-time video analysis. By focusing on making our API calls fault-tolerant, we were able to minimize failures, ensuring a smooth user experience even when dealing with computationally heavy tasks like computer vision.

Accomplishments That We’re Proud Of

One of our proudest achievements is the OpenCV script we developed. It accurately tracks joint positions and calculates angles to detect correct and incorrect movements. Developing this from scratch and ensuring that it works across different body types and video conditions was a significant technical hurdle due to the logic that we had to implement with our multi-colored states. Not only did we manage to implement precise joint tracking, but we also utilized Google Gemini API that provides meaningful feedback to users in the form of a short summary and bullet points. We’re excited that our application can help users improve their form and avoid potential injuries, making their workouts both safer and more effective.

What We Learned

Through building RepRepair, we gained valuable experience in computer vision and human pose estimation. We learned the intricacies of using OpenCV to process video data, detect joints, and analyze complex movements. Additionally, we deepened our understanding of backend architecture, particularly how to handle data flow between different services. Another key learning was integrating with Google Gemini, which expanded our knowledge of leveraging of utilizing LLMs.

What's next for RepRepair

We believe our next feature to roll out would be having a database to store a user's videos. This would allow our Gemini bot to have a list of data that can be used to track user forms over a certain period of time. This would allow users to have more confidence in themselves as their form is corrected over time until perfection!

Share this project:

Updates