Under 18

SLIDES

https://docs.google.com/presentation/d/1mInHYhiVynGZ4VY2QhG05xGHjVFDIHk9JPqHCPPlWIg/edit?usp=sharing

Inspiration

Ever since the pandemic when schools were forced to close, students like me faced 8 hours of computer usage every day, sometimes even more. Our posture has been negatively impacted because of this most times because of small actions we deem insignificant. These can include slouching just a little because of boredom or leaning forward to doze off in the middle of class. All these 'insignificant' actions can all add up to damages to our body.

Personally I had sometimes experienced immense back pain for days at a time because of poor posture. No matter how hard I tried to correct it, eventually I would forget for some period of time and then I would realize and attempt to correct it. This cycle was a never ending loop. That is why for this project, I dedicated my efforts to attempt to solve this challenging problem: how to encourage people to use good posture through non-invasive means.

What it does

My program essentially compares and scores 2 sets of images. One is the 'base' images that the user provides which they can create through the program. The user would press the 'take snapshot' button to save an image of the edge filter on themselves in a posture they deem proper. Then the user would take that image and make a copy and color in themselves pure red (rgb 255,0,0). The program then continuously compares that 'base' set with a set it captures and produces from the user's webcam every so often at an adjustable rate. It then outputs a sort of normalized score so it is understandable. (around -100 < x <150)

How we built it

I used Java Swing for the UI and used opencv to access the webcam (javacv for java). Then I attempted creating and slightly adjusting algorithms that find the edges, fill in the user's body, and score the sets of images.

Challenges we ran into

One particularly difficult challenge I ran into was the edge algorithm where it would sometimes fail to draw a light enough line around the user. This resulted in the flood fill algorithm to fail and be inconsistent. I played around with the algorithm, smoothing the image out, creating stricter requirements for the flood fill algorithm, and using the Gaussian filter. All of this resulted in both positives and negatives, which I just then picked something that produced a more accurate and consistent score.

Accomplishments that we're proud of

I am proud of how cool the edge filter turned out to be and even took the time to walk around my room looking at the filtered image. I also had to optimize so much for the video capture and the flood fill algorithm which would sometimes hit the Java Stack limit. I solved this by using my own stack with a more compact data type (short).

What we learned

I've learned a lot about image processing within Java. Also this was the first time I've ever used maven dependencies (and to be honest, it kinda sucks on eclipse - took 40 ish minutes to even get it working)

What's next for Posture Assistant Application

Some ideas I had for this project was a cleaner UI that would allow the user to adjust several settings to make this program more applicable to a wider diverse audience. I would also improve how the user supplies the 'base' sets as currently it's really tedious on the user.

One way that I think could help retention and persuade the audience to actually change their posture is through a rewarding system and by displaying historical data. But this would require the scoring algorithm to be much more consistent and accurate than it is currently.

Built With

Share this project:

Updates