mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-05-19 21:32:23 +00:00
[hotfix] fix session option access in Node.js binding (#17762)
### Description fix session option access in Node.js binding ### Motivation and Context This is a bug that affect transformer.js using ONNX Runtime Node.js binding. Issue: #17377 This bug is already fixed in main branch, but it is not picked in 1.16 release.
This commit is contained in:
parent
6df4211f12
commit
f480a3618a
1 changed files with 1 additions and 1 deletions
|
|
@ -68,7 +68,7 @@ Napi::Value InferenceSessionWrap::LoadModel(const Napi::CallbackInfo &info) {
|
|||
int64_t bytesOffset = info[1].As<Napi::Number>().Int64Value();
|
||||
int64_t bytesLength = info[2].As<Napi::Number>().Int64Value();
|
||||
|
||||
ParseSessionOptions(info[1].As<Napi::Object>(), sessionOptions);
|
||||
ParseSessionOptions(info[3].As<Napi::Object>(), sessionOptions);
|
||||
this->session_.reset(
|
||||
new Ort::Session(OrtEnv(), reinterpret_cast<char *>(buffer) + bytesOffset, bytesLength, sessionOptions));
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Reference in a new issue