mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-06-12 00:59:23 +00:00
[js/webgpu] Fix the undefined push error (#19366)
### Description This PR fixes below errors when enable webgpu profiling: ``` TypeError: Cannot read properties of undefined (reading 'push') ```
This commit is contained in:
parent
9139bdda02
commit
efc17e79de
1 changed files with 4 additions and 2 deletions
|
|
@ -530,8 +530,10 @@ export class WebGpuBackend {
|
|||
};
|
||||
this.pendingKernels.push(pendingKernelInfo);
|
||||
|
||||
const sessionPendingKernels = this.capturedPendingKernels.get(this.currentSessionId!);
|
||||
sessionPendingKernels!.push(pendingKernelInfo);
|
||||
if (this.sessionStatus === 'capturing') {
|
||||
const sessionPendingKernels = this.capturedPendingKernels.get(this.currentSessionId!);
|
||||
sessionPendingKernels!.push(pendingKernelInfo);
|
||||
}
|
||||
}
|
||||
|
||||
this.programManager.run(artifact, inputDatas, outputDatas, normalizedDispatchGroup, uniformBufferBinding);
|
||||
|
|
|
|||
Loading…
Reference in a new issue