MIR.models.Deformable_Swin_Transformer_v2ΒΆ
Deformable Swin Transformer v2 backbone for 3D registration.
Functions
|
Partition a per-head channel-last 3D map into non-overlapping windows. |
|
Partition a channel-last 3D feature map into non-overlapping windows. |
|
Merge windows produced by |
Classes
|
A basic Swin Transformer layer for one stage. |
|
Deformable 3D Swin Transformer (v2) encoder for a moving/fixed image pair. |
|
LayerNorm over the channel dimension of a channel-first 3D tensor. |
|
Feed-forward MLP block used inside transformer blocks. |
|
Offset prediction block for deformable attention. |
|
Offset prediction block for deformable attention (lightweight). |
|
Image to Patch Embedding using a strided 3D convolution. |
|
Patch Merging Layer. |
|
Fixed 3D sinusoidal positional encoding. |
|
Fixed sinusoidal (1D, absolute) position embedding for a token sequence. |
|
Swin Transformer Block. |
|
Window based multi-head cross attention between moving and fixed features with relative position bias. |
|
Cross-gated MLP conditioned on a second token stream. |