pytorch_generative/models/vae.py
def sample(self, n_images):
        """Generates a batch of n_images."""
        device = next(self.parameters()).device
        latents = torch.randn((n_images, self._latent_dim), device=device)
        return self._decoder(latents)
Generates a batch of n_images.
Generates a batch of n_images.
Generates a batch of n_images .
def sample(self, n_images):
        device = next(self.parameters()).device
        latents = torch.randn((n_images, self._latent_dim), device=device)
        return self._decoder(latents)
def sample ( self , n_images ) : device = next ( self . parameters ( ) ) . device latents = torch . randn ( ( n_images , self . _latent_dim ) , device = device ) return self . _decoder ( latents )
Generates a batch of n_images.
Generates a batch of n_images .
"""Generates a batch of n_images."""
self
n_images