Skip to content
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

Prepack weights when model is loaded #214

Open
robertknight opened this issue May 27, 2024 · 0 comments
Open

Prepack weights when model is loaded #214

robertknight opened this issue May 27, 2024 · 0 comments
Labels
performance Issues that affect model inference or loading performance

Comments

@robertknight
Copy link
Owner

robertknight commented May 27, 2024

Other ML runtimes such as ONNX Runtime and TensorFlow Lite prepack weights for use with the selected matrix multiplication kernel when a model is loaded. This reduces inference latency when a model is run multiple times in a session, at the cost of longer load time.

RTen implements weight prepacking to amortize packing overhead when MatMul or Conv operators are applied to a batch of inputs. However it doesn't prepack inputs when the model is loaded, so packing costs are incurred for each inference.

References:

@robertknight robertknight added the performance Issues that affect model inference or loading performance label May 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
performance Issues that affect model inference or loading performance
Projects
None yet
Development

No branches or pull requests

1 participant