8fa2699551
References were stored in normalized flow-matching space (net_generator.normalize(z_sample)) but the style loss compares against unnormalize(x) which is in VAE latent space. The optimizer was minimizing L1 between tensors at different scales, pushing the ODE endpoint out of distribution and producing noise. Fix: store reference latents in VAE space (z_sample directly) so both ref_mean/ref_gram and x_un are in the same coordinate system. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>