Browser Compatibility
LiteRT Backend / chromeOS, Linux, Windows and Android
WebNN | CPU | GPU | NPU |
---|---|---|---|
chromsOS | ✅ LiteRT/XNNPACK | 🚀ℹ️ LiteRT/MLDrift | 🚀ℹ️ LiteRT To do, temporarily fallback to XNNPACK |
Linux | ✅ LiteRT/XNNPACK | 🚀ℹ️ LiteRT/MLDrift | 🚀ℹ️ LiteRT To do, temporarily fallback to XNNPACK |
Windows | ✅ LiteRT/XNNPACK 🚀ℹ️ WCR/MLAS (deprecated) | ℹ️ DirectML (deprecated) 🚀ℹ️ Windows ML | ℹ️ DirectML (deprecated) 🚀ℹ️ Windows ML |
Android | ✅ LiteRT/XNNPACK | 🚀ℹ️ LiteRT/MLDrift | 🚀ℹ️ LiteRT To do, temporarily fallback to XNNPACK |
The WebNN LiteRT backend mainly supported on ChromeOS, Linux, Windows and Android.
WebNN Spec | Operations | Chromium Version |
---|---|---|
argMax | ✅ ARG_MAX | M126 |
argMin | ✅ ARG_MIN | M126 |
batchNormalization | ✅ Emulated with Scale * ((Input - Mean) / sqrt(Variance + Epsilon)) + Bias | M127 |
cast | ✅ CAST | M126 |
clamp | ✅ RELU_N1_TO_1 ✅ RELU6 ✅ RELU | M112 |
concat | ✅ CONCATENATION | M113 |
conv2d | ✅ CONV_2D ✅ DEPTHWISE_CONV_2D | M112 |
convTranspose2d | ✅ TRANSPOSE_CONV | M128 |
cumulativeSum | ✅ CUMSUM | M132 |
dequantizeLinear | ✅ QUANTIZE | M132 |
element-wise binary / add | ✅ ADD | M112 |
element-wise binary / div | ✅ DIV | M112 |
element-wise binary / max | ✅ MAXIMUM | M112 |
element-wise binary / min | ✅ MINIMUM | M112 |
element-wise binary / mul | ✅ MUL | M112 |
element-wise binary / notEqual | ✅ NotEqual | M134 |
element-wise binary / pow | ✅ POW | M122 |
element-wise binary / sub | ✅ SUB | M112 |
element-wise logical / equal | ✅ EQUAL | M126 |
element-wise logical / greater | ✅ GREATER | M126 |
element-wise logical / greaterOrEqual | ✅ GREATER_EQUAL | M126 |
element-wise logical / lesser | ✅ LESS | M126 |
element-wise logical / lesserOrEqual | ✅ LESS_EQUAL | M126 |
element-wise logical / logicalAnd | ✅ LOGICAL_AND | M132 |
element-wise logical / logicalOr | ✅ LOGICAL_OR | M132 |
element-wise logical / logicalXor | ✅ NOT_EQUAL | M132 |
element-wise logical / not | ✅ LOGICAL_NOT | M126 |
element-wise unary / abs | ✅ ABS | M116 |
element-wise unary / ceil | ✅ CEIL | M116 |
element-wise unary / identity | ✅ RESHAPE | M126 |
element-wise unary / cos | ✅ COS | M123 |
element-wise unary / erf | ✅ SIGN | M128 |
element-wise unary / exp | ✅ EXP | M123 |
element-wise unary / floor | ✅ FLOOR | M116 |
element-wise unary / log | ✅ LOG | M123 |
element-wise unary / neg | ✅ NEG | M116 |
element-wise unary / reciprocal | ✅ Emulated with 1/x | M127 |
element-wise unary / sin | ✅ SIN | M123 |
element-wise unary / sqrt | ✅ SQRT | M122 |
elu | ✅ ELU | M115 |
expand | ✅ BROADCAST_TO | M128 |
gather | ✅ GATHER | M126 |
gatherElements | ✅ Emulated with GATHER_ND | M133 |
gatherND | ✅ GATHER_ND | M132 |
gelu | ✅ GELU | M128 |
gemm | ✅ FULLY_CONNECTED | M112 |
gru | ✅ Emulated | M129 |
gruCell | ✅ Emulated | M129 |
hardSigmoid | ✅ Emulated with y = max(0, min(1, alpha * // x + beta)) | M126 |
hardSwish | ✅ HARD_SWISH | M112 |
instanceNormalization | ✅ Emulated with Scale * ((Input - Mean) / sqrt(Variance + Epsilon)) + Bias | M127 |
layerNormalization | ✅ Emulated | M127 |
leakyRelu | ✅ LEAKY_RELU | M113 |
linear | ✅ Emulated with alpha * x + beta | M126 |
lstm | ✅ Emulated | M129 |
lstmCell | ✅ Emulated | M129 |
matmul | ✅ BATCH_MATMUL | M126 |
pad | ✅ PAD | M114 |
pooling / averagePool2d | ✅ AVERAGE_POOL_2D | M112 |
pooling / l2Pool2d | 🚀 L2_POOL_2D | |
pooling / maxPool2d | ✅ MAX_POOL_2D | M112 |
prelu | ✅ PRELU | M115 |
quantizeLinear | ✅ QUANTIZE | M132 |
reduction / reduceL1 | ✅ Emulated with adding abs operation before reduceSum | M128 |
reduction / reduceL2 | ✅ Emulated with appending pow(x, 0.5) after reduceSumSquare | M128 |
reduction / reduceLogSum | ✅ Emulated with log and reduceSum | M127 |
reduction / reduceLogSumExp | ✅ Emulated with log, reduceSum and exp | M127 |
reduction / reduceMax | ✅ REDUCE_MAX | M126 |
reduction / reduceMean | ✅ MEAN | M120 |
reduction / reduceMin | ✅ REDUCE_MIN | M126 |
reduction / reduceProduct | ✅ REDUCE_PROD | M126 |
reduction / reduceSum | ✅ SUM | M126 |
reduction / reduceSumSquare | ✅ Emulated with reduceSum and square | M127 |
relu | ✅ RELU | M112 |
resample2d | ✅ RESIZE_BILINEAR ✅ RESIZE_NEAREST_NEIGHBOR | M112 |
reshape | ✅ RESHAPE | M112 |
reverse | ✅ REVERSE | M133 |
scatterElements | ✅ Emulated with SCATTER_ND and WHERE | M133 |
scatterND | ✅ SCATTER_ND | M132 |
sigmoid | ✅ LOGISTIC | M112 |
sign | ✅ SIGN | M130 |
slice | ✅ SLICE | M116 |
softmax | ✅ SOFTMAX | M112 |
softplus | ✅ Emulated with ln(1 + exp(x)) | M126 |
softsign | ✅ Emulated with x / (1 + |x|) | M127 |
split | ✅ SPLIT_V | M116 |
tanh | ✅ TANH | M116 |
tile | ✅ TILE | M131 |
transpose | ✅ TRANSPOSE | M113 |
triangular | ✅ Emulated | M128 |
where | ✅ SELECT_V2 | M126 |
Last updated on