Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ std::unique_ptr<ModelBlobWrapper> EPCtxHandler::GetModelBlobStream(const std::fi

result.reset(); // Release the stream as we will get the native blob from SharedContext
auto shared_context = shared_context_manager_->GetOrCreateSharedContext(native_blob_path);
return std::make_unique<ModelBlobWrapper>(shared_context->GetNativeBlobAsStream(partition_name), shared_context->GetNativeBlob(partition_name));
return std::make_unique<ModelBlobWrapper>(shared_context->GetNativeBlob(partition_name));
}

LOGS_DEFAULT(VERBOSE) << "[OpenVINO EP] Read blob from EPContext Node";
Expand Down
3 changes: 2 additions & 1 deletion onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@
namespace openvino_ep {

struct ModelBlobWrapper {
ModelBlobWrapper(std::unique_ptr<std::istream> stream, const ov::Tensor& tensor) : stream_(std::move(stream)), tensor_(tensor) {}
explicit ModelBlobWrapper(std::unique_ptr<std::istream> stream, const ov::Tensor& tensor) : stream_(std::move(stream)), tensor_(tensor) {}

Check notice on line 19 in onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h

View workflow job for this annotation

GitHub Actions / cpplint

[cpplint] onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h#L19

Add #include <utility> for move [build/include_what_you_use] [4]
Raw output
onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h:19:  Add #include <utility> for move  [build/include_what_you_use] [4]
explicit ModelBlobWrapper(const ov::Tensor& tensor) : tensor_(tensor) {};

Check notice on line 20 in onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h

View workflow job for this annotation

GitHub Actions / cpplint

[cpplint] onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h#L20

You don't need a ; after a } [readability/braces] [4]
Raw output
onnxruntime/core/providers/openvino/onnx_ctx_model_helper.h:20:  You don't need a ; after a }  [readability/braces] [4]
std::unique_ptr<std::istream> stream_;
ov::Tensor tensor_; // May be empty if model blob is provided as stream only.
};
Expand Down
Loading