RRDBNetGenerator<T>

Layers · AiDotNet.NeuralNetworks.Layers

RRDBNet Generator - the full generator architecture from ESRGAN and Real-ESRGAN.

Inheritance: LayerBase<T> → RRDBNetGenerator<T>

Implements: IShapeContract

For Beginners

This is the “brain” of Real-ESRGAN that transforms low-resolution images into high-resolution ones.

Key components:

  • Initial Conv: Extracts basic features from the input image
  • RRDB Blocks: 23 deep blocks that learn how to enhance details
  • Trunk Conv + Residual: Combines deep features with initial features
  • Upsampling: Makes the image bigger (2x or 4x depending on scale)
  • Final Convs: Produces the final RGB output image

The default parameters (64 features, 32 growth, 23 RRDBs, 4x scale) are from the Real-ESRGAN paper and produce excellent results for general image super-resolution.

How It Works

This implements the complete RRDBNet generator from the ESRGAN paper (Wang et al., 2018). It combines multiple RRDB blocks with upsampling for image super-resolution.

The architecture is:

Reference: Wang et al., “Real-ESRGAN: Training Real-World Blind Super-Resolution with Pure Synthetic Data”, ICCV 2021. https://arxiv.org/abs/2107.10833

Constructors

Constructor Summary
RRDBNetGenerator(int inputChannels, int outputChannels, int numFeatures, int growthChannels, int numRRDBBlocks, int scale, double residualScale) Initializes a new RRDBNet generator.

Properties

Property Summary
bool SupportsTraining { get; }
int NumFeatures { get; } Gets the number of feature channels.
int NumRRDBBlocks { get; } Gets the number of RRDB blocks.
int Scale { get; } Gets the upscaling factor.

Methods

Method Summary
IReadOnlyList<ILayer<T>> GetSubLayers()
IReadOnlyList<OutputAxisContract> OutputAxesFor(int inputRank)
void ResetState()
void UpdateParameters(T learningRate)