Use protobuf-lite to reduce onnxruntime.dll size.#639
Conversation
onnxruntime.dll. More details can be found here https://developers.google.com/protocol-buffers/docs/proto. The reduction is significant. For commit id: 4873b452151bafe49da332aaeab639ef0318fc1ca28d728, the size reduced by ~700K; from 4873728 to 4172800.
|
Any performance change? |
There should be zero change in performance since the model loading functionality has not changed. Previously we were able to take advantage of single APIs: ParseFromIStream and ParseFromFileDescriptor. Now we use the exact same functionality in 2 steps. See inference_session.cc and model.cc. |
a2af324 to
c33cbf8
Compare
794f66f to
ca26598
Compare
ca26598 to
887cc8a
Compare
566522d to
b8e53e9
Compare
c525da8 to
c8ced7f
Compare
fd209db to
a62f079
Compare
a62f079 to
1a90148
Compare
1a90148 to
45046ec
Compare
snnn
left a comment
There was a problem hiding this comment.
Please take a look at the build log.
It has a lot of error messages like:
"Parsing config failed."
Apparently, your new config parsing code doesn't work.
There was no problem with the parsing. The file just doesn't exist for many tests. The error message printed was misleading. I'll remove that line since it made sense only when we did protobuf parsing. |
466dfb5 to
e5ad72d
Compare
e5ad72d to
471e428
Compare
## Describe your changes 1. Skip vitis tests for ORT 1.16.1. Wait for VitisAI teams to fix this then to add the tests back. 2. Remove quant pre process as the bug is fixed in 1.16.1. 3. lower the metrics goal to allow at least one model in output. ## Checklist before requesting a review - [ ] Add unit tests for this change. - [ ] Make sure all tests can pass. - [ ] Update documents if necessary. - [ ] Format your code by running `pre-commit run --all-files` - [ ] Is this a user-facing change? If yes, give a description of this change to be included in the release notes. ## (Optional) Issue link
More details about the LITE_RUNTIME can be found here https://developers.google.com/protocol-buffers/docs/proto. The reduction is significant. For commit id: 4873b452151bafe49da332aaeab639ef0318fc1ca28d728, the size reduced by 700K; from 4873728 to 4172800 bytes.
More details on the binary analysis can be found here: https://microsoft-my.sharepoint.com/:w:/p/prs/ERGfQ3IIjWxFtznJCM_nLbwBVrziUgzcvNN9T3a6ETDIQw?e=OydgWL