Tencent / PocketFlow

An Automatic Model Compression (AutoMC) framework for developing smaller and faster AI applications.
https://pocketflow.github.io
Other
2.78k stars 490 forks source link

Pb & Tflite coverter for Weight Sparsification #252

Closed rag1998 closed 5 years ago

rag1998 commented 5 years ago

We are trying to evaluate Weight Sparsification Learner for some compression needs, using Optimal Prune Ratio Protocol we were able to achieve good accuracy but are having a bit of a hard time figuring out a converter to use to get .pb and .tflite files.

Is there one built already or do we have to create one?

jiaxiang-wu commented 5 years ago

To the best of our knowledge, TensorFlow and TensorFlow Lite does not support directly inference using models with non-structured sparsity and stored in CSR/CSC format. Therefore, we do not provide such model conversion tool. A possible solution to manually create a model loader so that the model can be stored in CSR/CSC format on disk and de-compressed to memory during inference. But this can only reduce the disk space consumption, which seems not so important in many applications.