You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
the feature SELECTIVE_REGISTRATION in TF Lite allows to create smaller TF lite library by only including the ops used in the converting model (see here). I couldn't find proper doc in the official TF lite guide though.
The text was updated successfully, but these errors were encountered:
arashb
changed the title
investigating tensorflow lite SELECTIVE_REGISTRATION feature
investigating TF lite SELECTIVE_REGISTRATION feature
Oct 23, 2019
So from what I understand, it works something like this:
There is the register.cc file which registers all the kernels. The way that we add our own kernel is by providing register_lqce.cc which includes our kernels.
Now the nice thing about a linker, is that when you do not register your kernel there, it will automatically detect that your Register_MyKernel() function is never called and it will remove that function from your final binary. So even if you compiled your MyKernel.cc file, it will just be removed at the end because it is seen as "unused".
So basically when you enable the selective registration feature, it generates a new register.cc file for you and it only calls the Register_XXX functions for those ops that are in your model. This way you get a binary that can only do your specific model or a subset of it.
So by providing our own register.cc file we are already kind-of using a system similar to this.
the feature SELECTIVE_REGISTRATION in TF Lite allows to create smaller TF lite library by only including the ops used in the converting model (see here). I couldn't find proper doc in the official TF lite guide though.
The text was updated successfully, but these errors were encountered: