Skip to content
KernelIndex
Search⌘K

SAM hq vision attention with relative position backward

32 eligible runs
vision

Backward pass for SAM-HQ vision attention with 2D decomposed relative positional embeddings. Computes gradients through output projection, attention mechanism, softmax, relative position bias, and QKV projection.

Fastest reported
339.6µsmean · 75% of SOL
RIAC as wellLicense unknown · unknown

Reported evidence · last observed 2026-08-21. Reported by source; not independently reproduced. No public source. License unknown.

No public sourceRun detail →

Current records

Workloadsuite of 16 cases · mean latencyhead_dim = 64 · hidden_size = 768 · qkv_out_size = 2304 · num_attention_heads = 1216 cases

Not measured on H100 for this workload. Challenges →

Source-native comparison · GPU NVIDIA B200 · Workload suite of 16 cases · mean latency · Protocol SOL-ExecBench evaluation stack v1.1 · mean · 25 results · last observed 2026-08-23Record history →
#
Implementation
Latency
vs #1
Trust
Observed
1
339.6µs75% SOL
1.00×
Reported · license unknown · no source
2026-08-21

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
2
341.1µs74% SOL
1.00×
Reported · license unknown · no source
2026-08-22

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
3
346.4µs73% SOL
1.02×
Reported · license unknown · no source
2026-08-04

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
4
370.3µs73% SOL
1.09×
Reported · license unknown · no source
2026-07-29

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
5
448.1µs69% SOL
1.32×
Reported · license unknown · no source
2026-07-22

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
6
464.1µs68% SOL
1.37×
Reported · license unknown · no source
2026-07-23

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
7
486.0µs67% SOL
1.43×
Reported · license unknown · no source
2026-08-23

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
8
531.2µs65% SOL
1.56×
Reported · license unknown · no source
2026-07-10

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
9
552.5µs64% SOL
1.63×
Reported · license unknown · no source
2026-08-22

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
10
579.8µs63% SOL
1.71×
Reported · license unknown · no source
2026-07-17

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
11
606.3µs62% SOL
1.79×
Reported · license unknown · no source
2026-08-17

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
12
610.9µs62% SOL
1.80×
Reported · license unknown · no source
2026-08-07

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
13
631.2µs61% SOL
1.86×
Reported · license unknown · no source
2026-08-22

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
14
678.0µs59% SOL
2.00×
Reported · license unknown · no source
2026-08-07

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
15
682.4µs59% SOL
2.01×
Reported · license unknown · no source
2026-07-10

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
16
682.9µs59% SOL
2.01×
Reported · license unknown · no source
2026-07-10

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
17
699.4µs59% SOL
2.06×
Reported · license unknown · no source
2026-08-19

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
18
872.1µs54% SOL
2.57×
Reported · license unknown · no source
2026-07-12

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
19
917.2µs52% SOL
2.70×
Reported · license unknown · no source
2026-08-06

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
20
954.8µs51% SOL
2.81×
Reported · license unknown · no source
2026-08-06

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
21
1.10ms48% SOL
3.24×
Reported · license unknown · no source
2026-08-06

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
22
1.22ms45% SOL
3.60×
Reported · license unknown · no source
2026-08-07

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
23
2.83ms27% SOL
8.33×
Reported · license unknown · no source
2026-07-27

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
24
3.21ms25% SOL
9.46×
Reported · license unknown · no source
2026-07-26

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →
25
6.56ms15% SOL
19.33×
Reported · license unknown · no source
2026-08-16

Measured exactly what you asked. Reported by source; not independently reproduced.

no sourcelicense unknownno install recipeRun detail →

Implementations

Implementation
Runtime
Best latency
Evidence
Availability
unknown
339.6µs
1.00×
Reported
license unknown · no source
unknown
341.1µs
1.00×
Reported
license unknown · no source
unknown
429.9µs
1.27×
Reported
license unknown · no source
unknown
486.0µs
1.43×
Reported
license unknown · no source
unknown
498.8µs
1.47×
Reported
license unknown · no source
unknown
579.8µs
1.71×
Reported
license unknown · no source
unknown
682.1µs
2.01×
Reported
license unknown · no source
unknown
464.1µs
1.37×
Reported
license unknown · no source
Show all 32 implementations ›
unknown
531.2µs
1.56×
Reported
license unknown · no source
unknown
552.5µs
1.63×
Reported
license unknown · no source
unknown
606.3µs
1.79×
Reported
license unknown · no source
unknown
610.9µs
1.80×
Reported
license unknown · no source
unknown
631.2µs
1.86×
Reported
license unknown · no source
unknown
660.2µs
1.94×
Reported
license unknown · no source
unknown
678.0µs
2.00×
Reported
license unknown · no source
unknown
682.4µs
2.01×
Reported
license unknown · no source
unknown
682.9µs
2.01×
Reported
license unknown · no source
unknown
699.4µs
2.06×
Reported
license unknown · no source
unknown
872.1µs
2.57×
Reported
license unknown · no source
unknown
906.2µs
2.67×
Reported
license unknown · no source
unknown
917.2µs
2.70×
Reported
license unknown · no source
unknown
954.8µs
2.81×
Reported
license unknown · no source
unknown
1.10ms
3.24×
Reported
license unknown · no source
unknown
1.22ms
3.60×
Reported
license unknown · no source
unknown
1.91ms
5.61×
Reported
license unknown · no source
unknown
2.83ms
8.33×
Reported
license unknown · no source
unknown
3.03ms
8.91×
Reported
license unknown · no source
unknown
3.21ms
9.46×
Reported
license unknown · no source
unknown
6.56ms
19.33×
Reported
license unknown · no source
unknown
370.3µs
1.09×
Reported
license unknown · no source
unknown
346.4µs
1.02×
Reported
license unknown · no source
unknown
448.1µs
1.32×
Reported
license unknown · no source

Semantics

Inputs and outputs
grad_outputfp32 [batch_size, height, width, hidden_size]
hidden_statesfp32 [batch_size, height, width, hidden_size]
qkv_weightfp32 [qkv_out_size, hidden_size]
qkv_biasfp32 [qkv_out_size]
proj_weightfp32 [hidden_size, hidden_size]
proj_biasfp32 [hidden_size]
rel_pos_hfp32 [rel_pos_h_size, head_dim]
rel_pos_wfp32 [rel_pos_w_size, head_dim]
scalefp32 scalar
grad_hidden_statesfp32 [batch_size, height, width, hidden_size]
grad_qkv_weightfp32 [qkv_out_size, hidden_size]
grad_qkv_biasfp32 [qkv_out_size]
grad_proj_weightfp32 [hidden_size, hidden_size]
grad_proj_biasfp32 [hidden_size]
grad_rel_pos_hfp32 [rel_pos_h_size, head_dim]
grad_rel_pos_wfp32 [rel_pos_w_size, head_dim]
Axes and behavior
widthvariable
heightvariable
head_dimconstant = 64
batch_sizevariable
hidden_sizeconstant = 768
qkv_out_sizeqkv_out_size = hidden_size * 3
spatial_sizespatial_size = height * width
rel_pos_h_sizerel_pos_h_size = height * 2 - 1
rel_pos_w_sizerel_pos_w_size = width * 2 - 1
num_attention_headsconstant = 12
determinismunspecified
constraintsNo mutation or aliasing
Identity
alias076_sam_hq_vision_attention_with_relative_position_backwardmodelsam-hq-vit-basesha256c8fbe98fa604…
Sources: NVIDIA SOL-ExecBench (2026-08-23)last observed 2026-08-23How records are decidedJSON