Level of heart beat is a primary indicator for the effectiveness of a workout, yet it is often unmeasured and untargeted. Brainstorming ways to stimulate our body for increased intensity, we realized that music often relates to physiological transition within an exercise, based on its bpm, pitch, decibels, etc., and decided to begin work on an app that targets a certain level of heart rate using music to help the user reach their physical limit.
What it does
Allows for users to input target workout levels and recommends songs based on ML algorithms that will help them reach those specific levels and meet their workout goals.
How we built it
Frontend on Swift, backend using ML in google colab using python
Challenges we ran into
Determining model selection for the clustering component. Due to the high dimensions for the model, we needed to use Principal Component Analysis to visually aid in mapping the clusterings to the heart rate ranges. The watchOS development was tricky since it is a more niche development system with less existing documentation. A major roadblock is the step of integrating Python script to SwiftUI, due to incomplete documentation and a limited means of implementation for this conversion from Python to SwiftUI.
Accomplishments that we're proud of
Segmenting the UI workflow to optimize segues through parallel structures in Swift storyboard interface was a major step taken in progressing through the app development, as there were limited constructs to enable a process of updating selections. The UI/UX Design and the resulting intuitive user integration were vital components in ensuring that our hack provides a user friendly environment. We are proud of our application of choosing and implementing a machine learning based clustering algorithm to associate a wide variety of relevant musical features from the identified dataset. The process of dimensionality reduction through PCA and subsequent data visualization for multidimensional feature vectors was important in enabling us to separate these clusters and assign them to a workout intensity level.
What we learned
Swift, Principal Component Analysis, Unsupervised Machine Learning, K-Means Algorithms, XCode, PyObjC, learning about and considering various clustering algorithms and methods such as k-nearest neighbors, reading prior literature about the strong correlation between a variety of musical factors and heartbeat, and consideration of other ML models such as Recurrent Neural Networks (RNN) as a solution using time series data.
What's next for Heart Beats
Enabling autoplay Functionality / song shuffle, optimal integration of python scripts in SwiftUI, dynamic heartbeat and song updates over time window, backend model optimization, and playlist compatibility