Skip to content

Serialize weights to map #31362

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

Draft
wants to merge 17 commits into
base: master
Choose a base branch
from

Conversation

XinWangIntel
Copy link
Contributor

@XinWangIntel XinWangIntel commented Jul 17, 2025

enabling serialization of weights to a WeightsMap, the map holds the shared_ptr of buffer.

Update serialize pass to accpet xmlstream and WeightsMapWrapper(Hold the WeightsMap since ov not expose alignedBuffer to normal package).
save weights buffer (std::shared_ptr * of AlignedBuffer, StringAlignedBuffer, SharedAlignedBuffer) to WeightsMap and use offset(number) as key.

In IR frontEnd will check the "key" and "type", then find weights from map

Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
…gnedBuffer

* They are not exposed by OV API, wait for OV to open them

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
Signed-off-by: Xin Wang <[email protected]>

Signed-off-by: Xin Wang <[email protected]>
@github-actions github-actions bot added category: Core OpenVINO Core (aka ngraph) category: transformations OpenVINO Runtime library - Transformations category: IR FE OpenVINO IR v10 / v11 FrontEnd category: CPP API OpenVINO CPP API bindings category: NPU OpenVINO NPU plugin labels Jul 17, 2025
@XinWangIntel XinWangIntel changed the title Serialize with weights shared map Serialize weights to map Jul 17, 2025
Signed-off-by: Xin Wang <[email protected]>
@XinWangIntel XinWangIntel force-pushed the serialize-with-weights-shared-map branch from 45b3992 to fe9d6e1 Compare July 17, 2025 06:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category: Core OpenVINO Core (aka ngraph) category: CPP API OpenVINO CPP API bindings category: IR FE OpenVINO IR v10 / v11 FrontEnd category: NPU OpenVINO NPU plugin category: transformations OpenVINO Runtime library - Transformations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant