-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
New caching api #27644
New caching api #27644
Conversation
43ce9ae
to
2b6200e
Compare
Hi guys @ilya-lavrenov @PatrikStepan @nshchego @MirceaDan99 @sshlyapn |
Updated my functional POC of supporting new I still believe we'll need to add a mechanism to treat offsets in the buffer for the |
2b6200e
to
e884bf8
Compare
c3df271
to
1e72a49
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could be any test added to use new API?
@@ -40,6 +40,11 @@ class MockIPlugin : public ov::IPlugin { | |||
import_model, | |||
(std::istream&, const ov::SoPtr<ov::IRemoteContext>&, const ov::AnyMap&), | |||
(const)); | |||
MOCK_METHOD(std::shared_ptr<ov::ICompiledModel>, import_model, (std::istream&, std::shared_ptr<ov::AlignedBuffer>, const ov::AnyMap&), (const)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not string + Tensor ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is internal plugins api. All plugins support model import with std::istream. I just added ov::AlignedBuffer as additional argument to simplify implementation to plugins. They can now reuse existing implementation + add additional login to get weights directly from ov::AlignedBuffer
5d582fe
to
61759a7
Compare
tests were added |
5e1c700
to
31e0dd2
Compare
*/ | ||
virtual std::shared_ptr<ov::ICompiledModel> import_model(std::istream& model, | ||
std::shared_ptr<ov::AlignedBuffer> model_buffer, | ||
const ov::AnyMap& properties) const; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why not to pass this model_buffer
via properties ? It will require less changes
In future, we are moving to weightless cache for all plugins, so model_buffer
will be less important.
alternative solution is #27981 |
This PR is closed to merge another solution #27981 |
### Details: - Replacement for #27644 ### Tickets: - CVS-154602 - CVS-157192
### Details: - Replacement for openvinotoolkit#27644 ### Tickets: - CVS-154602 - CVS-157192
Details:
Tickets: