File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change @@ -134,10 +134,11 @@ static OrtStatus* CreateSessionAndLoadModelImpl(_In_ const OrtSessionOptions* op
134134 bool load_config_from_model =
135135 os_env.GetEnvironmentVar (inference_session_utils::kOrtLoadConfigFromModelEnvVar ) == " 1" ;
136136
137- // If ep.context_enable is set, then ep.context_file_path is expected, otherwise ORT don't know where to generate the _ctx.onnx file
137+ // Check EPContext model generation options when the input model is loaded from memory (no input model path).
138138 if (options && model_path == nullptr ) {
139139 epctx::ModelGenOptions ep_ctx_gen_options = options->value .GetEpContextGenerationOptions ();
140140
141+ // Because there is no input model path, we require the application to explicitly set an output model's location.
141142 // This is checked by the OrtCompileApi's CompileModel() function, but we check again here in case
142143 // the user used the older SessionOptions' configuration entries to generate a compiled model.
143144 if (ep_ctx_gen_options.enable ) {
You can’t perform that action at this time.
0 commit comments