TabDDPMGenerator<T>

Models & Types · AiDotNet.NeuralNetworks.SyntheticData

TabDDPM (Tabular Denoising Diffusion Probabilistic Model) for generating synthetic tabular data.

Inheritance: NeuralNetworkBase<T> → NeuralSyntheticTabularGeneratorBase<T> → TabDDPMGenerator<T>

Implements: IGeneratedParameterRegistrar<T>, ISyntheticTabularGenerator<T>

For Beginners

TabDDPM generates data by learning to “undo noise.”

**Training:**Generation:

If you provide custom layers in the architecture, those will be used directly for the denoiser MLP. If not, the network creates industry-standard TabDDPM layers based on the original research paper specifications.

Example usage:

TabDDPM often produces higher-quality synthetic data than CTGAN/TVAE, especially for complex distributions, at the cost of slower generation (many denoising steps).

How It Works

TabDDPM applies diffusion models to tabular data with separate processes for different feature types:

  • Gaussian diffusion for continuous/numerical features (noise prediction)
  • Multinomial diffusion for categorical features (category probability prediction)
  • Shared MLP denoiser with sinusoidal timestep embedding processes both types jointly
  • Simple preprocessing: Quantile normalization for continuous, integer encoding for categorical

This implementation follows the standard neural network architecture pattern with:

  • Proper inheritance from NeuralNetworkBase
  • Layer-based architecture using ILayer components
  • Engine-based tensor operations for CPU/GPU acceleration
  • Full autodiff and JIT compilation support

Reference: “TabDDPM: Modelling Tabular Data with Diffusion Models” (Kotelnikov et al., ICML 2023)

Constructors

Constructor Summary
TabDDPMGenerator() Initializes a new TabDDPM generator with the specified architecture.
TabDDPMGenerator(NeuralNetworkArchitecture<T> architecture, TabDDPMOptions<T> options, IGradientBasedOptimizer<T, Tensor<T>, Tensor<T>> optimizer, ILossFunction<T> lossFunction)

Properties

Property Summary
IReadOnlyList<ColumnMetadata> Columns { get; }
TabDDPMOptions<T> Options { get; } Gets the TabDDPM-specific options.
bool IsFitted { get; set; }

Methods

Method Summary
Dictionary<string, T> GetFeatureImportance()
Matrix<T> Generate(int numSamples, Vector<T> conditionColumn, Vector<T> conditionValue)
ModelMetadata<T> GetModelMetadata()
Task FitAsync(Matrix<T> data, IReadOnlyList<ColumnMetadata> columns, int? epochs, CancellationToken ct)
void Fit(Matrix<T> data, IReadOnlyList<ColumnMetadata> columns, int? epochs)