Troubleshooting BlazePose, pose estimation model, on Android studio.

The encountered technical problems along with their solutions .

BlazePose is a pose estimation model that extracts body keypoints from a single image. It exactly infers 33, 2D landmarks of a human body from a single frame such as shoulders, elbows, and knees as illustrated in the previous figure .

This article is the third part of BlazePose’s article series . It focuses on three technical problems you could encounter while inferring through the model on Android studio ,the official integrated development environment for Google’s Android operating system, and how to solve them .

The technical problems are :

  • The images uploaded on the internal storage exist in the Device File Explorer but do not appear on Android Virtual Device(AVD).
  • while uploading images on the device’s external storage , it throws permission denied error.
  • when running the application , it throws the following error : The application could not be installed:

To know more about what Blazepose is , how its performance is revolutionary compared to its counterparts, and how to use it for upper body pose estimation , Kindly refer to this article . It represents the first part of BlazePose’s article series.

To get hands-on experience on how to infer through the model , kindly refer to this article. It represents the second part of BlazePose’s article series in which we have illustrated the exact technical steps you need to do to try/infer through Blazepose for full body pose estimation .

Note : This Article is a part of a technical research project that has been conducted by R&D department at Yuram. Yuram is a product of VRapeutic– a software company specialized in therapeutic applications based in Egypt.

Back to the first technical problem “The images uploaded on the internal storage exist in Device File Explorer but do not appear on Android Virtual Device(AVD)

  • To upload images to your AVD : When you run the application and your
    android emulator is on, click on the Device File Explorer . In order to open Device File Explorer, click View > Tool Windows > Device File Explorer or click the Device File Explorer button in the tool window bar to open it.
  • Then, you can add images to your internal storage by clicking on sdcard >
    DCIM> right click > upload.
    Unfortunately ,you will find your image uploaded on device file explorer but still invisible on AVD.
How to Upload Images to your AVD’s Internal Storage

To solve this problem , when you select image to apply Pose detection on from camera folder, click on the three vertically lined dots and choose show internal storage, then click on the three horizontal lines icon .

You will find a folder called “Android SDK Built for X86” this is where images uploaded on your AVD’s internal storage appear. The following figures show the steps thoroughly.

How to make images uploaded on the internal storage appear on AVD

Now , it is time to handle the second problem . It is about the permission to upload images on the external storage is denied . To prevent this problem from happening , make sure that your AVD’s system image is Android Open Source Project (AOSP) which does not include Google apps or services. The following image represents an example of AOSP system image.

Choose system images without Google APIs tag in “Target” tab.

Then, it is pretty similar to uploading images on internal storage, go to Device File Explorer. Click on storage>self > primary>DCIM>Camera>Upload.

How to upload images to external storage

Now let’s tackle the third problem which is that running the application leads to the following error :The application could not be installed:

The error is

To solve it , From “File”->Project Structure->Build Variants.
Under “Build Types” tab, in both “proguard” and “debug” go to Signing
Config and choose or type “$signingConfigs.debug”.

solution to

To conclude , we have reached the end of Blazepose’s article series . This article is focused on the troubleshooting part . It is worth noting that most of the technical problems are more related to Android studio rather than the model itself. So, that is the stuff you need to bear in mind regarding Android Studio while dealing with Pose detection/estimation in MLkit’s quick start app .

“Finally, Clapping is your way to let us know you have liked our Article”

Machine Learning Engineer at VRapeutic . Alumna from University of Science and Technology at Zewail City.