Making an android app

Should I use TensorFlow or Caffe2 to create an app for android. I said let’s use caffe2, since TensorFlow is longer name and I like coffee too.

But when tried the tutorials I believe someone is trying to help you to create the apps as hard as possible.

Do I really have to use Android Studio to create an app. Can I make APK in Python?

It’s not a problem to integrate Python into your app, but adding PyTorch or Tensorflow or any other framework is completely different problem.
Mainly because those libraries usually rely on native bindings which are not available for Android.

Speaking about performance, your best choice would be TensorFlow(lite) or any other framework that supports Android Neural Networks API.

Otherwise you would rely on quality of ported code by 3rd-parties. For example, tutorial you mentioned contains no black magic - they just provide you native (C++) library and it’s up to you to implement all required integrations with your client code.

Also, check this Pytorch model running in Android - #4 by ptrblck

Do I really have to use Android Studio to create an app. Can I make APK in Python?

No, you are not required to use Android Studio. Even Android SDK is optional (you may write your own implementation of existing tools - they are open source). But you have to satisfy APK format in one or another way: compile code → convert to DEX → archive everything into APK (which is just ZIP with extra meta info) → zipalign & sign

1 Like

You made an excellent feedback but I will need few days to process that @ Vandalko