Human Pose Detection in React Native: Develop a mobile application to count squats in real-time Lets start Reach me out

-

Hey, beautiful people across the Web. I’m Himanshu Saini, a full-stack developer, today going to integrate the capabilities of Machine Learning in a React Native project to develop a straightforward mobile application to count the squats of an individual in real-time.

Squats calculation in mobile app

The NPM package we’re going to use for our project is react-native-human-pose, which is a light-weight yet performative package that provides almost 20+ fps in modern mobile devices

First create a react native project using following command

npx react-native@latest init SquatsCounter

Next, lets add our package to the project using

yarn add react-native-human-pose react-native-webview

Or

npm i react-native-human-pose react-native-webview

Android

Go to android/app/src/predominant/AndroidManifest.xml and add this line

iOS

cd ios && pod install

Then go to ios/SquatsCounter/Info.plist and these lines

NSCameraUsageDescription
$(PRODUCT_NAME) needs access to your Camera.

After installing and configuring the package, lets head over to the App.tsx and add this piece of code

Then run your project on an actual Android Device and see your Squats Counter in effect.
Hooray!!

LinkedIn: https://www.linkedin.com/in/himanshu–saini/

Email: himanshu.saiini.91@gmail.com

ASK ANA

What are your thoughts on this topic?
Let us know in the comments below.

1 COMMENT

0 0 votes
Article Rating
guest
1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments

Share this article

Recent posts

1
0
Would love your thoughts, please comment.x
()
x