Browser Compatibility
Core ML Backend / macOS
| WebNN | CPU | GPU | NPU |
|---|---|---|---|
| macOS | ✅ Core ML | ✅ Core ML | ✅ Core ML |
| iOS | ❌ Core ML | ❌ Core ML | ❌ Core ML |
The WebNN Core ML backend mainly supported on macOS.
| WebNN Spec | Operations | Chromium Version |
|---|---|---|
| argMax | ✅ reduce_argmax | M128 |
| argMin | ✅ reduce_argmin | M128 |
| batchNormalization | ✅ batch_norm | M126 |
| cast | ✅ cast | M124 |
| clamp | ✅ clip | M125 |
| concat | ✅ concat | M125 |
| conv2d | ✅ conv | M125 |
| convTranspose2d | ✅ conv_transpose | M126 |
| cumulativeSum | ✅ cumsum | M132 |
| dequantizeLinear | ✅ dequantize_linear | M133 |
| element-wise binary / add | ✅ add | M122 |
| element-wise binary / div | ✅ real_div | M124 |
| element-wise binary / max | ✅ maximum | M124 |
| element-wise binary / min | ✅ minimum | M124 |
| element-wise binary / mul | ✅ mul | M124 |
| element-wise binary / notEqual | ✅ not_equal | M134 |
| element-wise binary / pow | ✅ pow | M124 |
| element-wise binary / sub | ✅ sub | M124 |
| element-wise logical / equal | ✅ equal | M125 |
| element-wise logical / greater | ✅ greater | M125 |
| element-wise logical / greaterOrEqual | ✅ greater_equal | M125 |
| element-wise logical / lesser | ✅ less | M125 |
| element-wise logical / lesserOrEqual | ✅ less_equal | M125 |
| element-wise logical / logicalAnd | ✅ logical_and | M132 |
| element-wise logical / logicalOr | ✅ logical_or | M132 |
| element-wise logical / logicalXor | ✅ logical_xor | M132 |
| element-wise logical / not | ✅ logical_not | M128 |
| element-wise unary / abs | ✅ abs | M126 |
| element-wise unary / ceil | ✅ ceil | M126 |
| element-wise unary / identity | ✅ identity | M126 |
| element-wise unary / cos | ✅ cos | M126 |
| element-wise unary / erf | ✅ erf | M126 |
| element-wise unary / exp | ✅ exp | M126 |
| element-wise unary / floor | ✅ floor | M126 |
| element-wise unary / isInfinite | ✅ Emulate with equal(abs(a), Infinity) | M141 |
| element-wise unary / isNaN | ✅ Emulate with not_equal(a, a) | M141 |
| element-wise unary / log | ✅ log | M126 |
| element-wise unary / neg | ✅ Emulated with mul(a, -1) | M127 |
| element-wise unary / reciprocal | ✅ inverse | M126 |
| element-wise unary / roundEven | ✅ round, todo: emulate when device type is not CPU | M141 |
| element-wise unary / sin | ✅ sin | M126 |
| element-wise unary / sqrt | ✅ sqrt | M126 |
| element-wise unary / tan | ✅ tan | M126 |
| elu | ✅ elu | M126 |
| expand | ✅ tile | M128 |
| gather | ✅ gather | M126 |
| gatherElements | ✅ gather_along_axis | M132 |
| gatherND | ✅ gather_nd | M132 |
| gelu | ✅ gelu | M132 |
| gemm | ✅ Emulated with add(mul(alpha, matmul(A, B)), mul(beta, C)) | M126 |
| gru | ✅ gru | M133 |
| gruCell | ✅ gru | M133 |
| hardSigmoid | ✅ sigmoid_hard | M126 |
| hardSwish | ✅ Emulated by mul(x, hardsigmoid(x, alpha=1.0/6, beta=0.5)) | M126 |
| instanceNormalization | ✅ instance_norm | M126 |
| layerNormalization | ✅ layer_norm | M129 |
| leakyRelu | ✅ leaky_relu | M126 |
| linear | Emulated with add(mul(alpha, a), beta) | M126 |
| lstm | ✅ lstm | M133 |
| lstmCell | ✅ lstm | M133 |
| matmul | ✅ matmul | M126 |
| pad | ✅ pad | M129 |
| pooling / averagePool2d | ✅ avg_pool | M126 |
| pooling / l2Pool2d | ✅ l2_pool | M126 |
| pooling / maxPool2d | ✅ max_pool | M126 |
| prelu | ✅ prelu | M136 |
| quantizeLinear | ✅ quantize_linear | M134 |
| reduction / reduceL1 | ✅ reduce_l1_norm | M126 |
| reduction / reduceL2 | ✅ reduce_l2_norm | M126 |
| reduction / reduceLogSum | ✅ reduce_log_sum | M126 |
| reduction / reduceLogSumExp | ✅ reduce_log_sum_exp | M126 |
| reduction / reduceMax | ✅ reduce_max | M126 |
| reduction / reduceMean | ✅ reduce_mean | M126 |
| reduction / reduceMin | ✅ reduce_min | M126 |
| reduction / reduceProduct | ✅ reduce_prod | M126 |
| reduction / reduceSum | ✅ reduce_sum | M126 |
| reduction / reduceSumSquare | ✅ reduce_sum_square | M126 |
| relu | ✅ relu | M125 |
| resample2d | ✅ upsample_bilinear ✅ upsample_nearest_neighbor | M126 |
| reshape | ✅ reshape | M126 |
| reverse | ✅ reverse | M137 |
| scatterElements | ✅ scatter_along_axis | M132 |
| scatterND | ✅ scatter_nd | M132 |
| sigmoid | ✅ sigmoid | M126 |
| sign | ✅ sign | M139 |
| slice | ✅ slice_by_size | M126 |
| softmax | ✅ softmax | M127 |
| softplus | ✅ softplus | M126 |
| softsign | ✅ softsign | M125 |
| split | ✅ split | M130 |
| tanh | ✅ tanh | M126 |
| tile | ✅ tile | M131 |
| transpose | ✅ transpose | M125 |
| triangular | ✅ band_part | M132 |
| where | ✅ select | M126 |
Last updated on