Hi DiffSynth-Studio team,
Thank you for open-sourcing this project.
I noticed that the Qwen-Image/Wan pipeline applies fixed channel-wise normalization to the VAE latent:
latents = (latents - mean) / std
Could you clarify:
How were these mean and std values calculated?
Were they computed by encoding the training data, taking the posterior mean for each sample, and then calculating channel-wise statistics over all samples and spatial-temporal positions?
Why is this scaling necessary?
My guess is that the raw latent channels have different means and variances, so this normalization makes their scales more balanced, better matches the scale of Gaussian noise, and prevents high-variance channels from dominating the flow-matching loss.
It would be very helpful if you could confirm this or share the statistics-collection method. Thanks!
Hi DiffSynth-Studio team,
Thank you for open-sourcing this project.
I noticed that the Qwen-Image/Wan pipeline applies fixed channel-wise normalization to the VAE latent:
latents = (latents - mean) / std
Could you clarify:
How were these mean and std values calculated?
Were they computed by encoding the training data, taking the posterior mean for each sample, and then calculating channel-wise statistics over all samples and spatial-temporal positions?
Why is this scaling necessary?
My guess is that the raw latent channels have different means and variances, so this normalization makes their scales more balanced, better matches the scale of Gaussian noise, and prevents high-variance channels from dominating the flow-matching loss.
It would be very helpful if you could confirm this or share the statistics-collection method. Thanks!