onnxruntime/js/common
Claude 3494f80e83
Check if HTMLCanvasElement exists (i.e. we are not running in a webworker) (#22153)
This fixes #22152


### Description
Tensor.fromImage fails in a webworker context, because HTMLCanvasElement
does not exist:

> HTMLCanvasElement is not defined



### Motivation and Context
This fixes #22152

---------

Co-authored-by: Yulong Wang <7679871+fs-eire@users.noreply.github.com>
2024-09-25 11:52:52 -07:00
..
lib Check if HTMLCanvasElement exists (i.e. we are not running in a webworker) (#22153) 2024-09-25 11:52:52 -07:00
test adds support for Uint8ClampedArray (#21985) 2024-09-11 22:02:30 -07:00
.gitignore
.npmignore
build.js [js] change default formatter for JavaScript/TypeScript from clang-format to Prettier (#21728) 2024-08-14 16:51:22 -07:00
package-lock.json bumps up version in main from 1.19 -> 1.20 (#21588) 2024-08-05 15:46:04 -07:00
package.json bumps up version in main from 1.19 -> 1.20 (#21588) 2024-08-05 15:46:04 -07:00
README.md
tsconfig.json
typedoc.json
webpack.config.js [js] change default formatter for JavaScript/TypeScript from clang-format to Prettier (#21728) 2024-08-14 16:51:22 -07:00

ONNX Runtime JavaScript API

ONNX Runtime JavaScript API is a unified API for all JavaScript usages. It's dependency of the following NPM packages:

  • onnxruntime-node
  • onnxruntime-web
  • onnxruntime-react-native

This package (onnxruntime-common) is not designed for using directly. Please consider to install one of the NPM packages above according to target platform.

License

License information can be found here.