-
Notifications
You must be signed in to change notification settings - Fork 203
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
[LLM] [NPU] StaticLLMPipeline: Import model if blob file is present in Stateful pipeline #1494
[LLM] [NPU] StaticLLMPipeline: Import model if blob file is present in Stateful pipeline #1494
Conversation
@TolyaTalamanov @AsyaPronina please review |
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.
Here is how blob
logic is done for StatelessLLMPipeline
:
- User provides
USE_BLOB
option to specify its intention to use precompiled blob:
const auto use_blobs = pop_or_default(properties, "USE_BLOBS", false); - Along with this, user may also provide
BLOB_PATH
option that points to the folder where blobs are located - Depends on the model type (prefill, generation). Pipeline searches for
opevino_prefill.blob
andopenvino_generate.blob
.
Here is the proposal how it can be done for your case:
- Keep (1) and (2) the same way as in
StatelessLLMPipeline
. - For (3) blob name can be just
openvino_model.blob
This will allow user to:
- Specify exact blob location if it's different from folder provided
- Switch between blob and model cases
src/cpp/src/llm_pipeline_static.cpp
Outdated
auto compiled = setupAndCompileModel(model, model_desc, properties); | ||
m_request = compiled->create_infer_request(); | ||
m_sampler.set_seed(m_generation_config.rng_seed); | ||
const auto use_blobs = pop_or_default(properties, "USE_BLOBS", false); |
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.
We only have 1 blob, so it must be USE_BLOB
???
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.
Fixed
…envino.genai into as/npuw_import
Depends on openvinotoolkit/openvino#27915
Depends on openvinotoolkit/openvino#28420