Skip to content

Commit

Permalink
[js/webgpu] Support uniforms for attention
Browse files Browse the repository at this point in the history
  • Loading branch information
axinging committed Dec 21, 2023
1 parent f3c62bf commit 4f5c6d1
Show file tree
Hide file tree
Showing 4 changed files with 159 additions and 140 deletions.
4 changes: 2 additions & 2 deletions js/web/lib/wasm/jsep/webgpu/op-resolve-rules.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
// Licensed under the MIT License.

import {argMax, argMin, parseArgMinMaxAttributes} from './ops/argminmax';
import {attention, parseAttentionAttributes} from './ops/attention';
import {attention} from './ops/attention';
import {batchNorm} from './ops/batch-norm';
import {biasAdd} from './ops/bias-add';
import {biasSplitGelu} from './ops/bias-split-gelu';
Expand Down Expand Up @@ -50,7 +50,7 @@ export const WEBGPU_OP_RESOLVE_RULES: Map<string, OperatorImplementation> = new
['Asinh', [unaryOps.asinh]],
['Atan', [unaryOps.atan]],
['Atanh', [unaryOps.atanh]],
['Attention', [attention, parseAttentionAttributes]],
['Attention', [attention]],
// TODO: support new attributes for AveragePool-10
['AveragePool', [pool.averagePool, pool.parseAveragePoolAttributes]],
['BatchNormalization', [batchNorm]],
Expand Down
Loading

0 comments on commit 4f5c6d1

Please sign in to comment.