ViMUNet<T>

Models & Types · AiDotNet.ComputerVision.Segmentation.Mamba

ViM-UNet: Vision Mamba for medical image segmentation in U-Net.

Inheritance: NeuralNetworkBase<T> → SegmentationModelBase<T> → SemanticSegmentationBase<T> → ViMUNet<T>

For Beginners

Medical image segmentation with Mamba. Biomedical image analysis.

Common use cases:

  • Medical image segmentation with Mamba
  • Biomedical image analysis
  • Efficient U-Net alternative
  • Long-range dependency modeling in medical images

How It Works

Technical Details:

  • Vision Mamba encoder blocks in U-Net architecture
  • Bidirectional SSM for capturing global context
  • Skip connections between encoder and decoder
  • Linear complexity for efficient medical image processing

Reference: Archit and Pape, “ViM-UNet: Vision Mamba for Biomedical Segmentation”, arXiv 2024.

Example

// Create a ViM-UNet model for biomedical image segmentation
var architecture = new NeuralNetworkArchitecture<double>(
    inputType: InputType.ThreeDimensional,
    taskType: NeuralNetworkTaskType.MultiClassClassification,
    inputHeight: 256, inputWidth: 256, inputDepth: 3, outputSize: 14);
var model = new ViMUNet<double>(architecture);
// Every tunable is now set through the options object; these are the defaults:
var custom = new ViMUNet<double>(architecture,
    options: new ViMUNetOptions { NumClasses = 14, DropRate = 0 });
            
// Or load a pre-trained ONNX model for medical image analysis
var onnxModel = new ViMUNet<double>(architecture, "vimunet.onnx");

Constructors

Constructor Summary
ViMUNet(NeuralNetworkArchitecture<T> architecture, IGradientBasedOptimizer<T, Tensor<T>, Tensor<T>> optimizer, ILossFunction<T> lossFunction, ViMUNetOptions options) Initializes ViMUNet in native (trainable) mode.
ViMUNet(NeuralNetworkArchitecture<T> architecture, string onnxModelPath, ViMUNetOptions options) Initializes ViMUNet in ONNX (inference-only) mode.

Methods

Method Summary
ModelMetadata<T> GetModelMetadata() Collects metadata describing this model’s configuration.