1

I am using OCR project in my app project.I have added two zip file eng.traineddata.zip(12.1MB) and osd.traineddata.zip(4.1MB) and implemented library jtar-1.0.4.jar(12.1kb).

I have use some classes of OCR project. In this project for character reorganization when open camera they are extracting from eng.traineddata.zip(12.1MB) and osd.traineddata.zip(4.1MB) files from assets folder and save in Internal storage.

Now my debug apk size is 38.6MB on installation and when open camera from this app data will be 47.28MB.My app not depending on Internet and not want to extracting these both zip files from Internet.

I want to reduce apk size and apk data size.I am not using ndk.How to do this? Any suggestions?

Vishal Jadav
  • 924
  • 9
  • 11
  • I believe Proguard has some options for discarding unused classes etc.. I know it has cut a smaller project's APK size by almost a half for me. – Haem Feb 01 '17 at 11:03
  • I already done that. – Vishal Jadav Feb 01 '17 at 11:17
  • Try my suggestions [here](http://stackoverflow.com/a/36122110). – rmtheis Feb 01 '17 at 20:55
  • Sir..@rmthesis plese check my edited question. – Vishal Jadav Feb 02 '17 at 05:21
  • If added split in build.gradle then my apk size reduce to 21.5MB. but its create app-dev-x86-debug.apk. Is it run on any devices? and if i remove those two zip file from assets folder and extracting from Internet then its reduce size to 5.4MB. But i don't want to use Internet in my app and want to generate apk for all devices.Then splits apk work for me? – Vishal Jadav Feb 02 '17 at 05:36

0 Answers0