LightM-UNet: Mamba Assists in Lightweight UNet for Medical Image Segmentation

Weibin Liao, Yinghao Zhu, Xinyuan Wang, Chengwei Pan, Yasha Wang, Liantao MaarXiv 2024 · DOI

TL;DR

LightM-UNet is an ultra-lightweight medical image segmentation framework that replaces heavy Transformer and CNN layers with Mamba-based State Space Models (SSMs). It achieves state-of-the-art accuracy while being a staggering 116x smaller and 21x faster than the industry-standard nnU-Net, making high-performance medical AI feasible for mobile and resource-constrained clinical settings.

Introduction

Medical image segmentation—the process of identifying organs or lesions in scans like CTs or X-rays—is currently dominated by the UNet architecture. Recently, researchers have integrated Transformers into UNet to capture "global context," the ability to model long-range spatial dependencies.

However, Transformers come with a significant computational cost: their complexity grows quadratically with image size. This makes them unsuitable for mobile health (mHealth) applications or hospitals with limited computing power. Conversely, traditional CNNs are efficient but have a narrow field of view, often missing critical long-range context. LightM-UNet addresses this by providing a model with the global reach of a Transformer but the efficiency of a lightweight CNN.

Methodology

The authors introduce LightM-UNet, which utilizes Mamba (a type of State Space Model) as a lightweight substitute for both CNN and Transformer blocks.

Architecture of LightM-UNet featuring the Residual Vision Mamba (RVM) Layer and Vision State-Space (VSS) Module.

Key technical components include:

  • Residual Vision Mamba (RVM) Layer: This is the core building block. It uses a "pure Mamba" approach to extract deep semantic features. Unlike previous hybrid models that mix CNNs and SSMs, this relies on the Mamba architecture to model long-range dependencies with linear computational complexity.
  • Vision State-Space (VSS) Module: This module processes data through parallel branches, using 1D scans in multiple directions to ensure the model captures spatial information effectively across 2D and 3D space.
  • Adjustment Factors: The researchers added learnable scaling factors ($s$ and $s'$) to the residual connections. This small tweak significantly stabilizes training and improves feature fusion in the decoder without adding a meaningful number of parameters.
  • Architecture: It follows the classic U-shaped encoder-decoder structure but is optimized to keep the total parameter count around 1 Million.

Experimental Setup

The model was validated on two diverse, real-world datasets:

  1. LiTS (Liver Tumor Segmentation Challenge): A 3D dataset consisting of CT scans. This tested the model's ability to handle complex volumetric data and small, hard-to-detect tumors.
  2. Montgomery & Shenzhen: A 2D dataset of chest X-rays used for lung segmentation. This demonstrated the model's versatility across different dimensions (2D vs. 3D) and modalities.

Key Results

The quantitative results highlight the model's extreme efficiency without sacrificing performance.

Comparison of DSC performance vs. GFLOPs on LiTS and Montgomery & Shenzhen datasets. LightM-UNet (ours) achieves superior performance with significantly lower computational cost.
  • Vs. nnU-Net: On the LiTS dataset, LightM-UNet achieved higher accuracy (84.58 DSC vs 82.11 DSC) while reducing parameters by 116x and computational costs (GFLOPs) by 21x.
  • Vs. U-Mamba: It outperformed the recent U-Mamba by 2.11% in mIoU while using significantly fewer resources.
  • Tumor Detection: The model was particularly effective at segmenting small tumors, which are often missed by other lightweight models.
  • Footprint: The 2D version of the model uses only 1.09M parameters, making it small enough to run on almost any modern mobile device.

Discussion and Future Work

Key Insights

  • Mamba as an Efficient Alternative: Mamba maintains a global receptive field without the memory explosion associated with Transformers, making it superior for lightweight applications.
  • The Power of "Pure" Mamba: While other recent papers use hybrid CNN-SSM blocks, LightM-UNet shows that a pure Mamba approach in the encoder/decoder is sufficient to outperform much larger models.
  • Extreme Parameter Efficiency: Achieving better-than-nnU-Net performance with a 116x reduction in parameters suggests that current standard models are significantly over-parameterized for these tasks.

Limitations

While the results are impressive, the authors note a few areas for growth. Future work will involve testing the model on a wider variety of organs and multi-organ segmentation tasks. Additionally, while the model is theoretically "mobile-ready," the authors plan to conduct actual on-device testing. Finally, further optimization of the training regime could help address potential convergence challenges in deep Mamba models.

Summary updated

BibTeX
@misc{liao2024lightm,
  author = {Weibin Liao and Yinghao Zhu and Xinyuan Wang and Chengwei Pan and Yasha Wang and Liantao Ma},
  title = {{LightM-UNet: Mamba Assists in Lightweight UNet for Medical Image Segmentation}},
  year = {2024},
  eprint = {2403.05246},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2403.05246},
}
Figure