attention_unet_3d(pretrained: bool = False, overrides: object = {})Attention U-Net, 3-D (Oktay et al., MIDL 2018).
The rank the paper actually specifies. Its Implementation Details
state "in contrast to the state-of-the-art CNN segmentation frameworks
... we propose a 3D-model to capture sufficient semantic context", and
every released network is Conv3d / BatchNorm3d with trilinear
resampling — it was built for CT volumes.
Identical to attention_unet in every other respect; only the
convolution rank differs, so the attention gate that is the paper's
contribution is the same mechanism in both.
Model Size
Parameters
pretrainedbool= FalseReserved for future pretrained-weight loading. Currently ignored.
**overridesobject= {}Keyword overrides forwarded into
AttentionUNetConfig.Returns
AttentionUNetForSemanticSegmentationVolumetric model expecting (B, C, D, H, W) input.
Examples
>>> import lucid
>>> from lucid.models.vision.attention_unet import attention_unet_3d
>>> model = attention_unet_3d(base_channels=8, depth=2).eval()
>>> out = model(lucid.randn(1, 1, 16, 32, 32))
>>> out.logits.shape[2:]
(16, 32, 32)