-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Constants are stored two times with JSON Runtime #7981
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello,
I faced the problem that the TVM export methods doesn’t strip original collection of constant tensor in case of usage external runtime like BNNS/ACL and others. First time we store constants in
GraphRuntimeFactory
when write it to the library and second time inMetadataModule
. This leads to double size of final exported files and also increases memory footprint in runtime. In fact, it is enough to store constants only inMetadataModule
, and we can strip the original constants. Maybe we could remove original constants fromGraphRuntimeFactory
and store them only inMetadataModule
?On the screenshot you can see that the weights were load two times in runtime:
This problem can be critical for different mobile devices with limited size of RAM.
The text was updated successfully, but these errors were encountered: