INNER CODE UNIT · Python
serve
HyperGAN/HyperGAN · hypergan/cli.py:94
def serve(self, gan):
return gan_server(self.gan.session, config)
def sample(self, allow_save=True):
""" Samples to a file. Useful for visualizing the learning process.
If allow_save is False then saves will not be created.
Use with:
ffmpeg -i samples/grid-%06d.png -vcodec libx264 -crf 22 -threads 0 grid1-7.mp4
to create a video of the learning process.
"""
sample_file="samples/%s/%06d.png" % (self.config_name, self.samples)
self.create_path(sample_file)
self.lazy_create()