WebNN support initial
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
*/
|
||||
|
||||
/** Devices the worker can actually run on (D-004). */
|
||||
export type InferenceDevice = "webgpu" | "wasm";
|
||||
export type InferenceDevice = "webgpu" | "wasm" | "webnn";
|
||||
|
||||
/**
|
||||
* What the UI may request. "auto" (the default) lets the worker probe
|
||||
@@ -147,7 +147,7 @@ function isOptionalString(value: unknown): value is string | undefined {
|
||||
return value === undefined || typeof value === "string";
|
||||
}
|
||||
|
||||
const DEVICES: readonly string[] = ["webgpu", "wasm"];
|
||||
const DEVICES: readonly string[] = ["webgpu", "wasm", "webnn"];
|
||||
const DTYPES: readonly string[] = ["fp32", "fp16", "q8", "q4"];
|
||||
|
||||
export function isInferenceDevice(value: unknown): value is InferenceDevice {
|
||||
|
||||
Reference in New Issue
Block a user