Construct an NCSN score network for the CelebA 64x64 setup.
Paper-faithful CelebA 64x64 configuration from NCSNv2 (Song 2020)
Appendix C: sample size 64x64, base_channels=128,
channel_mult=(1, 1, 2, 2, 4, 4), 2 ResBlocks per stage,
self-attention at the 16x16 feature map, geometric
noise levels in ,
and the NCSNv2 Langevin schedule ( steps per level,
).
Model Size
Parameters
pretrainedbool= FalseReserved for future weight registration; currently a no-op.
**overridesobject= {}Optional
NCSNConfig field overrides forwarded into the
underlying config.Returns
NCSNModelScore network configured with the CelebA 64x64 setup and any overrides.
Notes
Reference: Song and Ermon, "Improved Techniques for Training Score-Based Generative Models" (NCSNv2), NeurIPS, 2020 (arXiv:2006.09011), Appendix C.
Examples
>>> import lucid
>>> from lucid.models.generative.ncsn import ncsn_celeba
>>> model = ncsn_celeba().eval()
>>> x_tilde = lucid.randn((1, 3, 64, 64))
>>> sigma_idx = lucid.tensor([10]).long()
>>> out = model(x_tilde, sigma_idx)
>>> out.sample.shape # (1, 3, 64, 64)
(1, 3, 64, 64)