Table of Contents

Class MobileNetV3Configuration

Namespace
AiDotNet.Configuration
Assembly
AiDotNet.dll

Configuration options for MobileNetV3 neural network architectures.

public class MobileNetV3Configuration
Inheritance
MobileNetV3Configuration
Inherited Members

Remarks

MobileNetV3 builds on MobileNetV2 with additional optimizations including squeeze-and-excitation blocks and hard-swish activation for improved accuracy.

For Beginners: MobileNetV3 comes in Large (more accurate) and Small (faster) variants. Choose based on whether you prioritize accuracy or speed.

Constructors

MobileNetV3Configuration(MobileNetV3Variant, int, MobileNetV3WidthMultiplier, int, int, int)

Initializes a new instance of the MobileNetV3Configuration class.

public MobileNetV3Configuration(MobileNetV3Variant variant, int numClasses, MobileNetV3WidthMultiplier widthMultiplier = MobileNetV3WidthMultiplier.Alpha100, int inputHeight = 224, int inputWidth = 224, int inputChannels = 3)

Parameters

variant MobileNetV3Variant

The MobileNetV3 variant (Large or Small).

numClasses int

The number of output classes for classification.

widthMultiplier MobileNetV3WidthMultiplier

The width multiplier (default: Alpha100).

inputHeight int

The height of input images (default: 224).

inputWidth int

The width of input images (default: 224).

inputChannels int

The number of input channels (default: 3 for RGB).

Properties

Alpha

Gets the alpha value (width multiplier as a double).

public double Alpha { get; }

Property Value

double

InputChannels

Gets the number of input channels.

public int InputChannels { get; }

Property Value

int

InputHeight

Gets the height of input images in pixels.

public int InputHeight { get; }

Property Value

int

InputShape

Gets the computed input shape as [channels, height, width].

public int[] InputShape { get; }

Property Value

int[]

InputWidth

Gets the width of input images in pixels.

public int InputWidth { get; }

Property Value

int

NumClasses

Gets the number of output classes for classification.

public int NumClasses { get; }

Property Value

int

Variant

Gets the MobileNetV3 variant to use.

public MobileNetV3Variant Variant { get; }

Property Value

MobileNetV3Variant

WidthMultiplier

Gets the width multiplier for the network.

public MobileNetV3WidthMultiplier WidthMultiplier { get; }

Property Value

MobileNetV3WidthMultiplier

Methods

CreateLarge(int)

Creates a MobileNetV3-Large configuration (recommended default).

public static MobileNetV3Configuration CreateLarge(int numClasses)

Parameters

numClasses int

Returns

MobileNetV3Configuration

CreateSmall(int)

Creates a MobileNetV3-Small configuration for low-latency applications.

public static MobileNetV3Configuration CreateSmall(int numClasses)

Parameters

numClasses int

Returns

MobileNetV3Configuration