deeplearning4j / deeplearning4j-examples

Deeplearning4j Examples (DL4J, DL4J Spark, DataVec)

Home Page:http://deeplearning4j.konduit.ai

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Make a Moudle compiler

huzpsb opened this issue · comments

Issue Description

Please describe your issue, along with:

  • encountered behavior
    I have trained a multi-layer network to recognize some specific soundwaves.It worked perfectly well,and costed only ~1ms to work.However,when I tried to migrate it to Android,I found to my astonishment that the apk is over 1GB.I checked my moudle and found that it was merely 50kb.Is there a way that I can turn this moudle into,for instance,java code that works without DL4J?I don’t care performance loss since the soundwave lengths 10secs each,and I have 10secs to waste.But a 1 GB sized apk is just not appealing!

  • expected behavior
    Add a utility to compile pre-trained moudles into java bytecode that works without DL4J framework.So it would be suitable for from plugins to Android apps.

Version Information

Please indicate relevant versions, including, if relevant:

Latest(1.0.0-M2)

Contributing

If you'd like to help us fix the issue by contributing some code, but would
like guidance or help in doing so, please mention it!

(I want,but I don't have the ability.)

@huzpsb please file an issue on the main repo if you have a feature request/bug.

To summarize your concern we already handle this here: https://community.konduit.ai/t/optimising-dl4j-deployment-size/1737

Beyond that, we can also reduce the binary to just include the ops that are needed. This would require some work on your part but we do support it. If you want, move the discussion over to the forums: https://community.kondit.ai/ with higher visibility and we can dissect your problem. Thanks!