How to Use Model Caching on NPU in C++?
Content Type: Product Information & Documentation | Article ID: 000101134 | Last Reviewed: 05/22/2025
Unable to determine how to use model caching on NPU in C++.
Specify pipeline_config for NPU pipeline to export and import caching compiled models.
Export example:
ov::AnyMap pipeline_config = { { "EXPORT_BLOB", "YES" }, { "BLOB_PATH", ".npucache\\compiled_model.blob" } };
ov::genai::WhisperPipeline pipeline(model_path, "NPU", pipeline_config);
Import example:
ov::AnyMap pipeline_config = { { "BLOB_PATH", ".npucache\\compiled_model.blob" } };
ov::genai::WhisperPipeline pipeline(model_path, "NPU", pipeline_config);