DAMVSROptions

Options & Configuration · AiDotNet.Video.Options

Configuration options for DAM-VSR, appearance and motion disentanglement for video super-resolution on Stable Video Diffusion.

Inheritance: ModelOptions → NeuralNetworkOptions → DAMVSROptions

For Beginners

DAM-VSR upscales video with a video diffusion model. An image upscaler sharpens one reference frame (the appearance), the low-resolution video steers how everything moves (the motion), and the diffusion model fills in the rest of the frames consistently.

How It Works

Defaults follow Kong et al., SIGGRAPH 2025 (arXiv 2507.01012), Sec. 3-4, and Stable Video Diffusion as diffusers releases it (stabilityai/stable-video-diffusion-img2vid): the 1.5B-parameter spatio-temporal U-Net (320, 640, 1280, 1280 channels; 5, 10, 20, 20 heads), its VAE with the temporal decoder, OpenCLIP ViT-H/14 as the image encoder, 14-frame clips and a x4 output. Sampling is 30 Euler steps on the Karras schedule (σ from 700 to 0.002) entered by SDEdit 60% of the way down, with motion-aligned bidirectional sampling. Training is AdamW at a constant 8e-5: 60,000 iterations of the ControlNet, 45,000 of the backward pass’s temporal value and output projections, and 10,000 of the VAE decoder on L2, perceptual and GAN losses (1, 1, 0.025) after 8 sampling steps.

Constructors

Constructor Summary
DAMVSROptions() Initializes a new instance with default values.
DAMVSROptions(DAMVSROptions other) Initializes a new instance by copying from another instance.

Properties

Property Summary
OnnxModelOptions OnnxOptions { get; set; } Gets or sets the ONNX runtime options.
bool BidirectionalSampling { get; set; } Gets or sets whether sampling averages the forward pass with the motion-aligned backward pass (true).
double GANWeight { get; set; } Gets or sets the decoder stage’s GAN loss weight β (0.025).
double KarrasRho { get; set; } Gets or sets the Karras schedule’s ρ (7).
double LatentScale { get; set; } Gets or sets the latent scale (0.18215).
double LearningRate { get; set; } Gets or sets AdamW’s constant rate (8e-5).
double NoiseAugmentationStrength { get; set; } Gets or sets the noise added to the reference image before encoding (0.02).
double PerceptualWeight { get; set; } Gets or sets the decoder stage’s perceptual loss weight α (1; 0 leaves the VGG19 out).
double SdeditStrength { get; set; } Gets or sets the fraction of the schedule SDEdit enters at (0.6, leaving 18 of 30 steps).
double SigmaMax { get; set; } Gets or sets the largest σ of the Karras schedule (700).
double SigmaMin { get; set; } Gets or sets the smallest σ of the Karras schedule (0.002).
double TrainingSigmaMean { get; set; } Gets or sets the mean of log σ for training noise (0.7, SVD’s high-resolution fine-tuning).
double TrainingSigmaStd { get; set; } Gets or sets the standard deviation of log σ for training noise (1.6).
double WeightDecay { get; set; } Gets or sets AdamW’s decoupled weight decay (0.01, PyTorch’s default; the paper states none).
int AddedTimeEmbedDim { get; set; } Gets or sets the width each added time id is embedded at (256).
int BackwardIterations { get; set; } Gets or sets the iterations that then train the backward pass’s temporal value and output projections (45,000).
int ControlNetIterations { get; set; } Gets or sets the iterations that train the ControlNet with the U-Net frozen (60,000).
int DecoderSamplingSteps { get; set; } Gets or sets the sampling steps whose output trains the VAE decoder in the last stage (8).
int DiscriminatorChannels { get; set; } Gets or sets the decoder stage discriminator’s base width (64, RealBasicVSR’s U-Net discriminator).
int Fps { get; set; } Gets or sets the frame rate conditioning (7; the first added time id is fps - 1, as SVD’s pipeline passes it).
int ImageEmbedDim { get; set; } Gets or sets the image embedding the U-Net cross-attends to (1,024).
int ImageEncoderDepth { get; set; } Gets or sets the image encoder’s transformer layers (32).
int ImageEncoderHeads { get; set; } Gets or sets the image encoder’s attention heads (16).
int ImageEncoderMlpDim { get; set; } Gets or sets the image encoder’s MLP width (5,120).
int ImageEncoderPatchSize { get; set; } Gets or sets the image encoder’s patch side (14).
int ImageEncoderSize { get; set; } Gets or sets the image encoder’s input side (224).
int ImageEncoderWidth { get; set; } Gets or sets the image encoder’s width (1,280).
int LayersPerBlock { get; set; } Gets or sets the ResNets per down stage (2; up stages have one more).
int MotionBucketId { get; set; } Gets or sets SVD’s motion bucket conditioning (127).
int NumFrames { get; set; } Gets or sets the frames of a clip (14, SVD’s length).
int NumInferenceSteps { get; set; } Gets or sets the sampling schedule’s steps (30).
int ScaleFactor { get; set; } Gets or sets the spatial upscaling factor (4).
int TransformerDepth { get; set; } Gets or sets the transformer layers per attention (1).
int VaeLayersPerBlock { get; set; } Gets or sets the VAE encoder’s residual blocks per stage (2).
int[] UNetChannels { get; set; } Gets or sets the U-Net stage widths (320, 640, 1280, 1280); each must divide into 32 groups.
int[] UNetHeads { get; set; } Gets or sets the attention heads per U-Net stage (5, 10, 20, 20).
int[] VaeChannels { get; set; } Gets or sets the VAE stage widths (128, 256, 512, 512); the latent is 2^(stages - 1) times smaller.
string ModelPath { get; set; } Gets or sets the path to the ONNX model file.