RadialBasisFunctionNetwork<T>

Models & Types · AiDotNet.NeuralNetworks

Represents a Radial Basis Function Network, which is a type of neural network that uses radial basis functions as activation functions.

Inheritance: NeuralNetworkBase<T> → DeclaredModelLayoutBase<T> → VectorModelLayoutBase<T> → RadialBasisFunctionNetwork<T>

For Beginners

A Radial Basis Function Network is a special type of neural network designed to learn patterns differently than standard networks.

Think of it like a weather prediction system:

  • Traditional neural networks might look at many factors and gradually learn weather patterns
  • An RBFN instead has “weather experts” (the radial basis functions) who each specialize in a specific weather pattern
  • When new data comes in, each expert reports how similar the current conditions are to their specialty
  • The network combines these similarity reports to make a prediction

For example, one expert might specialize in “sunny summer days,” another in “rainy spring mornings,” and so on. When given new weather data, they each report how close it matches their expertise, and the network uses these reports to predict the weather.

RBFNs are particularly good at:

  • Learning complex patterns quickly
  • Function approximation (finding the shape of unknown mathematical functions)
  • Classification problems (determining which category something belongs to)

How It Works

A Radial Basis Function Network (RBFN) is a specialized type of neural network that uses radial basis functions as activation functions. Unlike traditional neural networks, RBFNs typically have only one hidden layer with a non-linear radial basis function, followed by a linear output layer. This architecture makes them particularly effective for function approximation, classification, and systems control problems.

Example

var architecture = new NeuralNetworkArchitecture<float>(inputFeatures: 8, outputSize: 4);
var input = Tensor<float>.CreateRandom(new[] { 1, 10 });
var trainX = Tensor<float>.CreateRandom(4, 8);
var trainY = Tensor<float>.CreateRandom(4, 2);
var result = new AiModelBuilder<float, Tensor<float>, Tensor<float>>()
    .ConfigureModel(new RadialBasisFunctionNetwork<float>(architecture))
    .Build(trainX, trainY);
var output = result.Predict(input);

Constructors

Constructor Summary
RadialBasisFunctionNetwork() Initializes a new instance of the RadialBasisFunctionNetwork class with the specified architecture and radial basis function.
RadialBasisFunctionNetwork(NeuralNetworkArchitecture<T> architecture, IRadialBasisFunction<T> radialBasisFunction, IGradientBasedOptimizer<T, Tensor<T>, Tensor<T>> optimizer, ILossFunction<T> lossFunction, RadialBasisFunctionNetworkOptions options)

Methods

Method Summary
ModelMetadata<T> GetModelMetadata() Gets metadata about the Radial Basis Function Network model.